SA-MP Forums Archive
Dini save help! - 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: Dini save help! (/showthread.php?tid=503619)



Dini save help! - Slicebook - 30.03.2014

How to save it? dini or msql ?help!
(shownametagplayer)

Код:
if(egyezik(cmd, "/bemutatkozbeta") || egyezik(cmd, "/bemutatkozbeta"))
	{
		new ID;
		#pragma tabsize 0
		//new string[200];
		new Float:X, Float: Y, Float:Z;
                new nev[MAX_PLAYER_NAME];
		if(sscanf(cmdtext, "u", ID)) return SendClientMessage(playerid, -1, "Hasznбlat: /bemutatkoz ID/Nйv");
		GetPlayerPos(playerid, X, Y, Z);
		if(!IsPlayerInRangeOfPoint(ID, 5.0, X, Y, Z)) return SendClientMessage(playerid, -1, "Nincs a megadott jбtйkos a kцzeledben!");
		SendClientMessage(playerid, -1, "Bemutatkoztбl valakinek!");
		GetPlayerName(playerid, nev, 24);
		format( string, sizeof ( string ), "Ьdv! Йn %s vagyok!", nev);
		SendClientMessage( ID, -1, string );
		ShowPlayerNameTagForPlayer(playerid, ID, true);
		return 1;
	}
	if(egyezik(cmd, "/bemutatkozbeta2") || egyezik(cmd, "/bemutatkozbeta2"))
	{
		new ID;
		#pragma tabsize 0
		//new string[200];
		new Float:X, Float: Y, Float:Z;
		new nev2[MAX_PLAYER_NAME];
		if(sscanf(cmdtext, "u", ID)) return SendClientMessage(playerid, -1, "Hasznбlat: /bemutatkoz ID/Nйv");
		GetPlayerPos(playerid, X, Y, Z);
		if(!IsPlayerInRangeOfPoint(ID, 5.0, X, Y, Z)) return SendClientMessage(playerid, -1, "Nincs a megadott jбtйkos a kцzeledben!");
		SendClientMessage(playerid, -1, "Bemutatkoztбl valakinek!");
		GetPlayerName(ID, nev2, 24);
		format( string, sizeof ( string ), "Ьdv! Йn %s vagyok!", nev2);
		SendClientMessage( ID, -1, string );
		ShowPlayerNameTagForPlayer(playerid, ID, true);
		return 1;
	}



Re: Dini save help! - RenovanZ - 30.03.2014

Make a variable, when the player toggle the name tag on set it to 1/true, else set it to 0/false, then store it to dini or whateva.