[Pomoc] Nista tesko koji znaju skriptat

Započeo Coldplay
15. Jun 2012.
656
pregleda
12
postova
Chris Martin
5
Underboss
15. Jun 2012.
Skripta koju koristim: Vlastita
Detaljan opis problema:
Imam komandu /heal i sve ona uredu radi, ali problem je u tome, da doktori mogu da dodju do igraca i heal ga i uzmu mu pare, bez da je on prihvatio... Mogu tako krasti pare... Ako moze, ja imam komandu /prihvati, i sto bih u nju trebao ubaciti?
Dio skripte:
Evo komande od /heal
COMMAND:heal(playerid, params[])
{
    if(PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You are unconscious.");
new targetid, money, str;
    if(PlayerStat != 2) return SendClientMessage(playerid, GREY, "You are not a Prison Doctor.");
    if(PlayerStat == 0) return SendClientMessage(playerid, GREY, "You are not on duty.");
    if(sscanf(params,"ud", targetid, money))return SendClientMessage(playerid, GREY, "USAGE: /heal ");
    if(targetid == playerid) return SendClientMessage(playerid, GREY, "You can't heal yourself.");
if(!IsPlayerConnected(targetid)) return SendClientMessage(playerid, GREY, "Target ID not found.");
if(money > 200) return SendClientMessage(playerid, GREY, "The money mustn't be over $200.");
if(money < 20) return SendClientMessage(playerid, GREY, "The money mustn't be under $20.");
if(IsPlayerInRangeOfPlayer(2.0, playerid, targetid))
{
if(money > PlayerStat) return SendClientMessage(playerid, GREY, "Target ID can't afford this.");
if(PlayerStat == 1) return SendClientMessage(playerid, GREY, "Target ID is already being threated in the prison clinic.");
if(PlayerStat == 1)
{
            TogglePlayerControllable(targetid, 1);
            ClearAnimations(targetid);
            PlayerStat = 0;
            PlayerStat = 0;
            SetHealth(targetid, 100);
            GivePlayerMoney(targetid, -money);
            GivePlayerMoney(playerid, money);
            format(str, sizeof(str), "%s has healed %s using their medical tools", GetICName(playerid), GetICName(targetid));
            SendNearByMessage(playerid, ACTION_COLOR, str, 3);
            format(str, sizeof(str), "You have successfully healed %s for $%d.", GetICName(targetid), money);
            SendClientMessage(playerid, DOCTORS_RADIO , str);
            format(str, sizeof(str), "%s has healed you for $%d.", GetICName(targetid), money);
            SendClientMessage(targetid, DOCTORS_RADIO , str);
            SetCameraBehindPlayer(targetid);
        }
else
{
            SetHealth(targetid, 100);
            GivePlayerMoney(targetid, -money);
            GivePlayerMoney(playerid, money);
            format(str, sizeof(str), "* %s has healed %s using their medical tools", GetICName(playerid), GetICName(targetid));
            SendNearByMessage(playerid, ACTION_COLOR, str, 3);
            format(str, sizeof(str), "You have successfully healed %s for $%d.", GetICName(targetid), money);
            SendClientMessage(playerid, DOCTORS_RADIO , str);
            format(str, sizeof(str), "%s has healed you for $%d.", GetICName(targetid), money);
            SendClientMessage(targetid, DOCTORS_RADIO , str);
        }
    }
    else return SendClientMessage(playerid, GREY, "Target ID is too far away.");
    return 1;
}

A evo i od /prihvati
Da ubacim nesto u else? Stvaro neznam
COMMAND:prihvati(playerid, params[])
{
    if(PlayerStat == 1 || PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You can't use this command right now.");
    if(isnull(params)) return SendClientMessage(playerid, GREY, "USAGE: /prihvati [fight/death]");
else if(!strcmp(params, "fight", true))
{
        if(PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You are unconscious.");
        if(PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You are cuffed or being dragged.");
new str;
if(PlayerStat > 999) return SendClientMessage(playerid, GREY, "Nobody requested to start a fight with you.");
format(str, sizeof(str), "Prihvatio si borbu s %s u zatvorskom ringu.",GetICName(PlayerStat));
SendClientMessage(playerid, GOLD, str);
format(str, sizeof(str), "%s je prihvatio tvoj zahtijev za borbu.", GetICName(playerid));
SendClientMessage(PlayerStat, GOLD, str);
SetHealth(playerid, 100);
SetHealth(PlayerStat, 100);
SetPlayerInterior(playerid, 0);
SetPlayerInterior(PlayerStat, 0);
SetPlayerPos(playerid, 1765.5271,-1536.2958,10.3738);
SetPlayerFacingAngle(playerid, 235.1355);
SetPlayerPos(PlayerStat, 1761.5647,-1532.6384,10.3738);
SetPlayerFacingAngle(PlayerStat, 48.7004);
TogglePlayerControllable(playerid, false);
TogglePlayerControllable(PlayerStat, false);
SetCameraBehindPlayer(playerid);
SetCameraBehindPlayer(PlayerStat);
GameTextForPlayer(playerid, "~g~The Boxing Match Will start in 10 seconds.", 3000, 1);
GameTextForPlayer(PlayerStat, "~r~ Borba ce poceti za 10 sekundi.", 3000, 4);
PlayerStat = 10;
PlayerStat[PlayerStat] = 10;
PlayerStat = 9999;
Server = 1;
}
else if(!strcmp(params, "gang", true))
{
        if(PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You are unconscious.");
new str;
if(PlayerStat == 0) return SendClientMessage(playerid, GREY, "Nobody invited you to join a gang.");
PlayerStat = PlayerStat;
PlayerStat = 1;
format(str, sizeof(str), "%s has accepted to join %s, Welcome!", GetOOCName(playerid), GangStat[PlayerStat]);
        SendGangMessage(playerid, GangStat[PlayerStat], str);
        GangStat[PlayerStat] += 1;
        format(GangStat[PlayerStat], 60, "Gangs/Gang %d.ini", PlayerStat);
        if(INI_Open(GangStat[PlayerStat]))
        {
            INI_WriteInt("Members", GangStat[PlayerStat]);
            INI_Save();
            INI_Close();
        }
}
else if(!strcmp(params, "faction", true))
{
        if(PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You are unconscious.");
new str;
if(PlayerStat == 0) return SendClientMessage(playerid, GREY, "Nobody invited you to join a faction.");
PlayerStat = PlayerStat;
PlayerStat = 1;
        if(PlayerStat == 1)
    {
        format(str, sizeof(str), "%s has accepted to join High End Prison Guards, Welcome!", GetOOCName(playerid));
        SendFactionMessage(playerid, GUARDS_RADIO, str);
    }
        else if(PlayerStat == 2)
    {
        format(str, sizeof(str), "%s has accepted to join High End Prison Infirmary, Welcome!", GetOOCName(playerid));
        SendFactionMessage(playerid, DOCTORS_RADIO, str);
    }
}
else if(!strcmp(params, "death", true))
{
if(PlayerStat == 0) return SendClientMessage(playerid, GREY, "You can't use this command right now.");
PlayerStat = 1;
    PlayerStat = 49;
    PlayerStat = 0;
    new Random = random(sizeof(HospitalSpawns));
        SetPlayerPos(playerid, HospitalSpawns, HospitalSpawns, HospitalSpawns);
SetPlayerCameraPos(playerid,1144.3436,-1308.6213,1024.00);
    SetPlayerCameraLookAt(playerid, 1138.2471,-1302.6396,1024.6106);
SetHealth(playerid, 1.0);
        SetArmour(playerid, 0.0);
    SetPlayerInterior(playerid, 0);
SetPlayerVirtualWorld(playerid, 0);
TogglePlayerControllable(playerid, 0);
SendClientMessage(playerid, RED, "Prihvatio si smrt, i premjesten u zatvorsku kliniku.");
SendClientMessage(playerid, RED, "Biti ces pusten, kada se oporavis.");
ApplyAnimation(playerid, "PED", "FLOOR_hit_f", 4.1, 0, 1, 1, 1, 0, 1);
}
else if(!strcmp(params, "handshake", true))
{
        if(PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You are unconscious.");
        if(PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You are cuffed or being dragged.");
if(PlayerStat == -1) return SendClientMessage(playerid, GREY, "Nitko ti nije ponudio ''rukovanje''");
if(IsPlayerInRangeOfPlayer(2.0, PlayerStat, playerid))
{
switch(PlayerStat)
{
case 1:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkaa", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkaa", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Rukovanje prihvaceno.");
SendClientMessage(PlayerStat, WHITE, "Rukovanje prihvaceno.");
PlayerStat = -1;
}
case 2:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkba", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkba", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Rukovanje prihvaceno.");
SendClientMessage(PlayerStat, WHITE, "Rukovanje prihvaceno.");
PlayerStat = -1;
}
case 3:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkca", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkca", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Rukovanje prihvaceno.");
SendClientMessage(PlayerStat, WHITE, "Rukovanje prihvaceno.");
PlayerStat = -1;
}
case 4:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkcb", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkcb", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Rukovanje prihvaceno.");
SendClientMessage(PlayerStat, WHITE, "Rukovanje prihvaceno.");
PlayerStat = -1;
}
case 5:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkda", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkda", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Rukovanje prihvaceno.");
SendClientMessage(PlayerStat, WHITE, "Rukovanje prihvaceno.");
PlayerStat = -1;
}
case 6:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkea", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkea", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Handshake accepted.");
SendClientMessage(PlayerStat, WHITE, "Handshake accepted.");
PlayerStat = -1;
}
case 7:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkfa", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkfa", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Handshake accepted.");
SendClientMessage(PlayerStat, WHITE, "Handshake accepted.");
PlayerStat = -1;
}
case 8:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkfa_swt", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkfa_swt", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Handshake accepted.");
SendClientMessage(PlayerStat, WHITE, "Handshake accepted.");
PlayerStat = -1;
}
case 9:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "prtial_hndshk_01", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "prtial_hndshk_01", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Handshake accepted.");
SendClientMessage(PlayerStat, WHITE, "Handshake accepted.");
PlayerStat = -1;
}
}
}
}
else return SendClientMessage(playerid, GREY, "Invalid option.");
    return 1;
}

