Bank robbed = In fire
#1

Hi,

I tried to make,if a player rob the bank,after he robbed bank,i put a timer of 20 sec.After 20 sec the bank is on fire,but i dont see the fire 2-3sec,after shows up,and dissepearing again...I want to make that fire to remain there and getting more higher with smoke..

Quote:

CreateObject(18689, 1450.7, -1009.3, 26.5, 0, 0, 0);
CreateObject(18689, 1451.2, -1011.2, 26.5, 0, 0, 0);
CreateObject(18689, 1447.5, -1011.5, 26.5, 0, 0, 0);
CreateObject(18689, 1443.6, -1009.5, 26.5, 0, 0, 0);
CreateObject(18689, 1444.7, -1012.1, 26.5, 0, 0, 0);
CreateObject(18689, 1439.4, -1010.7, 26.5, 0, 0, 0);
CreateObject(18689, 1436.2, -1009.8, 26.5, 0, 0, 0);
CreateObject(18689, 1439.2, -1014.5, 26.5, 0, 0, 0);
CreateObject(18689, 1432.9, -1011.8, 26.5, 0, 0, 0);
CreateObject(18689, 1433.9, -1015.9, 25.5, 0, 0, 0);
CreateObject(18689, 1435.4, -1019.9, 23.8, 0, 0, 0);
CreateObject(18689, 1438.2, -1016.2, 24.8, 0, 0, 0);
CreateObject(18689, 1444.5, -1017.8, 24.8, 0, 0, 0);
CreateObject(18689, 1448.9, -1018.7, 24.8, 0, 0, 0);
CreateObject(18689, 1440.3, -1019.2, 24.3, 0, 0, 0);
CreateObject(18689, 1443.3, -1015.4, 25.8, 0, 0, 0);
CreateObject(18689, 1444.8, -1021.5, 23.5, 0, 0, 0);
CreateObject(18689, 1441.2, -1021.6, 23.5, 0, 0, 0);
CreateObject(18689, 1449.6, -1021.2, 23.5, 0, 0, 0);
CreateObject(18689, 1454.4, -1021.6, 23.5, 0, 0, 0);
CreateObject(18689, 1461.2, -1020.9, 24.3, 0, 0, 0);
CreateObject(18689, 1467.4, -1021.2, 24.3, 0, 0, 0);
CreateObject(18689, 1470.1, -1022.5, 23.3, 0, 0, 0);
CreateObject(18689, 1463.3, -1023.2, 23.3, 0, 0, 0);
CreateObject(18689, 1465.1, -1016.7, 25.3, 0, 0, 0);
CreateObject(18689, 1458.1, -1016.6, 25.3, 0, 0, 0);
CreateObject(18689, 1453.3, -1016.5, 25.3, 0, 0, 0);
CreateObject(18689, 1469.8, -1016.5, 25.3, 0, 0, 0);
CreateObject(18689, 1464.2, -1018.4, 24.3, 0, 0, 0);
CreateObject(18689, 1457.5, -1018.3, 24.3, 0, 0, 0);
CreateObject(18689, 1455.6, -1012.2, 26.8, 0, 0, 0);
CreateObject(18689, 1459.8, -1012.6, 26.8, 0, 0, 0);
CreateObject(18689, 1462.3, -1010.1, 26.8, 0, 0, 0);
CreateObject(18689, 1469.2, -1010.2, 26.8, 0, 0, 0);
CreateObject(18689, 1472.2, -1011.5, 26.3, 0, 0, 0);
CreateObject(18689, 1465.5, -1012.4, 26.3, 0, 0, 0);
CreateObject(18689, 1461.5, -1015.1, 25.3, 0, 0, 0);
CreateObject(18689, 1475.5, -1011.5, 26.5, 0, 0, 0);
CreateObject(18689, 1479.5, -1009.8, 26.5, 0, 0, 0);
CreateObject(18689, 1482.7, -1011.6, 26.5, 0, 0, 0);
CreateObject(18689, 1486.2, -1009.1, 26.5, 0, 0, 0);
CreateObject(18689, 1491.2, -1009.2, 26.5, 0, 0, 0);
CreateObject(18689, 1489.4, -1012.7, 26.5, 0, 0, 0);
CreateObject(18689, 1485.7, -1012.7, 26.5, 0, 0, 0);
CreateObject(18689, 1490.4, -1015.8, 25.5, 0, 0, 0);
CreateObject(18689, 1486.2, -1015.7, 25.5, 0, 0, 0);
CreateObject(18689, 1482.2, -1015.6, 25.5, 0, 0, 0);
CreateObject(18689, 1478.5, -1015.6, 25.5, 0, 0, 0);
CreateObject(18689, 1474.5, -1015.5, 25.5, 0, 0, 0);
CreateObject(18689, 1474.5, -1019.2, 24.3, 0, 0, 0);
CreateObject(18689, 1477.7, -1019.2, 24.3, 0, 0, 0);
CreateObject(18689, 1481.2, -1017.5, 24.8, 0, 0, 0);
CreateObject(18689, 1486.9, -1017.6, 24.8, 0, 0, 0);
CreateObject(18689, 1490.6, -1018.1, 24.8, 0, 0, 0);
CreateObject(18689, 1490.6, -1020.6, 24.5, 0, 0, 0);
CreateObject(18689, 1485.8, -1020.5, 24.5, 0, 0, 0);
CreateObject(18689, 1481.3, -1020.4, 24.5, 0, 0, 0);
CreateObject(18689, 1475.8, -1021.6, 24.5, 0, 0, 0);
CreateObject(18689, 1475.8, -1024.3, 23.3, 0, 0, 0);
CreateObject(18689, 1481.6, -1022.9, 23.3, 0, 0, 0);
CreateObject(18689, 1488.3, -1023.7, 23.3, 0, 0, 0);
CreateObject(18689, 1482.1, -1022.4, 33.5, 0, 0, 0);
CreateObject(18689, 1477.6, -1022.2, 34.5, 0, 0, 0);
CreateObject(18689, 1477.6, -1022.2, 31.5, 0, 0, 0);
CreateObject(18689, 1474.3, -1022.3, 32.5, 0, 0, 0);
CreateObject(18689, 1470.1, -1022.1, 32.5, 0, 0, 0);
CreateObject(18689, 1465.4, -1021.9, 34.2, 0, 0, 0);
CreateObject(18689, 1470.2, -1020.3, 34.5, 0, 0, 0);
CreateObject(18689, 1462.5, -1020.2, 31.5, 0, 0, 0);
CreateObject(18689, 1456.2, -1020.5, 31.5, 0, 0, 0);
CreateObject(18689, 1454.2, -1020.9, 33.3, 0, 0, 0);
CreateObject(18689, 1459.2, -1020.3, 33.3, 0, 0, 0);
CreateObject(18689, 1448.6, -1022.1, 33.3, 0, 0, 0);
CreateObject(18689, 1448.5, -1022.1, 33.3, 0, 0, 0);
CreateObject(18689, 1451.6, -1021.7, 31.3, 0, 0, 0);
CreateObject(18689, 1447.1, -1022.5, 31.3, 0, 0, 0);
CreateObject(18689, 1444.9, -1022.4, 33.2, 0, 0, 0);
CreateObject(18689, 1439.4, -1022.4, 33.2, 0, 0, 0);
CreateObject(18689, 1442.4, -1021.5, 30.5, 0, 0, 0);
CreateObject(18689, 1434.2, -1021.2, 30.5, 0, 0, 0);
CreateObject(18689, 1434.2, -1022.2, 32.8, 0, 0, 0);
CreateObject(18689, 1428.5, -1022.2, 32.8, 0, 0, 0);
CreateObject(18689, 1428.5, -1021.3, 28.5, 0, 0, 0);
CreateObject(18689, 1431.7, -1022.4, 24.2, 0, 0, 0);
CreateObject(18689, 1495.6, -1022.5, 30.3, 0, 0, 0);
CreateObject(18689, 1495.6, -1022.7, 24.5, 0, 0, 0);
CreateObject(18689, 1492.4, -1022.5, 23.3, 0, 0, 0);
CreateObject(18727, 1450.7, -1009.3, 26.5, 0, 0, 0);
CreateObject(18727, 1451.2, -1011.2, 26.5, 0, 0, 0);
CreateObject(18727, 1447.5, -1011.5, 26.5, 0, 0, 0);
CreateObject(18727, 1443.6, -1009.5, 26.5, 0, 0, 0);
CreateObject(18727, 1444.7, -1012.1, 26.5, 0, 0, 0);
CreateObject(18727, 1439.4, -1010.7, 26.5, 0, 0, 0);
CreateObject(18727, 1436.2, -1009.8, 26.5, 0, 0, 0);
CreateObject(18727, 1439.2, -1014.5, 26.5, 0, 0, 0);
CreateObject(18727, 1432.9, -1011.8, 26.5, 0, 0, 0);
CreateObject(18727, 1433.9, -1015.9, 25.2, 0, 0, 0);
CreateObject(18727, 1435.4, -1019.9, 23.8, 0, 0, 0);
CreateObject(18727, 1438.2, -1016.2, 24.8, 0, 0, 0);
CreateObject(18727, 1444.5, -1017.8, 24.8, 0, 0, 0);
CreateObject(18727, 1448.9, -1018.7, 24.8, 0, 0, 0);
CreateObject(18727, 1440.3, -1019.5, 24.3, 0, 0, 0);
CreateObject(18727, 1443.3, -1015.4, 25.8, 0, 0, 0);
CreateObject(18727, 1444.8, -1021.5, 23.5, 0, 0, 0);
CreateObject(18727, 1441.2, -1021.6, 23.5, 0, 0, 0);
CreateObject(18727, 1449.6, -1021.5, 23.5, 0, 0, 0);
CreateObject(18727, 1454.4, -1021.6, 23.5, 0, 0, 0);
CreateObject(18727, 1461.2, -1020.9, 24.3, 0, 0, 0);
CreateObject(18727, 1467.4, -1021.5, 24.3, 0, 0, 0);
CreateObject(18727, 1470.1, -1022.5, 23.3, 0, 0, 0);
CreateObject(18727, 1463.3, -1023.2, 23.3, 0, 0, 0);
CreateObject(18727, 1465.1, -1016.7, 25.3, 0, 0, 0);
CreateObject(18727, 1458.1, -1016.6, 25.3, 0, 0, 0);
CreateObject(18727, 1453.3, -1016.5, 25.3, 0, 0, 0);
CreateObject(18727, 1469.8, -1016.5, 25.3, 0, 0, 0);
CreateObject(18727, 1464.2, -1018.4, 24.3, 0, 0, 0);
CreateObject(18727, 1457.5, -1018.3, 24.3, 0, 0, 0);
CreateObject(18727, 1455.6, -1012.2, 26.8, 0, 0, 0);
CreateObject(18727, 1459.8, -1012.6, 26.8, 0, 0, 0);
CreateObject(18727, 1462.3, -1010.1, 26.8, 0, 0, 0);
CreateObject(18727, 1469.2, -1010.2, 26.8, 0, 0, 0);
CreateObject(18727, 1472.2, -1011.5, 26.3, 0, 0, 0);
CreateObject(18727, 1465.5, -1012.4, 26.3, 0, 0, 0);
CreateObject(18727, 1461.5, -1015.1, 25.3, 0, 0, 0);
CreateObject(18727, 1475.5, -1011.5, 26.5, 0, 0, 0);
CreateObject(18727, 1479.5, -1009.8, 26.5, 0, 0, 0);
CreateObject(18727, 1482.7, -1011.6, 26.5, 0, 0, 0);
CreateObject(18727, 1486.2, -1009.1, 26.5, 0, 0, 0);
CreateObject(18727, 1491.2, -1009.2, 26.5, 0, 0, 0);
CreateObject(18727, 1489.4, -1012.7, 26.5, 0, 0, 0);
CreateObject(18727, 1485.7, -1012.7, 26.5, 0, 0, 0);
CreateObject(18727, 1490.4, -1015.8, 25.5, 0, 0, 0);
CreateObject(18727, 1486.2, -1015.7, 25.5, 0, 0, 0);
CreateObject(18727, 1482.2, -1015.6, 25.5, 0, 0, 0);
CreateObject(18727, 1478.5, -1015.6, 25.5, 0, 0, 0);
CreateObject(18727, 1474.5, -1015.5, 25.5, 0, 0, 0);
CreateObject(18727, 1474.5, -1019.2, 24.3, 0, 0, 0);
CreateObject(18727, 1477.7, -1019.2, 24.3, 0, 0, 0);
CreateObject(18727, 1481.2, -1017.5, 24.8, 0, 0, 0);
CreateObject(18727, 1486.9, -1017.6, 24.8, 0, 0, 0);
CreateObject(18727, 1490.6, -1018.1, 24.8, 0, 0, 0);
CreateObject(18727, 1490.6, -1020.6, 24.2, 0, 0, 0);
CreateObject(18727, 1485.8, -1020.5, 24.2, 0, 0, 0);
CreateObject(18727, 1481.3, -1020.4, 24.2, 0, 0, 0);
CreateObject(18727, 1475.8, -1021.6, 24.2, 0, 0, 0);
CreateObject(18727, 1475.8, -1024.3, 23.3, 0, 0, 0);
CreateObject(18727, 1481.6, -1022.9, 23.3, 0, 0, 0);
CreateObject(18727, 1488.3, -1023.7, 23.3, 0, 0, 0);
CreateObject(18727, 1482.1, -1022.4, 33.2, 0, 0, 0);
CreateObject(18727, 1477.6, -1022.2, 34.2, 0, 0, 0);
CreateObject(18727, 1477.6, -1022.2, 31.2, 0, 0, 0);
CreateObject(18727, 1474.3, -1022.3, 32.5, 0, 0, 0);
CreateObject(18727, 1470.1, -1022.1, 32.5, 0, 0, 0);
CreateObject(18727, 1465.4, -1021.9, 34.2, 0, 0, 0);
CreateObject(18727, 1470.2, -1020.3, 34.5, 0, 0, 0);
CreateObject(18727, 1462.5, -1020.2, 31.5, 0, 0, 0);
CreateObject(18727, 1456.2, -1020.5, 31.5, 0, 0, 0);
CreateObject(18727, 1454.2, -1020.9, 33.3, 0, 0, 0);
CreateObject(18727, 1459.2, -1020.3, 33.3, 0, 0, 0);
CreateObject(18727, 1448.6, -1022.1, 33.3, 0, 0, 0);
CreateObject(18727, 1448.5, -1022.1, 33.3, 0, 0, 0);
CreateObject(18727, 1451.6, -1021.7, 31.3, 0, 0, 0);
CreateObject(18727, 1447.1, -1022.5, 31.3, 0, 0, 0);
CreateObject(18727, 1444.9, -1022.4, 33.2, 0, 0, 0);
CreateObject(18727, 1439.4, -1022.4, 33.2, 0, 0, 0);
CreateObject(18727, 1442.4, -1021.5, 30.5, 0, 0, 0);
CreateObject(18727, 1434.2, -1021.2, 30.5, 0, 0, 0);
CreateObject(18727, 1434.2, -1022.2, 32.8, 0, 0, 0);
CreateObject(18727, 1428.5, -1022.2, 32.8, 0, 0, 0);
CreateObject(18727, 1428.5, -1021.3, 28.5, 0, 0, 0);
CreateObject(18727, 1431.7, -1022.4, 24.2, 0, 0, 0);
CreateObject(18727, 1495.6, -1022.5, 30.3, 0, 0, 0);
CreateObject(18727, 1495.6, -1022.7, 24.5, 0, 0, 0);
CreateObject(18727, 1492.4, -1022.5, 23.3, 0, 0, 0);

