Posts: 195
Threads: 52
Joined: Feb 2014
Reputation:
0
I have some mapping that is partly above water and partly underwater. Is there any way I can set the object to only be seen above ground? So the part above water can be seen when you are not in the water and the part below water can only be seen when you are underwater?
Posts: 1,801
Threads: 21
Joined: Mar 2008
Reputation:
0
I could make a little script for you, but it will be pretty inefficient if there are many objects below the water level.
But this could be buggy, because we do only have one coordinate for an object, meaning it would fully disappear if the center is below 0.0 (Z) - but they could be made invisible, so its collision is still there.
Posts: 111
Threads: 24
Joined: Aug 2014
Reputation:
0
can i know the map editor are u using to make that map (mta map editor or other map editor)
Posts: 3,324
Threads: 96
Joined: Sep 2013
Quote:
Originally Posted by semara123
can i know the map editor are u using to make that map (mta map editor or other map editor)
|
How is this relevant?
Anyways, I don't understand what you mean. Like do you want it to only stream when you're in water (and vice versa)? Or is it an object flag bug, like when object id 18754 and 18753 are underwater (they appear like they are above water and water is invisible).
Posts: 1,801
Threads: 21
Joined: Mar 2008
Reputation:
0
Well, as long as the player is above the water (z > 0.0), the objects that should be invisible above water are made invisible (Using SetObjectMaterial). And when he gets below 0.0, they are set to the normal textures.
But as I said that is a lot of work for the cpu if there are many players and/or objects, since the objects must be visible per-player.
If this is what you mean. If you mean the bug, it could be worked-around with the above mentioned script, but would be ugly.
Posts: 3,324
Threads: 96
Joined: Sep 2013
Quote:
Originally Posted by NaS
Well, as long as the player is above the water (z > 0.0), the objects that should be invisible above water are made invisible (Using SetObjectMaterial). And when he gets below 0.0, they are set to the normal textures.
But as I said that is a lot of work for the cpu if there are many players and/or objects, since the objects must be visible per-player.
If this is what you mean. If you mean the bug, it could be worked-around with the above mentioned script, but would be ugly.
|
That would not be a good way to work around it, especially if some of the objects are half way out - half way in.
I don't like this either, it's not really a bug though. They (Rockstar and SA-MP) just need to use the right flags when creating objects. They must've had a reason for this to be possible though.