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! / Scrolling map (with clicking)

Author
Message
Bob the cat
18
Years of Service
User Offline
Joined: 12th Nov 2006
Location:
Posted: 6th Dec 2006 15:25
OK, ive been trying to adapt the scrolling map on codebase, so that it can recognize which box you've clicked on (v. useful for Age of Empire-type games). These are the two functions, one does the number of boxes across, the second does the number down:



it doesn’t work when you click on the far right/bottom when the screen has moved there. Any ideas would be appreciated.

I love hairballs...
Grog Grueslayer
Valued Member
19
Years of Service
User Offline
Joined: 30th May 2005
Playing: Green Hell
Posted: 7th Dec 2006 04:09
I don't understand why their separate functions. You can make it check the whole screen with for/next loops.

This isn't the code above but it's a whole example of what I think you're trying to do (making a tile map and editing it using the mouse to select the tiles). If the remarks are confusing just let me know and I'll try to explain it better.

Attachments

Login to view attachments
Ikari Gendo
18
Years of Service
User Offline
Joined: 25th Dec 2006
Location: Hungary
Posted: 26th Dec 2006 01:47
Hyder! Nice code but I was wondering that how to work it in isometric view, for example in Sim City, Caesar 3, Tycoon games, etc. Please anybody help me write this "engine". I attached one example tile in isometric view.

http://i14.photobucket.com/albums/a319/Gendi/restrained2.jpg

Attachments

Login to view attachments
Ikari Gendo
18
Years of Service
User Offline
Joined: 25th Dec 2006
Location: Hungary
Posted: 26th Dec 2006 01:48
Hyder! Nice code but I was wondering that how to work it in isometric view, for example in Sim City, Caesar 3, Tycoon games, etc. Please anybody help me write this "engine". I attached one example tile in isometric view.

http://i14.photobucket.com/albums/a319/Gendi/restrained2.jpg

Login to post a reply

Server time is: 2025-05-15 00:55:51
Your offset time is: 2025-05-15 00:55:51