Jump to content

object removing question


Salem

Recommended Posts

Posted

Need some tip for removing special type of object from the main world. Namely, I have problem with these little sand palms (joshuas) to remove em using function removeWorldModel( ... ). Four models: 676, 681, 858, 904 included. Everything besides is ok. Who knows some working solution? Btw. they appear in game in quite different way and times than other objects.

My race maps available here: http://chomikuj.pl/salemander/mta+maps

Posted

You can enter map editor and remove the objects '-' after you can save the map, add it to the gamemode's XML and to the gamemode itself and there :P GL

Datastore - Store data to a database quickly. (Useful for saving scripted tables)

Posted

I don't get it. I need these objects to be removed while playing map on the server, not in map editor. I create script to remove objects and add it to the zip file (with map) as 'oremover.lua' in the way like this:

addEventHandler("onResourceStart", resourceRoot, function()

removeWorldModel( 676, 60, 873, 1709, 7 )

removeWorldModel( 681, 60, 873, 1709, 7 )

removeWorldModel( 858, 60, 873, 1709, 7 )

removeWorldModel( 904, 60, 873, 1709, 7 )

....

end)

addEventHandler("onResourceStop", resourceRoot, function()

restoreAllWorldModels()

end)

And for these palms it doesn't work.

My race maps available here: http://chomikuj.pl/salemander/mta+maps

Posted

Are you sure the model/position/radius are correct?

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

Posted

Yep. Why couldn't be sure? Tested it in many places, not also of this mentioned above. If there's some error in my script it could be different model number of identical object, I'll check it oyt, but these objects look like being loaded client-side. Hmm. Ok, I'll try to use it client-side. :P

My race maps available here: http://chomikuj.pl/salemander/mta+maps

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...