Reply
#2

Show the code that's not working, we're not here to script a system for you.
Reply
#3

I do not understand what code u want?
This "createobjects" i put them to rob.When player rob the bank after 20 sec is creating the objects fire and smoke.That's all.But it's not getting all fire,sometimes i don't see the fire
Reply
#4

Quote:
Originally Posted by duteba
Посмотреть сообщение
I do not understand what code u want?
This "createobjects" i put them to rob.When player rob the bank after 20 sec is creating the objects fire and smoke.That's all.But it's not getting all fire,sometimes i don't see the fire
Show THIS code that you're speaking about, not the objects.
Reply
#5

Show the timer, how you create them, the robbery or all that stuff you are talking about, you're just showing some objects, which we can't help with.
Reply
#6

Quote:

public RobFunc(playerid)
{
TogglePlayerControllable(playerid, 1);
TextDrawHideForPlayer(playerid, Rob[playerid]);
TextDrawHideForPlayer(playerid, Rob2[playerid]);
CP[playerid] = 50;
new rand;
rand = random(sizeof(gRandomRob));
SetPlayerCheckpoint(playerid, gRandomRob[rand][0],gRandomRob[rand][1],gRandomRob[rand][2], 4.0);
SendClientMessage(playerid, COLOR_YELLOW,"Go to checkpoint to finish breaking the bank.");
SetPlayerWantedLevel(playerid, 6);
PlayerInfo[playerid][pWantedLevel] = 6;
WantedPoints[playerid] = 12;
SetPlayerCriminal(playerid,255, "Robbed the bank.");
BizzInfo[1][bProducts] -= 20;
PlayerInfo[playerid][pRob] -= 20;
Update(playerid,pRobx);
Update(playerid,pWantedLevelx);
new str[184];
format(str,sizeof(str),"UPDATE `bizz` SET `Products`='%d' WHERE `ID`='1'",BizzInfo[1][bProducts]);
mysql_query(SQL,str);
SetPlayerAttachedObject( playerid, 0, 1550, 1, 0.024558, -0.279748, -0.060589, 6.105677, 137.291320, 147.132202, 1.019888, 1.000000, 1.000000 );
ClearAnimations(playerid);
TIMER TO GET EXPLOSION ----------> ExplodeRobTimer[playerid] = SetTimerEx("ExplodeRob",20000,false,"i",playerid);
foreach(Player,i)
{
if(IsPlayerConnected(i))
{
if(PlayerInfo[i][pLeader] == 1 || PlayerInfo[i][pMember] == 1 || PlayerInfo[i][pLeader] == 2 || PlayerInfo[i][pMember] == 2 || PlayerInfo[i][pLeader] == 3 || PlayerInfo[i][pMember] == 3)
{
new pName[24];
GetPlayerName(i, pName, 24);
format(str, 128,"Bank was robbed by %s, all units under alert!", pName);
SendClientMessage(i, COLOR_BLUE, str);
}
}
}
return 1;
}