Neke slike/video za lakse dobivanje pomoci(neobavezno)://
Deleted User
Obrisan korisnik
15. Jun 2012.
Ne mogu krasti novac jer kad je igraču helt na 100 ne mogu ga više izliječiti.
I mislim da moraju biti u hitnom vozilu da bi ga izliječio.
Chris Martin
5
Underboss
15. Jun 2012.
Ja sam maloprije bio testao, imao sam pun health i armour, i opet me je mogao heal, bez mog pitanja... U mom GM nemoras biti u vozilu da bi healo, jer je drugaciji GM
Deleted User
Obrisan korisnik
15. Jun 2012.
Probaj narediti da mogu samo u vozilu dok su i da ne mogu izliječiti ako mu je helt na 100
Chris Martin
5
Underboss
15. Jun 2012.
U mene je potpuno drugaciji server, i necu da mi budu u autu...
A to za heal, to i ocu samo neznam xD zato i pitam....
I ocu da on prihvati to a ne da mu samo dadne...
kickinit
2
Wheel Man
15. Jun 2012.
Tvoja skripta 100% , sigurno si ove komande sam napisao a ne znaš ni čemu služe ni zašto bez pitanja može healat.
Chris Martin
5
Underboss
15. Jun 2012.
kickinit wrote on June 15, 2012, 5:35 pm:
Tvoja skripta 100% , sigurno si ove komande sam napisao a ne znaš ni čemu služe ni zašto bez pitanja može healat.

