Grid Alert is the name for my new RTS.
I just got one problem.A base creates an enemy unit every so offten. But when it creates anotherone, it overlaps the other unit… How can i make it so the units slowly spread away from eachother?Grid Alert is the name for my new RTS.
I just got one problem.A base creates an enemy unit every so offten. But when it creates anotherone, it overlaps the other unit… How can i make it so the units slowly spread away from eachother?
have it creat the units around the base like on a cirlcle (will require trig) then have them more in the opposite direction of the base, slowly.
I have a code that makes the units spread out, somewhere. It isn't hard.
Ludamad, can you type me up a code? Can you find the code?
Or anyone?
var thing;
instance_deactivate(self);thing=instance_nearest(x,y,object_index);instance_activate(self);if(point_distance(x,y,thing.x,thing.y)<10)motion_add(point_direction(x,y,thing.x,thing.y),0.1);That's off the top of my head, and I didn't type it into GM, so there may be typos, but it should at least give you the idea. Basically, it turns itself off, first, so instance nearest doesn't just return the unit itself, finds out which other unit (of the same type, but that's easily changed) is close, and accelerates away from it if it's <i>too</i> close. This assumes that the units have friction, otherwise, they'll just keep zooming away forever. ^_^ You can always change that, though.You so ripped off of Westwood Studios, didn't you?
Indeed you did.Hmmmm… I don't get it… But whatever, thanks for trying!
Anyone else?
Alpha man, OF COURSE he ripped of Westwood Studios! How could a rts called grid alert not be a rip off? Most of the games here are clones or use ripped sprites. there's nothing wrong with immitation games.