Quote:

forward ExplodeRob(playerid);
public ExplodeRob(playerid)
{
CreateExplosion(1436.2120,-1013.2317,26.8438,2,100);
CreateExplosion(1440.7985,-1013.0107,26.8438,2,100);
CreateExplosion(1449.6451,-1014.8251,26.4299,2,100);
CreateExplosion(1449.3009,-1019.2944,24.7603,2,100);
CreateExplosion(1442.7583,-1020.4545,24.3269,2,100);
CreateExplosion(1433.7386,-1019.4755,24.6927,2,100);
CreateExplosion(1432.7233,-1023.1675,23.8281,2,100);
CreateExplosion(1438.9886,-1023.5110,23.8281,2,100);
CreateExplosion(1446.2384,-1023.1240,23.8281,2,100);
CreateExplosion(1452.5627,-1022.9641,23.8281,2,100);
CreateExplosion(1460.5977,-1022.8536,23.8281,2,100);
CreateExplosion(1469.8904,-1022.8215,23.8331,2,100);
CreateExplosion(1470.2592,-1019.5565,24.6624,2,100);
CreateExplosion(1466.7705,-1019.3690,24.7324,2,100);
CreateExplosion(1457.6558,-1019.2634,24.7719,2,100);
CreateExplosion(1455.2819,-1016.7610,25.7067,2,100);
CreateExplosion(1458.9384,-1016.0167,25.9847,2,100);
CreateExplosion(1464.2939,-1015.9390,26.0138,2,100);
CreateExplosion(1470.1294,-1015.6710,26.1139,2,100);
CreateExplosion(1471.4380,-1011.9886,26.8438,2,100);
CreateExplosion(1466.1749,-1011.6865,26.8438,2,100);
CreateExplosion(1461.0853,-1011.8094,26.8438,2,100);
CreateExplosion(1455.3788,-1011.8680,26.8438,2,100);
CreateExplosion(1475.1528,-1012.0660,26.8438,2,100);
CreateExplosion(1479.0438,-1011.5827,26.8438,2,100);
CreateExplosion(1483.2681,-1011.8271,26.8438,2,100);
CreateExplosion(1490.0756,-1012.2212,26.8438,2,100);
CreateExplosion(1491.6881,-1015.4674,26.1899,2,100);
CreateExplosion(1486.5857,-1015.5352,26.1646,2,100);
CreateExplosion(1480.1237,-1015.9203,26.0207,2,100);
CreateExplosion(1475.0807,-1016.2212,25.9083,2,100);
CreateExplosion(1474.0747,-1019.0797,24.8405,2,100);
CreateExplosion(1478.5372,-1019.2482,24.7776,2,100);
CreateExplosion(1485.5519,-1019.0394,24.8556,2,100);
CreateExplosion(1491.4349,-1021.8339,23.8281,2,100);
CreateExplosion(1484.9482,-1021.8837,23.8281,2,100);
CreateExplosion(1478.6887,-1021.6588,23.8770,2,100);
CreateExplosion(1473.2465,-1021.4496,23.9552,2,100);
CreateObject(18727,1436.2120,-1013.2317,26.8438, 0, 0, 0);
CreateObject(18727,1440.7985,-1013.0107,26.8438, 0, 0, 0);
CreateObject(18727,1449.6451,-1014.8251,26.4299, 0, 0, 0);
CreateObject(18727,1449.3009,-1019.2944,24.7603, 0, 0, 0);
CreateObject(18727,1442.7583,-1020.4545,24.3269, 0, 0, 0);
CreateObject(18727,1433.7386,-1019.4755,24.6927, 0, 0, 0);
CreateObject(18727,1432.7233,-1023.1675,23.8281, 0, 0, 0);
CreateObject(18727,1438.9886,-1023.5110,23.8281, 0, 0, 0);
CreateObject(18727,1446.2384,-1023.1240,23.8281, 0, 0, 0);
CreateObject(18727,1452.5627,-1022.9641,23.8281, 0, 0, 0);
CreateObject(18727,1460.5977,-1022.8536,23.8281, 0, 0, 0);
CreateObject(18727,1469.8904,-1022.8215,23.8331, 0, 0, 0);
CreateObject(18727,1470.2592,-1019.5565,24.6624, 0, 0, 0);
CreateObject(18727,1466.7705,-1019.3690,24.7324, 0, 0, 0);
CreateObject(18727,1457.6558,-1019.2634,24.7719, 0, 0, 0);
CreateObject(18727,1455.2819,-1016.7610,25.7067, 0, 0, 0);
CreateObject(18727,1458.9384,-1016.0167,25.9847, 0, 0, 0);
CreateObject(18727,1464.2939,-1015.9390,26.0138, 0, 0, 0);
CreateObject(18727,1470.1294,-1015.6710,26.1139, 0, 0, 0);
CreateObject(18727,1471.4380,-1011.9886,26.8438, 0, 0, 0);
CreateObject(18727,1466.1749,-1011.6865,26.8438, 0, 0, 0);
CreateObject(18727,1461.0853,-1011.8094,26.8438, 0, 0, 0);
CreateObject(18727,1455.3788,-1011.8680,26.8438, 0, 0, 0);
CreateObject(18727,1475.1528,-1012.0660,26.8438, 0, 0, 0);
CreateObject(18727,1479.0438,-1011.5827,26.8438, 0, 0, 0);
CreateObject(18727,1483.2681,-1011.8271,26.8438, 0, 0, 0);
CreateObject(18727,1490.0756,-1012.2212,26.8438, 0, 0, 0);
CreateObject(18727,1491.6881,-1015.4674,26.1899, 0, 0, 0);
CreateObject(18727,1486.5857,-1015.5352,26.1646, 0, 0, 0);
CreateObject(18727,1480.1237,-1015.9203,26.0207, 0, 0, 0);
CreateObject(18727,1475.0807,-1016.2212,25.9083, 0, 0, 0);
CreateObject(18727,1474.0747,-1019.0797,24.8405, 0, 0, 0);
CreateObject(18727,1478.5372,-1019.2482,24.7776, 0, 0, 0);
CreateObject(18727,1485.5519,-1019.0394,24.8556, 0, 0, 0);
CreateObject(18727,1491.4349,-1021.8339,23.8281, 0, 0, 0);
CreateObject(18727,1484.9482,-1021.8837,23.8281, 0, 0, 0);
CreateObject(18727,1478.6887,-1021.6588,23.8770, 0, 0, 0);
CreateObject(18727,1473.2465,-1021.4496,23.9552, 0, 0, 0);
KillTimer(ExplodeRobTimer[playerid]);
return 1;
}