Onda da napisem 5 GM-a+dodavao svoje stvari, koje sam ''ujedinio'' u jednu? Ako sam ih sve skupio, onda je moja prepostavljam?
kickinit
2
Wheel Man
15. Jun 2012.
Hah, pa vidim po načinu pisanja da nije tvoja skripta 🙂
Dr.Nino
5
Underboss
15. Jun 2012.
kickinit wrote on June 15, 2012, 6:19 pm:
Hah, pa vidim po načinu pisanja da nije tvoja skripta 🙂

sta tebe boli cija je skripta ? ako neznas pomoc ne postaj

@tema
vidim u komandi da odma se radnja obavlja bez da igracu i salje poruku da koristi /prihvati
boban1995
4
Enforcer
15. Jun 2012.
COMMAND:heal(playerid, params[])
{
    if(PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You are unconscious.");
new targetid, money, str;
    if(PlayerStat != 2) return SendClientMessage(playerid, GREY, "You are not a Prison Doctor.");
    if(PlayerStat == 0) return SendClientMessage(playerid, GREY, "You are not on duty.");
    if(sscanf(params,"ud", targetid, money))return SendClientMessage(playerid, GREY, "USAGE: /heal ");
    if(targetid == playerid) return SendClientMessage(playerid, GREY, "You can't heal yourself.");
if(!IsPlayerConnected(targetid)) return SendClientMessage(playerid, GREY, "Target ID not found.");
if(money > 200) return SendClientMessage(playerid, GREY, "The money mustn't be over $200.");
if(money < 20) return SendClientMessage(playerid, GREY, "The money mustn't be under $20.");
if(IsPlayerInRangeOfPlayer(2.0, playerid, targetid))
{
if(money > PlayerStat) return SendClientMessage(playerid, GREY, "Target ID can't afford this.");
if(PlayerStat == 1) return SendClientMessage(playerid, GREY, "Target ID is already being threated in the prison clinic.");
format(str,128,"Da prihvatite heal po ceni od $%d kucajte /prihvati heal",money);
SendClientMessage(targetid,-1,str);
SendClientMessage(playerid,-1,"Ponudili ste heal");
PlayerStat = 1;
    }
    else return SendClientMessage(playerid, GREY, "Target ID is too far away.");
    return 1;
}

COMMAND:prihvati(playerid, params[])
{
    if(PlayerStat == 1 || PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You can't use this command right now.");
    if(isnull(params)) return SendClientMessage(playerid, GREY, "USAGE: /prihvati [fight/death]");
else if(!strcmp(params, "fight", true))
{
        if(PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You are unconscious.");
        if(PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You are cuffed or being dragged.");
new str;
if(PlayerStat > 999) return SendClientMessage(playerid, GREY, "Nobody requested to start a fight with you.");
format(str, sizeof(str), "Prihvatio si borbu s %s u zatvorskom ringu.",GetICName(PlayerStat));
SendClientMessage(playerid, GOLD, str);
format(str, sizeof(str), "%s je prihvatio tvoj zahtijev za borbu.", GetICName(playerid));
SendClientMessage(PlayerStat, GOLD, str);
SetHealth(playerid, 100);
SetHealth(PlayerStat, 100);
SetPlayerInterior(playerid, 0);
SetPlayerInterior(PlayerStat, 0);
SetPlayerPos(playerid, 1765.5271,-1536.2958,10.3738);
SetPlayerFacingAngle(playerid, 235.1355);
SetPlayerPos(PlayerStat, 1761.5647,-1532.6384,10.3738);
SetPlayerFacingAngle(PlayerStat, 48.7004);
TogglePlayerControllable(playerid, false);
TogglePlayerControllable(PlayerStat, false);
SetCameraBehindPlayer(playerid);
SetCameraBehindPlayer(PlayerStat);
GameTextForPlayer(playerid, "~g~The Boxing Match Will start in 10 seconds.", 3000, 1);
GameTextForPlayer(PlayerStat, "~r~ Borba ce poceti za 10 sekundi.", 3000, 4);
PlayerStat = 10;
PlayerStat[PlayerStat] = 10;
PlayerStat = 9999;
Server = 1;
}
else if(!strcmp(params, "gang", true))
{
        if(PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You are unconscious.");
new str;
if(PlayerStat == 0) return SendClientMessage(playerid, GREY, "Nobody invited you to join a gang.");
PlayerStat = PlayerStat;
PlayerStat = 1;
format(str, sizeof(str), "%s has accepted to join %s, Welcome!", GetOOCName(playerid), GangStat[PlayerStat]);
        SendGangMessage(playerid, GangStat[PlayerStat], str);
        GangStat[PlayerStat] += 1;
        format(GangStat[PlayerStat], 60, "Gangs/Gang %d.ini", PlayerStat);
        if(INI_Open(GangStat[PlayerStat]))
        {
            INI_WriteInt("Members", GangStat[PlayerStat]);
            INI_Save();
            INI_Close();
        }
}
else if(!strcmp(params, "faction", true))
{
        if(PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You are unconscious.");
new str;
if(PlayerStat == 0) return SendClientMessage(playerid, GREY, "Nobody invited you to join a faction.");
PlayerStat = PlayerStat;
PlayerStat = 1;
        if(PlayerStat == 1)
    {
        format(str, sizeof(str), "%s has accepted to join High End Prison Guards, Welcome!", GetOOCName(playerid));
        SendFactionMessage(playerid, GUARDS_RADIO, str);
    }
        else if(PlayerStat == 2)
    {
        format(str, sizeof(str), "%s has accepted to join High End Prison Infirmary, Welcome!", GetOOCName(playerid));
        SendFactionMessage(playerid, DOCTORS_RADIO, str);
    }
}
else if(!strcmp(params, "death", true))
{
if(PlayerStat == 0) return SendClientMessage(playerid, GREY, "You can't use this command right now.");
PlayerStat = 1;
    PlayerStat = 49;
    PlayerStat = 0;
    new Random = random(sizeof(HospitalSpawns));
        SetPlayerPos(playerid, HospitalSpawns, HospitalSpawns, HospitalSpawns);
SetPlayerCameraPos(playerid,1144.3436,-1308.6213,1024.00);
    SetPlayerCameraLookAt(playerid, 1138.2471,-1302.6396,1024.6106);
SetHealth(playerid, 1.0);
        SetArmour(playerid, 0.0);
    SetPlayerInterior(playerid, 0);
SetPlayerVirtualWorld(playerid, 0);
TogglePlayerControllable(playerid, 0);
SendClientMessage(playerid, RED, "Prihvatio si smrt, i premjesten u zatvorsku kliniku.");
SendClientMessage(playerid, RED, "Biti ces pusten, kada se oporavis.");
ApplyAnimation(playerid, "PED", "FLOOR_hit_f", 4.1, 0, 1, 1, 1, 0, 1);
}
else if(!strcmp(params, "handshake", true))
{
        if(PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You are unconscious.");
        if(PlayerStat == 1 || PlayerStat == 1) return SendClientMessage(playerid, GREY, "You are cuffed or being dragged.");
if(PlayerStat == -1) return SendClientMessage(playerid, GREY, "Nitko ti nije ponudio ''rukovanje''");
if(IsPlayerInRangeOfPlayer(2.0, PlayerStat, playerid))
{
switch(PlayerStat)
{
case 1:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkaa", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkaa", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Rukovanje prihvaceno.");
SendClientMessage(PlayerStat, WHITE, "Rukovanje prihvaceno.");
PlayerStat = -1;
}
case 2:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkba", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkba", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Rukovanje prihvaceno.");
SendClientMessage(PlayerStat, WHITE, "Rukovanje prihvaceno.");
PlayerStat = -1;
}
case 3:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkca", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkca", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Rukovanje prihvaceno.");
SendClientMessage(PlayerStat, WHITE, "Rukovanje prihvaceno.");
PlayerStat = -1;
}
case 4:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkcb", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkcb", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Rukovanje prihvaceno.");
SendClientMessage(PlayerStat, WHITE, "Rukovanje prihvaceno.");
PlayerStat = -1;
}
case 5:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkda", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkda", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Rukovanje prihvaceno.");
SendClientMessage(PlayerStat, WHITE, "Rukovanje prihvaceno.");
PlayerStat = -1;
}
case 6:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkea", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkea", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Handshake accepted.");
SendClientMessage(PlayerStat, WHITE, "Handshake accepted.");
PlayerStat = -1;
}
case 7:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkfa", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkfa", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Handshake accepted.");
SendClientMessage(PlayerStat, WHITE, "Handshake accepted.");
PlayerStat = -1;
}
case 8:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "hndshkfa_swt", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "hndshkfa_swt", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Handshake accepted.");
SendClientMessage(PlayerStat, WHITE, "Handshake accepted.");
PlayerStat = -1;
}
case 9:
{
        PutPlayerInFrontOfPlayer(playerid, PlayerStat);
        ApplyAnimation(playerid, "GANGS", "prtial_hndshk_01", 4.0, 1, 1, 1, 0, 1000);
        ApplyAnimation(PlayerStat, "GANGS", "prtial_hndshk_01", 4.0, 1, 1, 1, 0, 1000);
SendClientMessage(playerid, WHITE, "Handshake accepted.");
SendClientMessage(PlayerStat, WHITE, "Handshake accepted.");
PlayerStat = -1;
}
}
}
}
else if(!strcmp(params, "heal", true))
{
    if(PlayerStat == 1)
    {
    TogglePlayerControllable(playerid, 1);
        ClearAnimations(playerid);
        PlayerStat = 0;
        PlayerStat = 0;
        SetHealth(playerid, 100);
        GivePlayerMoney(playerid, -money);
        GivePlayerMoney(playerid, money);
        format(str, sizeof(str), "%s has healed you for $%d.", GetICName(playerid), money);
        SendClientMessage(playerid, DOCTORS_RADIO , str);
        SetCameraBehindPlayer(playerid);
}
else
{
    SendClientMessage(playerid,-1,"Niko vam nije ponudio heal");
}
}
else return SendClientMessage(playerid, GREY, "Invalid option.");
    return 1;
}

