SA-MP Forums Archive
Removebuildingforplayer problem. - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Removebuildingforplayer problem. (/showthread.php?tid=508332)



Removebuildingforplayer problem. - dimitri8 - 21.04.2014

Hey I've done a mapping to the All Saints and when I'm uploading it on the Filterscript it doesnt remove the object, I have the .inc in pawno of that, I'm using the includes -
Код:
#include <a_samp>
#include <streamer>

public OnFilterScriptInit()
{ 
Mapping:
I wont post the codes here lol, CreateDynamicObject
}

forward RemoveBuildings(playerid);
public RemoveBuildings(playerid)
{
	RemoveBuildingForPlayer(playerid, 5930, 1134.2500, -1338.0781, 23.1563, 0.25);
RemoveBuildingForPlayer(playerid, 5708, 1134.2500, -1338.0781, 23.1563, 0.25);
RemoveBuildingForPlayer(playerid, 1440, 1148.6797, -1385.1875, 13.2656, 0.25);
RemoveBuildingForPlayer(playerid, 1297, 1161.1563, -1390.1172, 15.6406, 0.25);
RemoveBuildingForPlayer(playerid, 617, 1178.6016, -1332.0703, 12.8906, 0.25);
RemoveBuildingForPlayer(playerid, 620, 1184.0078, -1353.5000, 12.5781, 0.25);
RemoveBuildingForPlayer(playerid, 620, 1184.0078, -1343.2656, 12.5781, 0.25);
RemoveBuildingForPlayer(playerid, 618, 1177.7344, -1315.6641, 13.2969, 0.25);
RemoveBuildingForPlayer(playerid, 620, 1184.8125, -1292.9141, 12.5781, 0.25);
RemoveBuildingForPlayer(playerid, 620, 1184.8125, -1303.1484, 12.5781, 0.25);
RemoveBuildingForPlayer(playerid, 1283, 1161.5859, -1281.3594, 15.7109, 0.25);
RemoveBuildingForPlayer(playerid, 1297, 1190.7734, -1350.4141, 15.9453, 0.25);
RemoveBuildingForPlayer(playerid, 1297, 1190.7734, -1320.8594, 15.9453, 0.25);
return 1;
}
hELP me plz. ty


Re: Removebuildingforplayer problem. - Bingo - 21.04.2014

Dont post full codes, Just show us this 'RemoveBuildingForPlayer(.......'.


Re: Removebuildingforplayer problem. - dimitri8 - 21.04.2014

Done


Re: Removebuildingforplayer problem. - Rockyyy - 21.04.2014

try to Put the "RemoveBuildingForPlayer" codes under "on player connect"


Re: Removebuildingforplayer problem. - Bingo - 21.04.2014

You cant put that under forwarding callback, Put'em under OnplayerConnect.

pawn Код:
public OnPlayerConnect(playerid)
{
RemoveBuildingForPlayer(playerid, 5930, 1134.2500, -1338.0781, 23.1563, 0.25);
RemoveBuildingForPlayer(playerid, 5708, 1134.2500, -1338.0781, 23.1563, 0.25);
RemoveBuildingForPlayer(playerid, 1440, 1148.6797, -1385.1875, 13.2656, 0.25);
RemoveBuildingForPlayer(playerid, 1297, 1161.1563, -1390.1172, 15.6406, 0.25);
RemoveBuildingForPlayer(playerid, 617, 1178.6016, -1332.0703, 12.8906, 0.25);
RemoveBuildingForPlayer(playerid, 620, 1184.0078, -1353.5000, 12.5781, 0.25);
RemoveBuildingForPlayer(playerid, 620, 1184.0078, -1343.2656, 12.5781, 0.25);
RemoveBuildingForPlayer(playerid, 618, 1177.7344, -1315.6641, 13.2969, 0.25);
RemoveBuildingForPlayer(playerid, 620, 1184.8125, -1292.9141, 12.5781, 0.25);
RemoveBuildingForPlayer(playerid, 620, 1184.8125, -1303.1484, 12.5781, 0.25);
RemoveBuildingForPlayer(playerid, 1283, 1161.5859, -1281.3594, 15.7109, 0.25);
RemoveBuildingForPlayer(playerid, 1297, 1190.7734, -1350.4141, 15.9453, 0.25);
RemoveBuildingForPlayer(playerid, 1297, 1190.7734, -1320.8594, 15.9453, 0.25);
return 1;
}



Re : Removebuildingforplayer problem. - Ramoboss - 21.04.2014

i think that he can

put this under OnPlayerConnect

pawn Код:
RemoveBuilding(playerid);
and then, go a the bottom of your gamemode and put this :

pawn Код:
stock RemoveBuilding(playerid)
{
    //PUT YOUR RemoveBuildingForPlayer here
}
if he does that, he will save a lot of RAM


Re: Re : Removebuildingforplayer problem. - BleverCastard - 21.04.2014

Quote:
Originally Posted by Ramoboss
Посмотреть сообщение
i think that he can

put this under OnPlayerConnect

pawn Код:
RemoveBuilding(playerid);
and then, go a the bottom of your gamemode and put this :

pawn Код:
stock RemoveBuilding(playerid)
{
    //PUT YOUR RemoveBuildingForPlayer here
}
if he does that, he will save a lot of RAM
Not really. You're creating yet another useless stock when you can directly paste them where they're meant to go.