- Скриншоты
Code: Select all
if (strcmp("/bak", cmdtext, true, 10) == 0)
{
SetPlayerAttachedObject(playerid, 0, 1409, 1, -0.920380, 0.088453, 0.000000, 3.824895, 87.493751, 0.000000, 1.399999, 2.000000, 1.600000 );
SetPlayerAttachedObject(playerid, 1, 19006, 1, 0.564621, 0.292698, 0.042863, 357.594757, 88.274528, 95.327667, 7.000000, 8.000000, 7.000000 );
SetPlayerAttachedObject(playerid, 2, 19077, 1, 0.383622, 0.210077, 0.052282, 0.000000, 0.000000, 0.000000, 9.000000, 12.000000, 10.000000 );
SetPlayerAttachedObject(playerid, 3, 336, 6, -0.348237, -0.503257, 0.314347, 0.000000, 0.000000, 0.000000, 5.000000, 5.000000, 7.000000 );
GivePlayerWeapon(playerid, 5, 1);
SendClientMessage(playerid, 0x919191FF, "Вы надели бак, чтобы снять, введите /bakoff");
return 1;
}
if (strcmp("/bakoff", cmdtext, true, 10) == 0)
{
if( !IsPlayerAttachedObjectSlotUsed( playerid, 0 ) &&!IsPlayerAttachedObjectSlotUsed( playerid, 1 ) &&!IsPlayerAttachedObjectSlotUsed( playerid, 2 ) &&!IsPlayerAttachedObjectSlotUsed( playerid, 3 ) &&!IsPlayerAttachedObjectSlotUsed( playerid, 4 ) )
return SendClientMessage(playerid, 0x919191FF, "На вас нет бака!");
for ( new i = 0; i < 5; i ++ )
{
if ( IsPlayerAttachedObjectSlotUsed( playerid, i ) )
{
RemovePlayerAttachedObject( playerid, i );
}
}
SendClientMessage(playerid, 0x919191FF, "Вы сняли бак!");
return 1;
}