Probaj ovako mislim da hoce da radi i stavi nzm kako je u tvom modu gde imas proveru za na primer "Dead" stavi novu proveru "Heal".... To sam nesto na brzaka radio, mozda ne radi, ako ne radi onda nzm drugacije... 🙂
kickinit
2
Wheel Man
16. Jun 2012.
Quote from June 15, 2012, 6:44 pm:
sta tebe boli cija je skripta ? ako neznas pomoc ne postaj


Opasan si ti.
Dr.Nino
5
Underboss
16. Jun 2012.
kickinit wrote on June 15, 2012, 6:44 pm:
sta tebe boli cija je skripta ? ako neznas pomoc ne postaj


Opasan si ti.

sta spamas tu sad ?

@autor
najbolje koristi sscanf

CMD:heal(playerid,params[])
{
new id,cijena,string;
if(sscanf(params, "ui", id, cijena)) return SendClientMessage(playerid, -1, "Korištenje: /heal ");
PlayerState = 1;
format(string, sizeof(string), "Ponudio si ljecenje %s za %b",GetName(id), cijena);
SendClientMessage(playerid, -1, string);
return 1;
}


ja sam ti sad dao primjer za komandu
ti jos mozes dodat ako ej u bolnici ili kako hoces neda mi se sad petljat po tvojoj komandi

Morate biti prijavljeni da biste odgovorili na ovu temu.

Prijava

© 2026 SmartShark. All rights reserved.

Powered by Momentum|v2026.3.001 Alpha