AAlcohol Help -
matko.basket - 09.01.2010
so this is my script
SetTimer("alkoholcheck",1000,1);
SetTimer("triezvenie",30000,1);
forward alkoholcheck(playerid);
public alkoholcheck(playerid)
{
if(IsPlayerConnected(i))
{
if(Informacie[playerid][Alk]> 1)
{
if(Informacie[playerid][Alk]>= 2 && Informacie[playerid][Alk] < 4 ){
ApplyAnimation(playerid,"PED","WALK_DRUNK",0.05,1, 1,1,1,1);
}
else if(Informacie[playerid][Alk]>= 4 && Informacie[playerid][Alk] < 6 ){
ApplyAnimation(i,"PED","WALK_DRUNK",0.1,1,1,1,1,1) ;
}
else if(Informacie[playerid][Alk]>= 6 && Informacie[playerid][Alk] < 8 ){
SetPlayerDrunkLevel (playerid, 3000);
ApplyAnimation(playerid,"PED","WALK_DRUNK",0.15,1, 1,1,1,1);
}
else if(Informacie[playerid][Alk]>= 8 && Informacie[playerid][Alk] < 10 ){
SetPlayerDrunkLevel (playerid, 7000);
ApplyAnimation(playerid,"PED","WALK_DRUNK",0.2,1,1 ,1,1,1);
}
else if(Informacie[playerid][Alk]>= 10 && Informacie[playerid][Alk] < 12 ){
SetPlayerDrunkLevel (playerid, 20000);
ApplyAnimation(playerid,"PED","WALK_DRUNK",0.25,1, 1,1,1,1);
}
else if(Informacie[playerid][Alk]>= 12 && Informacie[playerid][Alk] < 14 ){
SetPlayerDrunkLevel (playerid, 15000);
ApplyAnimation(playerid,"PED","WALK_DRUNK",0.4,1,1 ,1,1,1);
}
else if(Informacie[playerid][Alk]>= 14 && Informacie[playerid][Alk] < 16 ){
SetPlayerDrunkLevel (playerid, 30000);
ApplyAnimation(playerid,"PED","WALK_DRUNK",0.5,1,1 ,1,1,1);
}
else if(Informacie[playerid][Alk]>= 16 && Informacie[playerid][Alk] < 18 ){
SetPlayerDrunkLevel (playerid, 40000);
ApplyAnimation(playerid,"PED","WALK_DRUNK",0.7,1,1 ,1,1,1);
ApplyAnimation(playerid,"PED","WALK_DRUNK",0.7,1,1 ,1,1,1);
}
else if(Informacie[playerid][Alk]>= 18 && Informacie[playerid][Alk] < 20 ){
SetPlayerDrunkLevel (i, 50000);
ApplyAnimation(playerid,"PED","WALK_DRUNK",0.9,1,1 ,1,1,1);
ApplyAnimation(playerid,"PED","WALK_DRUNK",0.9,1,1 ,1,1,1);
}
}
}
}
forward triezvenie(playerid);
public triezvenie(playerid)
{
if(IsPlayerConnected(i)) {
if (Informacie[playerid][Alk] != 0)
Informacie[playerid][Alk]--;
}
else if(hrac[playerid][alkohol] == 0) ClearAnimations(playerid);
}
}
som my problem is i canґt stop the animation ...when i have a 0 per mille....why
pls help me or writte vy who must see public triezvenie
pls help me
Re: AAlcohol Help -
matko.basket - 10.01.2010
is someone hwo help me
?,
soorrry for my bad english
Re: AAlcohol Help -
Doppeyy - 10.01.2010
Put the code in [ code]put your code here[/ code].
Or else we cant even read it normally.
[Doppeyy
Re: AAlcohol Help -
matko.basket - 11.01.2010
help pls