Advertisement

Sprite automation.

Started by November 08, 2000 08:25 PM
1 comment, last by SikCiv 24 years, 2 months ago
Where can I get some information relating to sprite automation? My game is a 2D platformer and I would like some sprites to wander the level automatically. They would have to be able to detect things like slopes, ledges, other sprites, etc... I have a basic idea on how to do it. My guess is that I should split the level up into smaller rectangles probably the size of the screen, and have an array of all the objects in each rectangle. When the sprite comes to a certain object, it would react with it depending on the type of object it is. I know its alot of work, but ill figure it out. But I just dont want to jump into the coding (like ive done many times before unfortunately). I have a piece of paper with no contrast of color yet... if anyone has done something similar before, i''d like to know how u designed the system. Thanks.

  Downloads:  ZeroOne Realm

Umm, just make a structure where the sprite is an ''object'' and have it know its world cordinates i.e consider the whole level a gigiantic ''screen'' then all you have to check is colliosn with other objects kinda
HardDrop - hard link shell extension."Tread softly because you tread on my dreams" - Yeats
Advertisement
Yeah but the mothod described by SikCiv would most likely be faster if the world had many objects...

He could reduce the collision checking to the objects in one of the rectangles...



Edited by - granat on November 9, 2000 6:38:52 AM
-------------Ban KalvinB !

This topic is closed to new replies.

Advertisement