Jump to content

Preview MTASA maps in your web browser


Guest spii

Recommended Posts

Want to preview maps on the web? Here's a demo of how it can be accomplished:

http://inspire.server101.com/spi/MTA-map-previewer/

ps: if you use Internet Explorer, it ain't gonna look as a good as in a swish browser like firefox! 8)

These are just the maps that came with MTASA. The only change I made to the *.map files was to point it at the XSLT file like so:

<?xml-stylesheet type="text/xsl" href="style/mtasa-map.xsl"?>

All my code is in the XSL, CSS and javascript files. You can check that out here: http://inspire.server101.com/spi/MTA-ma ... wer/style/

Grab the zip if you want to extend it. Go nuts!

Link to comment
Want to preview maps on the web? Here's a demo of how it can be accomplished:

http://inspire.server101.com/spi/MTA-map-previewer/

ps: if you use Internet Explorer, it ain't gonna look as a good as in a swish browser like firefox! 8)

These are just the maps that came with MTASA. The only change I made to the *.map files was to point it at the XSLT file like so:

<?xml-stylesheet type="text/xsl" href="style/mtasa-map.xsl"?>

All my code is in the XSL, CSS and javascript files. You can check that out here: http://inspire.server101.com/spi/MTA-ma ... wer/style/

Grab the zip if you want to extend it. Go nuts!

Blank pages on IE.

Edited by Guest
Link to comment

Just a note on hot route: the easy ways across SA are blocked because they make it much less entertaining, so most of those objects are dedicated to blocking off the highways and railroad tracks/bridges.

I like this little tool but the objects as large semi-transparent black boxes isn't very good. If you could pinpoint them as red dots it would be nicer.

Also feels like the route tracer should go about half as fast as its blazing atm :P

Nice work.

Link to comment

Thanks guys.

Sorry about IE showing nothing, I've fixed that. Something with the script tag being written by XSLT was throwing it. Script isn't working either. Feel free to hack into the code... it seems to be choking on hasAttribute('class') at the moment.

If you can't see any change try holding Shift (or is it Ctrl?) when reloading to clear your cache.

It's still not real good in IE as it relies on transparent PNG files. If the checkpoints are spaced out it's not too bad: http://inspire.server101.com/spi/MTA-ma ... 0Round.map

But if they are close together, it's not much use:

http://inspire.server101.com/spi/MTA-ma ... 20Park.map

(it does give you a general indication of the race location though).

I've also slowed it down (300ms increments) and swapped the object "blocks" for dots. It's not clear what the objects are... trees? walls? buildings? That could all be coded into the XSL file (if someone has the time) but be difficult to handle the rotation angles. Still, if someone is keen enough to hava crack at it, there is bound to be a way!

ps: I anticipate this will work much better when IE7 is released. At least I hope so :D

Link to comment

The MTA center already has one - click on the "View" button. I only noticed this today, but it's very cool. All rendered as an image so it will work in all browsers. Different, but cool :D

I'd really like to adapt the one I did to provide a live "race cam" on the web... could be done with AJAX. But I don't have time, there's racing to be done! :shock:

Link to comment
The MTA center already has one - click on the "View" button. I only noticed this today, but it's very cool. All rendered as an image so it will work in all browsers. Different, but cool :D

I'd really like to adapt the one I did to provide a live "race cam" on the web... could be done with AJAX. But I don't have time, there's racing to be done! :shock:

no offense to the MTA center but your checkpoints, and all that stuff look better than the ones they used, their map looks better though.

Link to comment

very nice indeed, great to be able to browse all 70 release maps in this way as only the truly addicted with too much time on thier hands will have played them all in most servers :)

Any chance of an uploader so people can show others thier work?

Link to comment

no offense to the MTA center but your checkpoints, and all that stuff look better than the ones they used, their map looks better though.

I agree you pinpoint things better and have a route tracer for those maps with tons of cps. If you asked for Ians permission to use that high quality map and made some sort of handy download I'd use this for sure.

Link to comment

Alrighty, I'll see what I can do

There are some things I really like about the Blue Center maps: the way it is zoomed in on the race area for starters, Ian's map is fantastic, the flags for race start/end are a nice touch and of course, the fact it works in more browsers than just firefox.

So no promises. But I'll see if I can improve things. If anyone knows XSLT, CSS and javascript well (SVG might be good too) and wants to help, let me know :D

Link to comment
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...