This is all the code
Reply
#7

Up!Someone can help me?
Reply
#8

i guess use another timer for explosion, can't understand problem, creating another timer might fix it :#

pawn Код:
public RobFunc(playerid)
{
    TogglePlayerControllable(playerid, 1);
    TextDrawHideForPlayer(playerid, Rob[playerid]);
    TextDrawHideForPlayer(playerid, Rob2[playerid]);
    CP[playerid] = 50;
    new rand;
    rand = random(sizeof(gRandomRob));
    SetPlayerCheckpoint(playerid, gRandomRob[rand][0],gRandomRob[rand][1],gRandomRob[rand][2], 4.0);
    SendClientMessage(playerid, COLOR_YELLOW,"Go to checkpoint to finish breaking the bank.");
    SetPlayerWantedLevel(playerid, 6);
    PlayerInfo[playerid][pWantedLevel] = 6;
    WantedPoints[playerid] = 12;
    SetPlayerCriminal(playerid,255, "Robbed the bank.");
    BizzInfo[1][bProducts] -= 20;
    PlayerInfo[playerid][pRob] -= 20;
    Update(playerid,pRobx);
    Update(playerid,pWantedLevelx);
    new str[184];
    format(str,sizeof(str),"UPDATE `bizz` SET `Products`='%d' WHERE `ID`='1'",BizzInfo[1][bProducts]);
    mysql_query(SQL,str);
    SetPlayerAttachedObject( playerid, 0, 1550, 1, 0.024558, -0.279748, -0.060589, 6.105677, 137.291320, 147.132202, 1.019888, 1.000000, 1.000000 );
    ClearAnimations(playerid);
    ExplodeRobTimer[playerid] = SetTimerEx("ExplodeRob",20000,false,"i",playerid);
    SetTimer("Explosions",20000,false);
    foreach(Player,i)
    {
        if(IsPlayerConnected(i))
        {
            if(PlayerInfo[i][pLeader] == 1 || PlayerInfo[i][pMember] == 1 || PlayerInfo[i][pLeader] == 2 || PlayerInfo[i][pMember] == 2 || PlayerInfo[i][pLeader] == 3 || PlayerInfo[i][pMember] == 3)
            {
                new pName[24];
                GetPlayerName(i, pName, 24);
                format(str, 128,"Bank was robbed by %s, all units under alert!", pName);
                SendClientMessage(i, COLOR_BLUE, str);
            }
        }
    }
    return 1;
}

