RemoveBuildingForPlayer bug
#1

Hey,

I've lately used RemoveBuildingForPlayer to allow players sail in the LV pirate ship.
My code is removing the exist pirate ship objects, and creates new ones that i'll be able to control.

Anyway, i've noticed that when using RemoveBuildingForPlayer on a specific modelid, he will not see ANY object (game or script object) with the specific modelid. However, the player will see objects with the same modelid if i'll create them after using RemoveBuildingForPlayer on him.
I'm not sure if it's really a bug, but anyway, I guess that it will cause some players to see specific objects and some other players will not see it. Depends on if the CreateObject() used when they're in-game.
Reply
#2

Wait, what? Use the map editor.
Reply
#3

Quote:
Originally Posted by MP2
Посмотреть сообщение
Wait, what? Use the map editor.
Wait, what? Read my post again. There's a bug using RemoveBuildingForPlayer, the way of creating it doesn't matter here.
Reply
#4

Well yeah, RemoveBuildingForPlayer removes all models, it doesn't know/care if it's a static object or a created one. Not a bug. Use RemoveBuildingForPlayer in OnPlayerConnect and create the objects using a streamer.
Reply
#5

Quote:
Originally Posted by MP2
Посмотреть сообщение
Well yeah, RemoveBuildingForPlayer removes all models, it doesn't know/care if it's a static object or a created one. Not a bug. Use RemoveBuildingForPlayer in OnPlayerConnect and create the objects using a streamer.
That's what i've just meant. Even if i'll create objects with streamer, they'll still will not be visible to players who connecting the server. However, object will be visible to player when creating it after using RemoveBuildingForPlayer() on the player. That will cause some players to see the object and some others not, depends on when the object created.
Reply
#6

Quote:
Originally Posted by Amit_B
Посмотреть сообщение
That's what i've just meant. Even if i'll create objects with streamer, they'll still will not be visible to players who connecting the server. However, object will be visible to player when creating it after using RemoveBuildingForPlayer() on the player. That will cause some players to see the object and some others not, depends on when the object created.
Make sure the new objects are created (or streamed with the Streamer Plugin) after RemoveBuildingForPlayer, not before. It might help to spawn the player far away from the pirate ship when he connects, so RemoveBuildingForPlayer isn't conflicting with the Streamer?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)