Need help
#1

Hi guys i need help with command /oskin.. I has try this script but there are bug in this command
Код:
CMD:oskin(playerid, params[])
{
	new orgid=PlayerInfo[playerid][pOrgid],duty,oColours[25];
	duty = PlayerInfo[playerid][pDuty];
	if(PlayerInfo[playerid][pOrgid]>0)
	{
	    if(duty==0)
	    {
	        SetPlayerSkin(playerid,OrgInfo[PlayerInfo[playerid][pOrgid]][oSkin1]);
	        duty = 2;
		}
		if(duty==1)
	    {
	        SetPlayerSkin(playerid,OrgInfo[PlayerInfo[playerid][pOrgid]][oSkin1]);
	        duty = 2;
		}
		if(duty==2)
	    {
	        SetPlayerSkin(playerid,OrgInfo[PlayerInfo[playerid][pOrgid]][oSkin2]);
	        duty = 3;
		}
		if(duty==3)
	    {
	        SetPlayerSkin(playerid,OrgInfo[PlayerInfo[playerid][pOrgid]][oSkin3]);
	        duty = 4;
		}
		if(duty==4)
	    {
	        SetPlayerSkin(playerid,OrgInfo[PlayerInfo[playerid][pOrgid]][oSkin4]);
	        duty = 5;
		}
		if(duty==5)
	    {
	        SetPlayerSkin(playerid,OrgInfo[PlayerInfo[playerid][pOrgid]][oSkin5]);
	        duty = 1;
		}
		GivePlayerWeapon(playerid, OrgInfo[orgid][oWeaps1],OrgInfo[orgid][oAmmo1]);
		GivePlayerWeapon(playerid, OrgInfo[orgid][oWeaps2],OrgInfo[orgid][oAmmo2]);
		GivePlayerWeapon(playerid, OrgInfo[orgid][oWeaps3],OrgInfo[orgid][oAmmo3]);
		format(oColours, 12, "0x%s99", OrgInfo[orgid][oColor]);
		SetPlayerColor(playerid, HexToInt(oColours));
		if(OrgInfo[orgid][oType]>=1 && OrgInfo[orgid][oType]<4)
		{
		    SendClientMessage(playerid, HexToInt(oColours),"You're On Duty");
		}
	}
	return 1;
}
The mistake is the skin didn't changed any idea ?? Thanks
Reply
#2

Check the "oSkin1" line. press control F to search
Reply
#3

oSkin1 line at this enum

Код:
enum OInfo
{
	oName[128],
	oLeader[MAX_PLAYER_NAME],
	oWageRank1,
	oWageRank2,
	oWageRank3,
	oWageRank4,
	oWageRank5,
	oWageLeader,
	oCP,
	oText,
	oType,
	oSkin1,
	oSkin2,
	oSkin3,
	oSkin4,
	oSkin5,
	oColor[25],
	oWeaps1,
	oAmmo1,
	oWeaps2,
	oAmmo2,
	oWeaps3,
	oAmmo3,
	oMembers,
	oIntEx,
	oIntEn,
	oVWEx,
	oVWEn,
	oMaxMembers,
	NameRank1[60],
	NameRank2[60],
	NameRank3[60],
	NameRank4[60],
	NameRank5[60],
	LeaderRank[60],
	oVehicle[20],
	Float:oVehicle_PosX[20],
	Float:oVehicle_PosY[20],
	Float:oVehicle_PosZ[20],
	Float:oVehicle_PosA[20],
	oVehicle_Model[20],
	oVehicleCol1[20],
	oVehicleCol2[20],
	Float:oPosExtX,
	Float:oPosExtY,
	Float:oPosExtZ,
	Float:oPosIntX,
	Float:oPosIntY,
	Float:oPosIntZ,
}
new OrgInfo[MAX_ORGS][OInfo];
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)