01.08.2009, 06:40
Help me please! helllpppp
script commpiling and work
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
if (newkeys==KEY_FIRE)
{ if (Xbombb[playerid] == 0 || Ybombb[playerid] == 0 || Zbombb[playerid] == 0) {
} else {
CreateExplosion(Xbombb[playerid],Ybombb[playerid],Zbombb[playerid],6,1);
CreateExplosion(Xbombb[playerid],Ybombb[playerid],Zbombb[playerid],7,1);
SendClientMessage(playerid,COLOR_GREEN,"* boom");
DestroyObject(bombid[playerid]);
bombid[playerid] = 0;
for (new v = 1; v < MAX_VEHICLES; v++) {
new dis = GetDistanceBetweenVAP(playerid,v);
if (dis < 5) {
SetVehicleHealth(v,0);
}
else if (dis > 5 && dis < 10) {
GiveVehicleHealth(v,-650);
}
else if (dis > 10 && dis < 15) {
GiveVehicleHealth(v,-300);
}
}
Xbombb[playerid] = 0;
Ybombb[playerid] = 0;
Zbombb[playerid] = 0;
}
return 1;
}
dont work commpilling error
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
if (newkeys==KEY_FIRE)
{ if (Xbombb[playerid] == 0 || Ybombb[playerid] == 0 || Zbombb[playerid] == 0) {
} else {
CreateExplosion(Xbombb[playerid],Ybombb[playerid],Zbombb[playerid],6,1);
CreateExplosion(Xbombb[playerid],Ybombb[playerid],Zbombb[playerid],7,1);
SendClientMessage(playerid,COLOR_GREEN,"* boom");
DestroyObject(bombid[playerid]);
bombid[playerid] = 0;
for (new v = 1; v < MAX_VEHICLES; v++) {
new dis = GetDistanceBetweenVAP(playerid,v);
if (dis < 5) {
SetVehicleHealth(v,0);
}
else if (dis > 5 && dis < 10) {
GiveVehicleHealth(v,-650);
}
else if (dis > 10 && dis < 15) {
GiveVehicleHealth(v,-300);
}
}
Xbombb[playerid] = 0;
Ybombb[playerid] = 0;
Zbombb[playerid] = 0;
}
return 1;
}
if (newkeys==KEY_WALK)
if(GetPlayerMoney(playerid)>=9999)
{
GetPlayerPos(playerid,X,Y,Z);
Xbombb[playerid] = X;
Ybombb[playerid] = Y;
Zbombb[playerid] = Z;
GivePlayerMoney(playerid,-9999);
if (bombid[playerid] == 0) {
} else {
DestroyObject(bombid[playerid]);
}
bombid[playerid] = CreateObject(1252,X,Y + 0.5,Z,0,0,0);
SendClientMessage(playerid,COLOR_GREEN,"* Bomb setup");
}
else if(GetPlayerMoney(playerid)<9999){
SendClientMessage(playerid,COLOR_GREEN,"* No money");
return 1;
}
script commpiling and work
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
if (newkeys==KEY_FIRE)
{ if (Xbombb[playerid] == 0 || Ybombb[playerid] == 0 || Zbombb[playerid] == 0) {
} else {
CreateExplosion(Xbombb[playerid],Ybombb[playerid],Zbombb[playerid],6,1);
CreateExplosion(Xbombb[playerid],Ybombb[playerid],Zbombb[playerid],7,1);
SendClientMessage(playerid,COLOR_GREEN,"* boom");
DestroyObject(bombid[playerid]);
bombid[playerid] = 0;
for (new v = 1; v < MAX_VEHICLES; v++) {
new dis = GetDistanceBetweenVAP(playerid,v);
if (dis < 5) {
SetVehicleHealth(v,0);
}
else if (dis > 5 && dis < 10) {
GiveVehicleHealth(v,-650);
}
else if (dis > 10 && dis < 15) {
GiveVehicleHealth(v,-300);
}
}
Xbombb[playerid] = 0;
Ybombb[playerid] = 0;
Zbombb[playerid] = 0;
}
return 1;
}
dont work commpilling error
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
if (newkeys==KEY_FIRE)
{ if (Xbombb[playerid] == 0 || Ybombb[playerid] == 0 || Zbombb[playerid] == 0) {
} else {
CreateExplosion(Xbombb[playerid],Ybombb[playerid],Zbombb[playerid],6,1);
CreateExplosion(Xbombb[playerid],Ybombb[playerid],Zbombb[playerid],7,1);
SendClientMessage(playerid,COLOR_GREEN,"* boom");
DestroyObject(bombid[playerid]);
bombid[playerid] = 0;
for (new v = 1; v < MAX_VEHICLES; v++) {
new dis = GetDistanceBetweenVAP(playerid,v);
if (dis < 5) {
SetVehicleHealth(v,0);
}
else if (dis > 5 && dis < 10) {
GiveVehicleHealth(v,-650);
}
else if (dis > 10 && dis < 15) {
GiveVehicleHealth(v,-300);
}
}
Xbombb[playerid] = 0;
Ybombb[playerid] = 0;
Zbombb[playerid] = 0;
}
return 1;
}
if (newkeys==KEY_WALK)
if(GetPlayerMoney(playerid)>=9999)
{
GetPlayerPos(playerid,X,Y,Z);
Xbombb[playerid] = X;
Ybombb[playerid] = Y;
Zbombb[playerid] = Z;
GivePlayerMoney(playerid,-9999);
if (bombid[playerid] == 0) {
} else {
DestroyObject(bombid[playerid]);
}
bombid[playerid] = CreateObject(1252,X,Y + 0.5,Z,0,0,0);
SendClientMessage(playerid,COLOR_GREEN,"* Bomb setup");
}
else if(GetPlayerMoney(playerid)<9999){
SendClientMessage(playerid,COLOR_GREEN,"* No money");
return 1;
}