Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

2D All the way! / Lemmings?

Author
Message
Fa1con
17
Years of Service
User Offline
Joined: 20th Aug 2007
Location:
Posted: 17th Oct 2007 03:52
allright so i dont no if anyone has ever played lemmings but if they have, does anyone know how to make you able to click on an item, thn your cursor be that item, and then when you click itll go there?
thanks
demons breath
21
Years of Service
User Offline
Joined: 4th Oct 2003
Location: Surrey, UK
Posted: 17th Oct 2007 10:34
Never tried it but I would assume:

1. When the mouse is clicked, if it's not already in an , get it's position (then repeat : until mouseclick()=0)
2. If it is over anything, change a variable so that it knows that the current mode is building, or digging, or whatever it is
3. Detect the current mode and paste the appropriate sprite at the mouse position. Then set the mouse variable back to 0.

Shouldn't be too hard. Just remember to create sprites every time, not just re-use the old ones, or it'll just move the sprites that are out every time.

http://jamesmason01.googlepages.com/index.htm

Login to post a reply

Server time is: 2025-05-14 14:09:10
Your offset time is: 2025-05-14 14:09:10