Forum Jump :

Author Message

yussy  



Posts: 2
Rank:


Level: Member

Country: fi
Location:
Occupation:
Age:
In-game name:

 
#1 Posted at 2017-09-20 00:24        
     
So basically I made a script that makes enemy mortar fire at your position when inside a trigger and spotted by enemy team. I've tried to make it loop so the mortar shoots at your position every 20 seconds while you are inside the trigger, but the mortar keeps shooting with ~3 second delay when the guy is reloading. So how can I make it 20 seconds?

Script:
trigger name: trigger1
condition: trigger1
On act.: mortar1 commandArtilleryFire [getposatl (thislist select 0), "8Rnd_82mm_Mo_shells", 1]; trigger1=false;
on deact.: trigger1=true;

On player's unit:
init:trigger1=true;


Author Message


Posts: 1484
Rank:


Level: Member

Country: uk
Location:
Occupation:
Age:
In-game name:

 
#2 Posted at 2017-09-20 01:32        
     
forget all the true false variables that works well for fast trigger every 0.5 second but no use here

all you need is this in the cond

round (time %20) == 20

on act
 mortar1 commandArtilleryFire [getposatl (thislist select 0), "8Rnd_82mm_Mo_shells", 1];


Advertisement


Author Message

yussy  



Posts: 2
Rank:


Level: Member

Country: fi
Location:
Occupation:
Age:
In-game name:

 
#3 Posted at 2017-09-20 15:19        
     
# F2kSel : forget all the true false variables that works well for fast trigger every 0.5 second but no use here

all you need is this in the cond

round (time %20) == 20

on act
 mortar1 commandArtilleryFire [getposatl (thislist select 0), "8Rnd_82mm_Mo_shells", 1];
It worked! Thank you