Need help with /briefcase
#1

Код:
warning 213: tag mismatch
warning 202: number of arguments does not match definition
Код:
	if(strcmp(cmd, "/briefcase", true) == 0)
	{
		if(IsPlayerConnected(playerid))
		{
			if(PlayerInfo[playerid][pBCase] == 1)
			{
				if(BCase[playerid] == 0)
				{
                    SetPlayerAttachedObject(playerid, 1210, 6,0.3,0.1,0,0,-90,0); // BriefCase
                    SendClientMessage(playerid, COLOR_WHITE, " You have pulled out your briefcase. ");
                    BCase[playerid] = 1;
	        		return 1;
	        	}
	        	else if(BCase[playerid] == 1)
	        	{
                    RemovePlayerAttachedObject(playerid);
                    SendClientMessage(playerid, COLOR_WHITE, " You have put away your briefcase. ");
                    BCase[playerid] = 0;
	        		return 1;
	        	}
	        }
	        else
	        {
				SendClientMessage(playerid, COLOR_GRAD2, " You don't own a briefcase !");
				return 1;
			}
	        return 1;
		}
		return 1;
	}
Reply
#2

what lines are the errors
Reply
#3

SetPlayerAttachedObject(playerid, 1210, 6,0.3,0.1,0,0,-90,0); // BriefCase
RemovePlayerAttachedObject(playerid);

In those lines..
Reply
#4

I have this problem too.... anyone can help ?
Reply
#5

Check this:
https://sampwiki.blast.hk/wiki/SetPlayerAttachedObject
You're mixing the parameters. And this one too: https://sampwiki.blast.hk/wiki/RemovePlayerAttachedObject
You have to specify the index.

Best regards!
Reply
#6

Yeah i looked at this one but im messing it up even more..... can you just transform those 2 and provide the code here ?
Reply
#7

Try with this:
pawn Код:
SetPlayerAttachedObject(playerid, 0, 1210, 6, 0.3, 0.1, 0.0,-90.0,0.0,0.0);
RemovePlayerAttachedObject(playerid, 0);
____________________
EDIT:
@Rg-Gaming.Info: No problem.

(Hate make a new comment to say you're welcome. xD)
Reply
#8

Quote:
Originally Posted by irinel1996
Посмотреть сообщение
Try with this:
pawn Код:
SetPlayerAttachedObject(playerid, 0, 1210, 6, 0.3, 0.1, 0.0,-90.0,0.0,0.0);
RemovePlayerAttachedObject(playerid, 0);
Thanks it worked !
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)