pawn Код:
public OnGameModeInit()
{
SetGameModeText("Made By .Wicked");
AddPlayerClass(285, 1958.3783, 1343.1572, 15.3746, 269.1425, 31, 200, 22, 100, 4, 1); // (Skin ID, Position X, Position Y, Position Z, Angel, Weapon 1, Weapon 1 Ammo, Weapon 2, Weapon 2 Ammo, Weapon 3, Weapon 3 Ammo);
AddPlayerClass(50, 1958.3783, 1343.1572, 15.3746, 269.1425, 30, 200, 22, 100, 4, 1); // (Skin ID, Position X, Position Y, Position Z, Angel, Weapon 1, Weapon 1 Ammo, Weapon 2, Weapon 2 Ammo, Weapon 3, Weapon 3 Ammo);
return 1; // The skins above (^) will show up on the visable class selection and will spawn the the weapons you have chose them to spawn with.
}
pawn Код:
public OnPlayerRequestClass(playerid, classid)
{
switch(classid)
{
case 0:
{
gTeam[playerid] = TEAM_ROBBERS;
GameTextForPlayer(playerid, "~b~Robbers", 1000, 3); // Gametext for the player when he switches class.
SetPlayerPos(playerid, 508.9641,-88.0964,998.9683); // The position you will see the skin at.
SetPlayerCameraPos(playerid, 508.8021,-85.0079,998.9609); // Where the camera will be at.
SetPlayerCameraLookAt(playerid, 508.9641,-88.0964,998.9683); // Where the camera will look at.
SetPlayerInterior(playerid, 11); // If the camera/skin etc is in a interior. (11) = interior ID.
}
case 1:
{
gTeam[playerid] = TEAM_COPS;
GameTextForPlayer(playerid, "~r~Cops", 1000, 3);
SetPlayerPos(playerid, 508.9641,-88.0964,998.9683);
SetPlayerFacingAngle(playerid, 1.2533);
SetPlayerCameraPos(playerid, 508.8021,-85.0079,998.9609);
SetPlayerCameraLookAt(playerid, 508.9641,-88.0964,998.9683);
SetPlayerInterior(playerid, 11);
}
}
return 1;
}
This should work 100% if you have defined the teams.
Please replay back if it works or if there's a bug I'll do my best to fix it.