Some of you may know I'm making a game called speedball (just put speedball in the search box), well in this game there are going to be some obstacles that appear and disappear every second. Meaning that you need timing to get past them.
The problem is that these obstacles are currently working inefficently. Occasionally they don't reappear or disappear at the correct time and sometimes only a few obstacles reappear.
I was wondering if it was anything to do with the below code that controls the appearing/disappearing. Can anyone help
+ Code Snippetfor a=3 to 600
if object exist(a)=1
if active(a)=8 and (timer()-tii3)/1000>0 and object visible(a)=1 then hide object a : sc_setupobject a,0,0
if active(a)=10 and (timer()-tii3)/1000>0 and object visible(a)=1 then hide object a : sc_setupobject a,0,0
if active(a)=8 and (timer()-tii3)/1000>1 and object visible(a)=0 then show object a : sc_setupobject a,1,0
if active(a)=10 and (timer()-tii3)/1000>1 and object visible(a)=0 then show object a : sc_setupobject a,1,0
endif
if a=600 and (timer()-tii3)/1000>1 then tii3=timer()
next a