waitevent() is crap

BlitzMax Forums/BlitzMax Programming/waitevent() is crap

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

Ok, The waitevent() system seems to be causing more trouble than good. What happened to the good ole days of b+ waitevent()??

Right now I'm having to do this:
Global flipTimer:TTimer = CreateTimer(1000) 
Waitevent()
If EventID()=EVENT_TIMERTICK and EventSource()= flipTimer then Flip 


What are other viable solutions to the waitevent() varmin??? (p.s. adding a hook system didnt seem to do much good, the above way was better, but there has to be even better!!!!)

AddHook EmitEventHook, flipitHook

Function flipitHook:Object(iId:Int,TData:Object,tContext:Object)
  Local event:TEvent=TEvent(TData)
   
  If  event.source=flipTimer and event.id=EVENT_TIMERTICK  
     Flip 
     Return Null
  EndIf

  Return TData
End Function