Jump to content

[REL] Race map loader (only loads objects) (updated).


iam2noob4u

Recommended Posts

This resource will load the objects (tested) and show the metadata at start and on join (half-tested). It also loads the weather (not tested, in the script it says it doesn't work, but it might work). Also it can spawn players automaticly (spawn will have a small delay!).

However, there is also an option to only load the objects and do nothing more (that is where it originally was created for). The default map is an unfinished race.

Unrar the resource in the resources folder, and put maps in that folder (so you will have default.map, mymap.map mystuntmap.map in the same folder as the script), etc.

You only have to use refresh when you added the resource, no need to do so when a map is added.

After that, just type "/startmap mymap.map full" (without the quotes) to load the map - including spawnpoints, IF YOU'RE RUNNING BROPH: both resources will respawn: mine does it later, so it should work. If you only want to load the objects, replace "full" with "objectsonly" (again, without the quotes).

I haven't added any commands to the ACL list yet, but if you know how to do it, you should try restricting the startmap function.

Any suggestions are welcome :)

Download: here.

Edit: I should really thank all the people who helped me on the IRC (mainly with the XML functions).

~ Iam2noob4u

Edited by Guest
Link to comment

Does this script only spawn the objects of a map like in the MTA Race map editor? If yes is there a way to let spawn one of my stunt maps in the freeroam mode (broph) ? I tried to copy the objects etc from mystuntmap.map to broph.map but there came an error. would be nice if my map works in the broph mode. I downloaded your script and replaced the default.map with my stunt map ... then I added it into the resources folder and added it into the mtaserver.conf to start it at startup. But the script isnt loaded in the adminpanel ;S

Link to comment

wtf :o ... it was all so buggy that i reinstalled the server. but he can't find the resource now!? whats wrong here now?

wtfjy7.th.jpg

and when he finds the resource just type ingame /startmap default.map when the broph.map runs? or must i add the code into the broph.map? cuz then i got an error >_<

btw i changed the code of the default.map with that from my stuntmap. i didn't change the default.map name so... wst ;S?

Link to comment

Unrar the resource in the resources folder, and put maps in that folder (so you will have default.map, mymap.map mystuntmap.map in the same folder as the script), etc.

You only have to use refresh when you added the resource, no need to do so when a map is added.

After that, just type "/startmap mymap.map full" (without the quotes) to load the map - including spawnpoints, IF YOU'RE RUNNING BROPH: both resources will respawn: mine does it later, so it should work. If you only want to load the objects, replace "full" with "objectsonly" (again, without the quotes).

If you already have the resource, redownload it (the full and objectsonly parts of the command only work with the newest version).

Link to comment
Doesn't the race resource already do this?

Yes it does - you don't have do any of the above. When I started I looked at the race doing this manually but then found the map manager. You don't need handle objects / pickups / the weather etc.

Link to comment
Doesn't the race resource already do this?

When I start the server the following resources will be loaded:

startingresourcesne3.th.jpg

And when I join I spawn at the spawnpoints of the "broph" resource o_O. The maploader-resource is loaded but my map isn't. So I loaded it manually and it spawned. If I type /kill I first spawn at the spawn of my own map and one second later I get spawned at the spawnpoint of broph. So I've setted it to "objectsonly". That works now but I think the server doesn't know how to load my own map and spawn me at joining there not at broph. But I haven't added the broph-resource to the loaded resources at staring the server :shock: ...

Maybe it works when I find that resource which let me spawn at the broph-resource and delete all the spawnpoints... then I could set my map to "full" again and the server would spawn me at my map. But the biggest problem is that my own map isn't loaded at starting.

greetz ruschiiiiii

maybe bad english but i dont care :D

Link to comment
And when I join I spawn at the spawnpoints of the "broph" resource o_O. The maploader-resource is loaded but my map isn't. So I loaded it manually and it spawned. If I type /kill I first spawn at the spawn of my own map and one second later I get spawned at the spawnpoint of broph. So I've setted it to "objectsonly". That works now but I think the server doesn't know how to load my own map and spawn me at joining there not at broph. But I haven't added the broph-resource to the loaded resources at staring the server :shock: ...

Maybe it works when I find that resource which let me spawn at the broph-resource and delete all the spawnpoints... then I could set my map to "full" again and the server would spawn me at my map. But the biggest problem is that my own map isn't loaded at starting.

The spawning worked fine for me (even with broph running). Didn't try on join though... but that should work too (it's also delayed 3 seconds). For automaticly loading one map, remove or rename default.map, and name your map default.map. If you don't want to run any other maps, try commenting

addCommandHandler("startmap",loadmap,true) 

, and just start/stop the resource for loading the map. Also, you can always turn broph off I guess...

Doesn't the race resource already do this?

Well this is created to only load the objects, not run the whole race, or do a freeroam mode (although the last is possible). As far as I know race doesn't have the option to do so (correct me if I'm wrong... then I made a useless resource xD).

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

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