Hey to all!
I'm trying to make a tile-based game map in much the same fashion as the old Space Merchants game and others where you moved your ship around from sector to sector.
However, my research has proven to be fairly futile at this point. I came up with one method, but it's not the best and I've had no luck getting movement working beyond
displaying the player sprite. This is not an isometric tile map - just a standard 500px * 500px with tiles 50-50px in size. This is an addition to an already existing website, so
I don't really need things like login/logout/etc.
Could anyone offer some advice or examples/samples of code - or maybe point to a tutorial? I keep coming up with Actionscript examples, not PHP.
Tile-Based Game Map
Moderator: General Moderators
Re: Tile-Based Game Map
If it's real-time or even turn-based you shouldn't rely on just PHP, because you'd have to refresh the page every time something happens. Your best bet is probably to use AJAX (Javascript with PHP) in order to update game information and also move the pieces around without refreshing the page.
Re: Tile-Based Game Map
That's the plan, pretty much. It's not wholly real-time but I was planning on doing the movement with AJAX/jQuery. I'm not sure if the map should be done in pure Javascript or displayed with PHP. As said, I got a primitive version of PHP display working but it's very tough to grab the right information from for JS - what type of tile, player position, etc.