[Gambas-user] timer overlaps
Christopher Brian Jack
brian at ...1334...
Sat Jan 28 01:44:07 CET 2006
On Fri, 27 Jan 2006, Rob Kudla wrote:
> On Fri January 27 2006 16:16, Christopher Brian Jack wrote:
> > So you would be suggestion something like this?
> > Public Sub myTimer_Timer()
>
> I personally have only ever delayed redrawing the screen when I
> ran out of time, but if your client operations may take more
> than a timer tick to complete too, sure, you can do that.
>
> Rob
There's nesting in them there hills. The client of the scheduler (done by
passing ME to a BeginScheduling() method I wrote called from the class
desiring scheduling) has a method "Scheduler" called in the class who
passed itself to the argument of BeginScheduling(). It was good to find a
way to dynamicall do method calls otherwise a lot more chicanery would
have been needed.
I think I'll create another timer specifically for rendering attachment.
Then I need to think about how the game data is going to cope with
asynchronous attempts to render. Sounds like the game logic needs a
Snapshot method to make an instant world-state snapshot from existing data
but in a copy so that the renderer's copy will not be affected by
possibly higher-paced game logic updates. When the renderer starts a pass
it will make a snapshot call to get a "frame" of the game logic to display
to the screen (actually a DrawingArea).
.=================================================.
| Christopher BRIAN Jack aka "Gau of the Veldt" |
+================================================='
| brian _AT_ brians-anime _DOT_ com
| brian _AT_ animemayhem _DOT_ com
| brian _AT_ nall.brians-anime _DOT_ com
| brian _AT_ ruby.brians-anime _DOT_ com
| gau_veldt _AT_ hotmail _DOT_ com
`=================================================-
Hi Spambots, my email address is sputnik at ...1334...
More information about the User
mailing list