SA-MP Forums Archive
[Ajuda]Save Neons - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda]Save Neons (/showthread.php?tid=225889)



[Ajuda]Save Neons - [Dk]TuReTOo - 14.02.2011

Boas pessoal, alguem me ajuda a procurar o save neon ? ja procurei na parte englesa, espanhola e na parte portuuguesa , agradeзo


Re: [Ajuda]Save Neons - rjjj - 14.02.2011

Sim, estude o tutorial abaixo para aprender o sistema de salvamento em Dini, com isso poderб salvar praticamente tudo o que vocк quiser no Pawn :

https://sampforum.blast.hk/showthread.php?tid=180237

Espero ter ajudado


Re: [Ajuda]Save Neons - Pirata - 14.02.2011

@rjjj

vlw eu tava procurando isso ai mano brigadao


Re: [Ajuda]Save Neons - Macintosh - 14.02.2011

KKKKKKKKK.
Falta mais 2 tуpicos pra ele fazer ainda hoje --'
Obs.: Fora os extras *-*


Re: [Ajuda]Save Neons - [Dk]TuReTOo - 14.02.2011

Como e que eu sei os ids dos neons ?


Код:
			//blue
			SetPVarInt(playerid, "Status", 1);
            SetPVarInt(playerid, "neon", CreateObject(18648,0,0,0,0,0,0));
            SetPVarInt(playerid, "neon1", CreateObject(18648,0,0,0,0,0,0));
            AttachObjectToVehicle(GetPVarInt(playerid, "neon"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
            AttachObjectToVehicle(GetPVarInt(playerid, "neon1"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
   			 }
			if(listitem == 1)
			{


			 //red
				SetPVarInt(playerid, "Status", 1);
	            SetPVarInt(playerid, "neon2", CreateObject(18647,0,0,0,0,0,0));
	            SetPVarInt(playerid, "neon3", CreateObject(18647,0,0,0,0,0,0));
	            AttachObjectToVehicle(GetPVarInt(playerid, "neon2"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
	            AttachObjectToVehicle(GetPVarInt(playerid, "neon3"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
	            SendClientMessage(playerid, 0xFFFFFFAA, "neon instalado");

}
			if(listitem == 2)
			{


			//green
		   	   SetPVarInt(playerid, "Status", 1);
	            SetPVarInt(playerid, "neon4", CreateObject(18649,0,0,0,0,0,0));
	            SetPVarInt(playerid, "neon5", CreateObject(18649,0,0,0,0,0,0));
	            AttachObjectToVehicle(GetPVarInt(playerid, "neon4"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
	            AttachObjectToVehicle(GetPVarInt(playerid, "neon5"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
	            SendClientMessage(playerid, 0xFFFFFFAA, "neon instalado");

	            }
			if(listitem == 3)
			{

			//white
		   	   SetPVarInt(playerid, "Status", 1);
	            SetPVarInt(playerid, "neon6", CreateObject(18652,0,0,0,0,0,0));
	            SetPVarInt(playerid, "neon7", CreateObject(18652,0,0,0,0,0,0));
	            AttachObjectToVehicle(GetPVarInt(playerid, "neon6"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
	            AttachObjectToVehicle(GetPVarInt(playerid, "neon7"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
	            SendClientMessage(playerid, 0xFFFFFFAA, "neon instalado");

}
			if(listitem == 4)
			{


			//pink
		   	   SetPVarInt(playerid, "Status", 1);
	            SetPVarInt(playerid, "neon8", CreateObject(18651,0,0,0,0,0,0));
	            SetPVarInt(playerid, "neon9", CreateObject(18651,0,0,0,0,0,0));
	            AttachObjectToVehicle(GetPVarInt(playerid, "neon8"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
	            AttachObjectToVehicle(GetPVarInt(playerid, "neon9"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
	            SendClientMessage(playerid, 0xFFFFFFAA, "neon instalado");

}
			if(listitem == 5)
			{


			//yellow
  				 SetPVarInt(playerid, "Status", 1);
	            SetPVarInt(playerid, "neon10", CreateObject(18650,0,0,0,0,0,0));
	            SetPVarInt(playerid, "neon11", CreateObject(18650,0,0,0,0,0,0));
	            AttachObjectToVehicle(GetPVarInt(playerid, "neon10"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
	            AttachObjectToVehicle(GetPVarInt(playerid, "neon11"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
	            SendClientMessage(playerid, 0xFFFFFFAA, "neon instalado");

}
			if(listitem == 6)
			{


			//police
   	 		   SetPVarInt(playerid, "Status", 1);
	            SetPVarInt(playerid, "neon12", CreateObject(18646,0,0,0,0,0,0));
	            SetPVarInt(playerid, "neon13", CreateObject(18646,0,0,0,0,0,0));
	            AttachObjectToVehicle(GetPVarInt(playerid, "neon12"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
	            AttachObjectToVehicle(GetPVarInt(playerid, "neon13"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
	            SendClientMessage(playerid, 0xFFFFFFAA, "neon instalado");

	            }

	           	if(listitem == 7)
				{
	            SetPVarInt(playerid, "Status", 1);
	            SetPVarInt(playerid, "interior", CreateObject(18646,0,0,0,0,0,0));
	            SetPVarInt(playerid, "interior1", CreateObject(18646,0,0,0,0,0,0));
	            AttachObjectToVehicle(GetPVarInt(playerid, "interior"), GetPlayerVehicleID(playerid), 0, -0.0, 0, 2.0, 2.0, 3.0);
	            AttachObjectToVehicle(GetPVarInt(playerid, "interior1"), GetPlayerVehicleID(playerid), 0, -0.0, 0, 2.0, 2.0, 3.0);
	            SendClientMessage(playerid, 0xFFFFFFAA, "Luzes no intrior instalado");

	            }
          	if(listitem == 8)
			{

			//back
	            SetPVarInt(playerid, "Status", 1);
	            SetPVarInt(playerid, "back", CreateObject(18646,0,0,0,0,0,0));
	            SetPVarInt(playerid, "back1", CreateObject(18646,0,0,0,0,0,0));
	            AttachObjectToVehicle(GetPVarInt(playerid, "back"), GetPlayerVehicleID(playerid), -0.0, -1.5, -1, 2.0, 2.0, 3.0);
	            AttachObjectToVehicle(GetPVarInt(playerid, "back1"), GetPlayerVehicleID(playerid), -0.0, -1.5, -1, 2.0, 2.0, 3.0);
	            SendClientMessage(playerid, 0xFFFFFFAA, "Back neon instalado");
	            }
            	if(listitem == 9)
				{

				//front
	            SetPVarInt(playerid, "Status", 1);
	            SetPVarInt(playerid, "front", CreateObject(18646,0,0,0,0,0,0));
	            SetPVarInt(playerid, "front1", CreateObject(18646,0,0,0,0,0,0));
	            AttachObjectToVehicle(GetPVarInt(playerid, "front"), GetPlayerVehicleID(playerid), -0.0, 1.5, -0.6, 2.0, 2.0, 3.0);
	            AttachObjectToVehicle(GetPVarInt(playerid, "front1"), GetPlayerVehicleID(playerid), -0.0, 1.5, -0.6, 2.0, 2.0, 3.0);
	            SendClientMessage(playerid, 0xFFFFFFAA, "Front neon instalado");
	            }
	            if(listitem == 10)
				{
	            //undercover
	            SetPVarInt(playerid, "Status", 1);
	            SetPVarInt(playerid, "undercover", CreateObject(18646,0,0,0,0,0,0));
	            SetPVarInt(playerid, "undercover1", CreateObject(18646,0,0,0,0,0,0));
	            AttachObjectToVehicle(GetPVarInt(playerid, "undercover"), GetPlayerVehicleID(playerid), -0.5, -0.2, 0.8, 2.0, 2.0, 3.0);
	            AttachObjectToVehicle(GetPVarInt(playerid, "undercover1"), GetPlayerVehicleID(playerid), -0.5, -0.2, 0.8, 2.0, 2.0, 3.0);
	            SendClientMessage(playerid, 0xFFFFFFAA, "Undercover lights instalado");
	            }
			if(listitem == 11)



Re: [Ajuda]Save Neons - Baddark2131 - 14.02.2011

Isso faz parte de um Dialog amigo (:


Re: [Ajuda]Save Neons - Macintosh - 14.02.2011

tenso opaskaposkaosas


Re: [Ajuda]Save Neons - [Dk]TuReTOo - 14.02.2011

tipo ja comeзei a a trabalhar no sabe tune vejao ai


pawn Код:
#include <a_samp>
#include <dini>

#if defined FILTERSCRIPT

forward TuneThisCar(vehicleid);
forward LoadModsForAll(vehicleid);
forward SaveModsForAll(vehicleid);

new neons[11][0] = {

    {18648},
    {18647},
    {18649},
    {18652},
    {18651},
    {18650},
    {18646},
    {18646},
    {18646},
    {18646},
    {18646}
};

enum tInfo

{
    neon1,
    neon2,
    neon3,
    neon4,
    neon5,
    neon6,
    neon7,
    neon8,
    neon9,
    neon10,
    neon11,
}

new neons[MAX_VEHICLES][tInfo];

public OnFilterScriptInit()
{
    print("\n--------------------------------------");
    print(" FS By Ricardo_Jorge ");
    print("--------------------------------------\n");
    return 1;
}

public OnFilterScriptExit()
{
    return 1;
}

#else

main()
{
    print("\n----------------------------------");
    print(" FS By Ricardo_Jorge");
    print("----------------------------------\n");
}

#endif

public OnGameModeInit()
{
    return 1;
}

public OnGameModeExit()
{
    return 1;
}

public OnPlayerRequestClass(playerid, classid)
{
    return 1;
}

public OnPlayerConnect(playerid)
{
    return 1;
}

public OnPlayerDisconnect(playerid, reason)
{
    return 1;
}

public OnPlayerSpawn(playerid)
{
    return 1;
}

public OnPlayerDeath(playerid, killerid, reason)
{
    return 1;
}

public OnVehicleSpawn(vehicleid)
{
    return 1;
}

public OnVehicleDeath(vehicleid, killerid)
{
    return 1;
}

public OnPlayerText(playerid, text[])
{
    return 1;
}

public OnPlayerCommandText(playerid, cmdtext[])
{
    return 0;
}

public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
    LoadModsForAll(vehicleid);
    TuneThisCar(vehicleid);
    return 1;
}

public OnPlayerExitVehicle(playerid, vehicleid)
{
    SaveModsForAll(vehicleid);
    return 1;
}

public OnPlayerStateChange(playerid, newstate, oldstate)
{
    return 1;
}

public OnPlayerEnterCheckpoint(playerid)
{
    return 1;
}

public OnPlayerLeaveCheckpoint(playerid)
{
    return 1;
}

public OnPlayerEnterRaceCheckpoint(playerid)
{
    return 1;
}

public OnPlayerLeaveRaceCheckpoint(playerid)
{
    return 1;
}

public OnRconCommand(cmd[])
{
    return 1;
}

public OnPlayerRequestSpawn(playerid)
{
    return 1;
}

public OnObjectMoved(objectid)
{
    return 1;
}

public OnPlayerObjectMoved(playerid, objectid)
{
    return 1;
}

public OnPlayerPickUpPickup(playerid, pickupid)
{
    return 1;
}

public OnVehicleMod(playerid, vehicleid, componentid)
{
    return 1;
}

public OnVehiclePaintjob(playerid, vehicleid, paintjobid)
{
    return 1;
}

public OnVehicleRespray(playerid, vehicleid, color1, color2)
{
    return 1;
}

public OnPlayerSelectedMenuRow(playerid, row)
{
    return 1;
}

public OnPlayerExitedMenu(playerid)
{
    return 1;
}

public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
{
    return 1;
}

public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
    return 1;
}

public OnRconLoginAttempt(ip[], password[], success)
{
    return 1;
}

public OnPlayerUpdate(playerid)
{
    return 1;
}

public OnPlayerStreamIn(playerid, forplayerid)
{
    return 1;
}

public OnPlayerStreamOut(playerid, forplayerid)
{
    return 1;
}

public OnVehicleStreamIn(vehicleid, forplayerid)
{
    return 1;
}

public OnVehicleStreamOut(vehicleid, forplayerid)
{
    return 1;
}

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
    return 1;
}

public OnPlayerClickPlayer(playerid, clickedplayerid, source)
{
    return 1;
}

public TuneThisCar(vehicleid)
{
        if(TuneCar[vehicleid][neon1]!=0) { AddVehicleComponent(vehicleid,TuneCar[vehicleid][mod1]); }
        if(TuneCar[vehicleid][neon2]!=0) { AddVehicleComponent(vehicleid,TuneCar[vehicleid][mod2]); }
        if(TuneCar[vehicleid][neon3]!=0) { AddVehicleComponent(vehicleid,TuneCar[vehicleid][mod3]); }
        if(TuneCar[vehicleid][neon4]!=0) { AddVehicleComponent(vehicleid,TuneCar[vehicleid][mod4]); }
        if(TuneCar[vehicleid][neon5]!=0) { AddVehicleComponent(vehicleid,TuneCar[vehicleid][mod5]); }
        if(TuneCar[vehicleid][neon6]!=0) { AddVehicleComponent(vehicleid,TuneCar[vehicleid][mod6]); }
        if(TuneCar[vehicleid][neon7]!=0) { AddVehicleComponent(vehicleid,TuneCar[vehicleid][mod7]); }
        if(TuneCar[vehicleid][neon8]!=0) { AddVehicleComponent(vehicleid,TuneCar[vehicleid][mod8]); }
        if(TuneCar[vehicleid][neon9]!=0) { AddVehicleComponent(vehicleid,TuneCar[vehicleid][mod9]); }
        if(TuneCar[vehicleid][neon10]!=0) { AddVehicleComponent(vehicleid,TuneCar[vehicleid][mod10]); }
        if(TuneCar[vehicleid][neon11]!=0) { AddVehicleComponent(vehicleid,TuneCar[vehicleid][mod11]); }

ainda nao ta completo mas dame estes erros


Код:
C:\Users\Ricardo\Desktop\Server Sa-mp 0.3c\filterscripts\SaveNeon.pwn(124) : error 017: undefined symbol "LoadModsForAll"
C:\Users\Ricardo\Desktop\Server Sa-mp 0.3c\filterscripts\SaveNeon.pwn(131) : error 017: undefined symbol "SaveModsForAll"
C:\Users\Ricardo\Desktop\Server Sa-mp 0.3c\filterscripts\SaveNeon.pwn(260) : warning 235: public function lacks forward declaration (symbol "TuneThisCar")
C:\Users\Ricardo\Desktop\Server Sa-mp 0.3c\filterscripts\SaveNeon.pwn(262) : error 017: undefined symbol "TuneCar"
C:\Users\Ricardo\Desktop\Server Sa-mp 0.3c\filterscripts\SaveNeon.pwn(262) : warning 215: expression has no effect
C:\Users\Ricardo\Desktop\Server Sa-mp 0.3c\filterscripts\SaveNeon.pwn(262) : error 001: expected token: ";", but found "]"
C:\Users\Ricardo\Desktop\Server Sa-mp 0.3c\filterscripts\SaveNeon.pwn(262) : error 029: invalid expression, assumed zero
C:\Users\Ricardo\Desktop\Server Sa-mp 0.3c\filterscripts\SaveNeon.pwn(262) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


6 Errors.
agradeзo..