forward ExplodeRob(playerid);
public ExplodeRob(playerid)
{
    KillTimer(ExplodeRobTimer[playerid]);
    return 1;
}

forward Explosions();
public Explosions()
{
   CreateExplosion(1436.2120,-1013.2317,26.8438,2,100);
   CreateExplosion(1440.7985,-1013.0107,26.8438,2,100);
   CreateExplosion(1449.6451,-1014.8251,26.4299,2,100);
   CreateExplosion(1449.3009,-1019.2944,24.7603,2,100);
   CreateExplosion(1442.7583,-1020.4545,24.3269,2,100);
   CreateExplosion(1433.7386,-1019.4755,24.6927,2,100);
   CreateExplosion(1432.7233,-1023.1675,23.8281,2,100);
   CreateExplosion(1438.9886,-1023.5110,23.8281,2,100);
   CreateExplosion(1446.2384,-1023.1240,23.8281,2,100);
   CreateExplosion(1452.5627,-1022.9641,23.8281,2,100);
   CreateExplosion(1460.5977,-1022.8536,23.8281,2,100);
   CreateExplosion(1469.8904,-1022.8215,23.8331,2,100);
   CreateExplosion(1470.2592,-1019.5565,24.6624,2,100);
   CreateExplosion(1466.7705,-1019.3690,24.7324,2,100);
   CreateExplosion(1457.6558,-1019.2634,24.7719,2,100);
   CreateExplosion(1455.2819,-1016.7610,25.7067,2,100);
   CreateExplosion(1458.9384,-1016.0167,25.9847,2,100);
   CreateExplosion(1464.2939,-1015.9390,26.0138,2,100);
   CreateExplosion(1470.1294,-1015.6710,26.1139,2,100);
   CreateExplosion(1471.4380,-1011.9886,26.8438,2,100);
   CreateExplosion(1466.1749,-1011.6865,26.8438,2,100);
   CreateExplosion(1461.0853,-1011.8094,26.8438,2,100);
   CreateExplosion(1455.3788,-1011.8680,26.8438,2,100);
   CreateExplosion(1475.1528,-1012.0660,26.8438,2,100);
   CreateExplosion(1479.0438,-1011.5827,26.8438,2,100);
   CreateExplosion(1483.2681,-1011.8271,26.8438,2,100);
   CreateExplosion(1490.0756,-1012.2212,26.8438,2,100);
   CreateExplosion(1491.6881,-1015.4674,26.1899,2,100);
   CreateExplosion(1486.5857,-1015.5352,26.1646,2,100);
   CreateExplosion(1480.1237,-1015.9203,26.0207,2,100);
   CreateExplosion(1475.0807,-1016.2212,25.9083,2,100);
   CreateExplosion(1474.0747,-1019.0797,24.8405,2,100);
   CreateExplosion(1478.5372,-1019.2482,24.7776,2,100);
   CreateExplosion(1485.5519,-1019.0394,24.8556,2,100);
   CreateExplosion(1491.4349,-1021.8339,23.8281,2,100);
   CreateExplosion(1484.9482,-1021.8837,23.8281,2,100);
   CreateExplosion(1478.6887,-1021.6588,23.8770,2,100);
   CreateExplosion(1473.2465,-1021.4496,23.9552,2,100);
   CreateObject(18727,1436.2120,-1013.2317,26.8438, 0, 0, 0);
   CreateObject(18727,1440.7985,-1013.0107,26.8438, 0, 0, 0);
   CreateObject(18727,1449.6451,-1014.8251,26.4299, 0, 0, 0);
   CreateObject(18727,1449.3009,-1019.2944,24.7603, 0, 0, 0);
   CreateObject(18727,1442.7583,-1020.4545,24.3269, 0, 0, 0);
   CreateObject(18727,1433.7386,-1019.4755,24.6927, 0, 0, 0);
   CreateObject(18727,1432.7233,-1023.1675,23.8281, 0, 0, 0);
   CreateObject(18727,1438.9886,-1023.5110,23.8281, 0, 0, 0);
   CreateObject(18727,1446.2384,-1023.1240,23.8281, 0, 0, 0);
   CreateObject(18727,1452.5627,-1022.9641,23.8281, 0, 0, 0);
   CreateObject(18727,1460.5977,-1022.8536,23.8281, 0, 0, 0);
   CreateObject(18727,1469.8904,-1022.8215,23.8331, 0, 0, 0);
   CreateObject(18727,1470.2592,-1019.5565,24.6624, 0, 0, 0);
   CreateObject(18727,1466.7705,-1019.3690,24.7324, 0, 0, 0);
   CreateObject(18727,1457.6558,-1019.2634,24.7719, 0, 0, 0);
   CreateObject(18727,1455.2819,-1016.7610,25.7067, 0, 0, 0);
   CreateObject(18727,1458.9384,-1016.0167,25.9847, 0, 0, 0);
   CreateObject(18727,1464.2939,-1015.9390,26.0138, 0, 0, 0);
   CreateObject(18727,1470.1294,-1015.6710,26.1139, 0, 0, 0);
   CreateObject(18727,1471.4380,-1011.9886,26.8438, 0, 0, 0);
   CreateObject(18727,1466.1749,-1011.6865,26.8438, 0, 0, 0);
   CreateObject(18727,1461.0853,-1011.8094,26.8438, 0, 0, 0);
   CreateObject(18727,1455.3788,-1011.8680,26.8438, 0, 0, 0);
   CreateObject(18727,1475.1528,-1012.0660,26.8438, 0, 0, 0);
   CreateObject(18727,1479.0438,-1011.5827,26.8438, 0, 0, 0);
   CreateObject(18727,1483.2681,-1011.8271,26.8438, 0, 0, 0);
   CreateObject(18727,1490.0756,-1012.2212,26.8438, 0, 0, 0);
   CreateObject(18727,1491.6881,-1015.4674,26.1899, 0, 0, 0);
   CreateObject(18727,1486.5857,-1015.5352,26.1646, 0, 0, 0);
   CreateObject(18727,1480.1237,-1015.9203,26.0207, 0, 0, 0);
   CreateObject(18727,1475.0807,-1016.2212,25.9083, 0, 0, 0);
   CreateObject(18727,1474.0747,-1019.0797,24.8405, 0, 0, 0);
   CreateObject(18727,1478.5372,-1019.2482,24.7776, 0, 0, 0);
   CreateObject(18727,1485.5519,-1019.0394,24.8556, 0, 0, 0);
   CreateObject(18727,1491.4349,-1021.8339,23.8281, 0, 0, 0);
   CreateObject(18727,1484.9482,-1021.8837,23.8281, 0, 0, 0);
   CreateObject(18727,1478.6887,-1021.6588,23.8770, 0, 0, 0);
   CreateObject(18727,1473.2465,-1021.4496,23.9552, 0, 0, 0);
   return 1;
}
Reply
#9

I do not understand why i should use 2 timers?...I want to make the bank to be on fire,after someone robbed the bank.After player leave bank,in 10-15 sec,to creating explosion and to be a lot of fire...and smoke
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)