RemoveBuildingForPlayer
From SA-MP Wiki
(Difference between revisions)
Revision as of 02:28, 4 December 2012 Smithy (Talk | contribs) ← Previous diff |
Revision as of 18:49, 27 December 2012 Ikkentim (Talk | contribs) (removed rather an advertisement for an include than a 'note') Next diff → |
||
Line 15: | Line 15: | ||
{{NoReturn}} | {{NoReturn}} | ||
- | |||
- | {{note|You cannot natively restore objects removed with RemoveBuildingForPlayer, however the Global Remove Building include produced by funky1234 (link below) supports this by using server-sided objects.}} | ||
- | {{note2|When an object is removed, the LOD (low detail, 'blurred') version of said object will appear. These must also be removed. JernejL's Map Editor support this (link below).}} | ||
- | |||
- | funky1234's Global Remove Building include: http://forum.sa-mp.com/showthread.php?p=1551937 | ||
JernejL's Map Editor: http://forum.sa-mp.com/showthread.php?t=282801 | JernejL's Map Editor: http://forum.sa-mp.com/showthread.php?t=282801 |
Revision as of 18:49, 27 December 2012
Description:
Removes a standard San Andreas model for a single player within a specified range.
(playerid, modelid, Float:fX, Float:fY, Float:fZ, Float:fRadius)
playerid | The ID of the player to remove the objects for. |
modelid | The model to remove. |
Float:fX | The X coordinate around which the objects will be removed. |
Float:fY | The Y coordinate around which the objects will be removed. |
Float:fZ | The Z coordinate around which the objects will be removed. |
Float:fRadius | The radius. Objects within this radius from the coordinates above will be removed. |
Return Values:
This function does not return any specific values.
JernejL's Map Editor: http://forum.sa-mp.com/showthread.php?t=282801
public OnPlayerConnect(playerid) { // When the player connects model "615" which is veg_tree3 will be deleted within a range of 200.0 // from the point: 0.0, 0.0, 0.0, which is the center of San Andreas. RemoveBuildingForPlayer(playerid, 615, 0.0, 0.0, 0.0, 200.0); return 1; }
Related Functions
The following functions may be useful, as they are related to this function in one way or another.
- DestroyObject: Destroy an object.
- DestroyPlayerObject: Destroy a player object.