SA-MP Forums Archive
[Help]Command /setforsale - 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: [Help]Command /setforsale (/showthread.php?tid=352756)



[Help]Command /setforsale - Henry_Martinez - 20.06.2012

Код HTML:
command(setforsale, playerid, params[])
{
	new i, price, string[256];
    if(Player[playerid][CarLinkID])
	{
	    if(sscanf(params, "dd", i, price)) return SendClientMessage(playerid, GREY, "Server: /setforsale [Vehicle ID(Get the ID through /dl)] [Price]");
	    {
            format(string, sizeof(string), "You have set vehicle ID: %d for sale at the price of %d", i, price);
	        SendClientMessage(playerid, GREY, string);
	        format(string, sizeof(string), "For Sale\nPrice: %d\nCall 118 to purchase it.", price);
	        vehicle3Dtext = Create3DTextLabel(string, WHITE, 0.0, 0.0, 0.0, 50.0, 0, 1);
	        Attach3DTextLabelToVehicle(vehicle3Dtext, 21, 0.0, 0.0, 2.0);
		}
	}
	else return SendClientMessage(playerid, GREY, "You are not in the correct Faction.");
	return 1;
}
Some who when i type that command, the Create3DTextLabel Won't show up. Any idea's?


Re: [Help]Command /setforsale - Henry_Martinez - 21.06.2012

dump.


Re: [Help]Command /setforsale - [MM]RoXoR[FS] - 21.06.2012

pawn Код:
Attach3DTextLabelToVehicle(vehicle3Dtext, 21, 0.0, 0.0, 2.0);
Change to

pawn Код:
Attach3DTextLabelToVehicle(vehicle3Dtext, i, 0.0, 0.0, 2.0);