Jump to content
  • 0

[GF/RP] Probleme /Bandana


AleX1321

Question

20 answers to this question

Recommended Posts

[pawn]if(strcmp(cmdtext, "/bandana", true) == 0)

{

if(PlayerInfo[playerid][pDonateRank] > 2)

{

ShowPlayerDialog(playerid,bandana,DIALOG_STYLE_LIST,"Bandana","Bandana 1\nBandana 2\nBandana 3\nBandana 4\nBandana 5\nBandana 6\nBandana 7\nBandana 8\nBandana 9\nBandana 10\nRemove Bandana","OK","");

}else{

//Mesaj care sa apara daca nu e

}

return 1;

}[/pawn]

Stiu si eu ... branza e pe bani, dar eu tot ma joc pe gratis!

Link to comment
Share on other sites

primesc erori

C:\Users\AleX\Desktop\svs\filterscripts\bandana.pwn(17) : error 017: undefined symbol "PlayerInfo"

C:\Users\AleX\Desktop\svs\filterscripts\bandana.pwn(17) : warning 215: expression has no effect

C:\Users\AleX\Desktop\svs\filterscripts\bandana.pwn(17) : error 001: expected token: ";", but found "]"

C:\Users\AleX\Desktop\svs\filterscripts\bandana.pwn(17) : error 029: invalid expression, assumed zero

C:\Users\AleX\Desktop\svs\filterscripts\bandana.pwn(17) : fatal error 107: too many error messages on one line

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

4 Errors.

Link to comment
Share on other sites

primesc erori

C:\Users\AleX\Desktop\svs\filterscripts\bandana.pwn(17) : error 017: undefined symbol "PlayerInfo"

C:\Users\AleX\Desktop\svs\filterscripts\bandana.pwn(17) : warning 215: expression has no effect

C:\Users\AleX\Desktop\svs\filterscripts\bandana.pwn(17) : error 001: expected token: ";", but found "]"

C:\Users\AleX\Desktop\svs\filterscripts\bandana.pwn(17) : error 029: invalid expression, assumed zero

C:\Users\AleX\Desktop\svs\filterscripts\bandana.pwn(17) : fatal error 107: too many error messages on one line

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

4 Errors.

Primesti acele erori pentru ca nu ai enumerat informatile playerului , pInfo , sau in cazul tau , PlayerInfo.

Link to comment
Share on other sites

Incearca sa adaugi asta in script :

[pawn]enum pInfo

{

    // Enumerarile :

    pCash,

    pScore

    // Schimbi tu enumerarile cu ce enumerari ai nevoie.

}

new PlayerInfo[MAX_PLAYERS][pInfo];[/pawn]

Si cu ce l-ar ajuta pCash si pScore?

Daca copiezi ai grija sa si editezi

[pawn]enum{

pDonateRank

};

new PlayerInfo[MAX_PLAYERS][pInfo];[/pawn]

Si nu o sa mearga,pune tot in gamemode si nu vei avea probleme.

gXvsYS
Link to comment
Share on other sites

Si cu ce l-ar ajuta pCash si pScore?

Daca copiezi ai grija sa si editezi

[pawn]enum{

pDonateRank

};

new PlayerInfo[MAX_PLAYERS][pInfo];[/pawn]

Si nu o sa mearga,pune tot in gamemode si nu vei avea probleme.

Eu doar am dat un exemplu.I-am zis sa modifice enumerarile cu ce are el nevoie.

Nu puteti sa mi-l faceti voi direct va rog? sunt incepator in scripting si nu stiu,va rog frumos

Adauga la inceputul scriptului asta :

[pawn]enum pInfo

{

    pDonateRank

}

new PlayerInfo[MAX_PLAYERS][pInfo];[/pawn]

sau asa :

[pawn]enum{

    pDonateRank

};

new PlayerInfo[MAX_PLAYERS][pInfo];[/pawn]

Link to comment
Share on other sites

[pawn]#include <a_samp>

#define bandana 1000

enum pInfo

{

    pDonateRank

}

new PlayerInfo[MAX_PLAYERS][pInfo];

#define MAX_PLAYER_ATTACHED_OBJECTS 5

#define SetPlayerHoldingObject(%1,%2,%3,%4,%5,%6,%7,%8,%9,%10) SetPlayerAttachedObject(%1,MAX_PLAYER_ATTACHED_OBJECTS-1,%2,%3,%4,%5,%6,%7,%8,%9,%10)

#define StopPlayerHoldingObject(%1) RemovePlayerAttachedObject(%1,MAX_PLAYER_ATTACHED_OBJECTS-1)

#define IsPlayerHoldingObject(%1) IsPlayerAttachedObjectSlotUsed(%1,MAX_PLAYER_ATTACHED_OBJECTS-1)

main()

