Results 1 to 10 of 21

Thread: TBEM - Event manager module V1.10

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    thinBasic MVPs Michael Hartlef's Avatar
    Join Date
    Sep 2006
    Location
    Germany
    Age
    58
    Posts
    3,299
    Rep Power
    348

    TBEM - Event manager module V1.10

    Hi folks,

    I think I have the syntax settled and it is ready to be published. TBEM - Event manager module for thinBasic. It will help you set up events for a game. Well, it could be used for other uses too, but I was thinking more game related, when I was developing it. Included with the module is a little help file that describes the syntax right now. I will wirte some samples tonight to relieve the power of this little module. I'm pretty excited about it as I think it is really a helper when you develop games. Ok, enough bragging. Like I said, samples will follow soon, but the ones who want to play with it allready, download it now.

    Update October 18th, 2008: Version 1.10 uploaded. Bugfixes plus new zone commands

    Here is just a little console sample:

    [code=thinbasic]

    uses "TBEM"
    uses "Console"

    dim event1, event2 as long
    dim y,q,z as long
    dim stime,dtime,etime as dword
    q = 0
    z = 0
    y = 0

    %evg_system = 1
    %evg_user = 2

    %evt_game = 1
    %evt_gui = 2
    %evt_next = 3

    function FinishIt()
    console_writeline(y+") Finish")
    q = 99
    function = 0
    end function

    function getTime()
    y += 1
    console_writeline(y + ") TimeDiff="+dtime)
    function = 0
    end function

    event1 = TBEM_AddEvent("getTime",%evt_gui,getTickcount,%evg_system,%TRUE)
    event2 = TBEM_AddEvent("FinishIt",%evt_game,getTickcount+300,%evg_system,%TRUE)


    stime = gettickcount
    while q = 0
    etime = gettickcount
    dtime = etime - stime
    TBEM_AddTrigger ( %evt_gui)
    TBEM_AddTrigger ( %evt_game)
    TBEM_run(%evg_system)
    wend

    console_writeline("TriggerCount="+TBEM_GetTriggerCount+" EventCount="+TBEM_GetEventCount)

    console_writeline("Press any key...")
    Console_waitkey

    [/code]

    Attached Files Attached Files

Similar Threads

  1. TBEM sample - Add an event
    By Michael Hartlef in forum TBEM module - thinBasic Event Manager module
    Replies: 0
    Last Post: 18-10-2008, 19:07

Members who have read this thread: 0

There are no members to list at the moment.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •