I need help making an enemy that climbs around platforms. Like.
..........
.-<------.
.o######^.
.|######|.
.|######|.
.V######|.
.------>|.
..........
o=enemy
#=platform
->=Arrow
|
V=Arrow too
.=empty space
Edit: nevermind, the ascii got messed up. You could copy it on notepad though.
I don't recommend doing a path movement for it because it isn't extensible, and you'd have to have separate objects for different paths.
Instead, you could place invisible detector objects beyond the corners of your platforms so you direct the enemies where to go. If you're feeling really clever, however, you could test against the Collision Mask depending on which direction your object is travelling, and avoid using detectors altogether.
I wrote a detailed post on how to do it last night, but TDC fucked up and I closed the browser.
Basically do what Wong said with the corner detectors. Path movement is retarded.
i have a more complicated problem. in the phisycs department. im making a worms esque type game except with vehivhles like tanks en such. to make the projectiles arc im using something like
-PL1 pressed fire 1
and ("projectile")<1
then shoot ("projectile") towards ("sight")
set Value A("projectile") to X("projectile")
set Value B("projectile") to 24
-X("projectile")>Value A("projectile")
and B("projectile")<>dir("projectile")
every 0'00''10'''
then set dir("projectile") to dir("projectile")-1
-X("projectile")<Value A("projectile")
and B("projectile")<>dir("projectile")
every 0'00''10'''
then set dir("projectile") to dir("projectile")+1
this works but when direction is like dir 7 or 9 it makes it go high up relly far over and down-not high up a little over and then down like it would when you throw a ball up into the air. any one got a more realistic aproach.
also for a computer AI how would i make it so it shoots at a higher angle the farther away i am.
n/a
Assault Andy Administrator
I make other people create vaporware
Registered 29/07/2002
Points 5686
17th May, 2005 at 02:01:14 -
legendkpr, please create a new thread for a differant problem. Please also try and use proper spelling and grammar as it helps others to understand your problem better.
Thank you all, I am currently using agge's one because it's the easiest one. Too bad it can only climb on simple shapes as rectangles but I guess I can live with that.
Using detectors at the corner of your platforms is [b]extremely[/b] easy, and will allow your dudes to climb anything. Just create four different invisible detectors, named Left, Up, Down and Right, and make it so that your enemy faces that direction when overlapping the corresponding object.
Assault andy: ill start a new feed but what is this about spelling and grammer. theres only like two spelling errors that dont make what i wrote any less understandable and its not like im writing an essay. if someone wants to know what im saying because they dont understand the wording they can ask.