25.02.2010, 16:53
Test filterscript:
Wrong:
Correct:
Wrong:
pawn Код:
#include <a_samp>
public OnFilterScriptInit() { SetTimer("test", 60, true); return 1; }
forward test();public test() {
new
vhp = random(800)+200;
if(vhp < 700)
{
printf("true vhp: %d", vhp);
}
else if(vhp < 540)
{
printf("No Callback funkcion true (else if) vhp: %d", vhp);
}
}
pawn Код:
#include <a_samp>
public OnFilterScriptInit() { SetTimer("test", 600, true); return 1; }
forward test();public test()
{
new
vhp = random(800)+200;
if(vhp < 540)
{
printf("Your car health is now under 540. VehicleHealth: %d", vhp);
}
else if(vhp < 700)
{
printf("Your car health is now under 700. VehicleHealth: %d", vhp);
}
}