Same idea but instead of teleporting enemy rise shields. Teleport skill needs to be cool-down ability, I also need to be able to fine tune the time how long it takes to teleport again.Ĥ. or anything you can suggest that is betterĮnemy ship that is trying to avoid the player and pass and shoot into boundary( bottom of the screen) that we defend, this ship would also detect when player or players bullet are close(enter his collider- detection) and then teleport somewhere randomly on the screen. if enemy would move in an arch like movement not strait diagonally. = (0, 0, * -tilt) īut I need few more a bit complex and intelligent attacking maneuvers.ġ- Once the enemy ship detects the player it does not pass him, instead hoover around and tries to kill him/shoot.Ĭombination of evade and attack movements, Enemy ship stays around and fight the player ( does not pass him) till one of them dies. The player object is a dynamic rigidbody and can collide with other players or asteroids. The movement in 2DSpaceShooter is physics based.
Technical features include NetworkVariable and ObjectPooling. = new Vector3 (newManeuver, 0.0f, currentSpeed) The 2D Space Shooter Project provides examples of physics, player health, and status effects using Unity MLAPI. Yield return new WaitForSeconds ( (maneuverWait.x, maneuverWait.y)) įloat newManeuver = (, targetManeuver, smoothing * ) Yield return new WaitForSeconds ( (maneuverTime.x, maneuverTime.y))
Yield return new WaitForSeconds ( (startWait.x, startWait.y)) IEnumerator Evade ()// this randomly moves left and right and keeps the enemy within screen Public class Enemy_EvasiveManeuver1 : MonoBehaviour This is the basic Script that moves the ship In current script enemy (just like in any tower defence game) moves randomly shot randomly, and moves along z axes till it reaches end of the screen, where if not shoot by player get destroyed. which moves Enemies, and make them shot.īut I would like a couple of variation with improved AI. I need someone to create more advance Enemy Ai for space shooter.