{

print("[FS]Hold Bandana by Lucian.");

}

    public OnPlayerCommandText(playerid, cmdtext[])

    {

  if(strcmp(cmdtext, "/bandana", true) == 0)

    {

    ShowPlayerDialog(playerid,bandana,DIALOG_STYLE_LIST,"Bandana","Bandana 1\nBandana 2\nBandana 3\nBandana 4\nBandana 5\nBandana 6\nBandana 7\nBandana 8\nBandana 9\nBandana 10\nRemove Bandana","OK","");

return 1;

}

return 0;

}

    public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])

    {

if(dialogid==bandana)

{

if(response)

{

if(listitem==0)

{

            SetPlayerAttachedObject( playerid, 0, 18917, 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==1)

{

            SetPlayerAttachedObject( playerid, 0, 18913, 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==2)

{

            SetPlayerAttachedObject( playerid, 0, 18916, 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==3)

{

            SetPlayerAttachedObject(playerid, 0, 18915, 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==4)

{

            SetPlayerAttachedObject(playerid, 0, 18912 , 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==5)

{

            SetPlayerAttachedObject(playerid, 0, 18911 , 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==6)

{

            SetPlayerAttachedObject( playerid, 0, 18914, 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==7)

{

            SetPlayerAttachedObject(playerid, 0, 18918, 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==8)

{

            SetPlayerAttachedObject(playerid, 0, 18920 , 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==9)

            {

            SetPlayerAttachedObject(playerid, 0, 18919 , 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==10)

{

            for(new i;i<5;i++) RemovePlayerAttachedObject(playerid,i);

}

}

        return 1;

}

        return 0;

}

public OnGameModeExit()

{

for(new i=0;i<MAX_PLAYERS;i++)

    if(IsPlayerConnected(i))

StopPlayerHoldingObject(i);

return 0;

}[/pawn]

Link to comment
Share on other sites

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(11) : warning 201: redefinition of constant/macro (symbol "MAX_PLAYER_ATTACHED_OBJECTS")

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(20) : error 025: function heading differs from prototype

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(20) : error 029: invalid expression, assumed zero

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(22) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(25) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(28) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(30) : error 025: function heading differs from prototype

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(30) : error 029: invalid expression, assumed zero

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(32) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(34) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(36) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(40) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(44) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(48) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(52) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(56) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(60) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(64) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(68) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(72) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(76) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(78) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(81) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(83) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(94) : warning 203: symbol is never used: "PlayerInfo"

Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase

23 Errors.

Link to comment
Share on other sites

[pawn]#include <a_samp>

#define bandana 1000

enum pInfo

{

pDonateRank

}

new PlayerInfo[MAX_PLAYERS][pInfo];

#define SetPlayerHoldingObject(%1,%2,%3,%4,%5,%6,%7,%8,%9,%10) SetPlayerAttachedObject(%1,MAX_PLAYER_ATTACHED_OBJECTS-1,%2,%3,%4,%5,%6,%7,%8,%9,%10)

#define StopPlayerHoldingObject(%1) RemovePlayerAttachedObject(%1,MAX_PLAYER_ATTACHED_OBJECTS-1)

#define IsPlayerHoldingObject(%1) IsPlayerAttachedObjectSlotUsed(%1,MAX_PLAYER_ATTACHED_OBJECTS-1)

main()

{

print("[FS]Hold Bandana by Lucian.");

}

public OnPlayerCommandText(playerid, cmdtext[])

{

if(strcmp(cmdtext, "/bandana", true) == 0)

{

    if(PlayerInfo[playerid][pDonateRank] > 1)

    {

ShowPlayerDialog(playerid,bandana,DIALOG_STYLE_LIST,"Bandana","Bandana 1\nBandana 2\nBandana 3\nBandana 4\nBandana 5\nBandana 6\nBandana 7\nBandana 8\nBandana 9\nBandana 10\nRemove Bandana","OK","");

}

return 1;

}

return 0;

}

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])

{

if(dialogid==bandana)

{

if(response)

{

if(listitem==0)

{

SetPlayerAttachedObject( playerid, 0, 18917, 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==1)

{

SetPlayerAttachedObject( playerid, 0, 18913, 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==2)

{

SetPlayerAttachedObject( playerid, 0, 18916, 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==3)

{

SetPlayerAttachedObject(playerid, 0, 18915, 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==4)

{

SetPlayerAttachedObject(playerid, 0, 18912 , 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==5)

{

SetPlayerAttachedObject(playerid, 0, 18911 , 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==6)

{

SetPlayerAttachedObject( playerid, 0, 18914, 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==7)

{

SetPlayerAttachedObject(playerid, 0, 18918, 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==8)

{

SetPlayerAttachedObject(playerid, 0, 18920 , 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==9)

{

SetPlayerAttachedObject(playerid, 0, 18919 , 2, 0.078534, 0.041857, -0.001727, 268.970458, 1.533374, 269.223754);

}

if(listitem==10)

{

for(new i;i<5;i++) RemovePlayerAttachedObject(playerid,i);

}

}

return 1;

}

return 0;

}

public OnFilterScriptExit()

{

for(new i=0;i<MAX_PLAYERS;i++)

if(IsPlayerConnected(i))

StopPlayerHoldingObject(i);

return 0;

}[/pawn]

Stiu si eu ... branza e pe bani, dar eu tot ma joc pe gratis!

Link to comment
Share on other sites

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(17) : error 025: function heading differs from prototype

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(17) : error 029: invalid expression, assumed zero

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(19) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(21) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(25) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(27) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(29) : error 025: function heading differs from prototype

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(29) : error 029: invalid expression, assumed zero

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(31) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(33) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(35) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(39) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(43) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(47) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(51) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(55) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(59) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(63) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(67) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(71) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(75) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(77) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(80) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(82) : error 010: invalid function or declaration

C:\Users\AleX\Desktop\SAmP\Deadly\filterscripts\bandana.pwn(93) : warning 203: symbol is never used: "PlayerInfo"

Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase

24 Errors.

:(

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.