Mark Sibly

Forum Replies Created

Viewing 15 posts - 1,321 through 1,335 (of 1,431 total)
  • Author
    Posts
  • in reply to: I'de like to work on Ted2 #1752

    Mark Sibly
    Keymaster

    It’s open source – go nuts!

    There actually an ‘almost working’ help browser in there – uncomment out this line in mainwindow.monkey2:

    _browser.AddTab( “Help”,_helpView )

    You’ll also need to add a ‘modules.txt’ inside /modules containing a list of modules, eg:

    monkey
    std
    mojo

    in reply to: Time, CurrentTime & etc #1674

    Mark Sibly
    Keymaster

    Time is ‘@hidden’ because it needs more work. See my blog entry re: hidden stuff.

    In particular, I want to implement a ‘TimeSpan’ or ‘DeltaTime’ struct to go along with ‘Time’ (for use with +/- operators) but this needs a bit more thought/planning.

    So use at your own risk! The interface will probably remain much the same but the implementation could change…

    in reply to: String.ToCString() issues #1673

    Mark Sibly
    Keymaster

    > char *dev_name   = “/dev/video0”;

    Literal c/c++ strings like this are stored in ‘read only’ memory and shouldn’t be written to.

    Try this instead…

    char dev_name[256];

    dev_name will intially be ’empty’ but that’s OK because you’re using ToCString to initialize it before you use it (I hope).

    The alternative is to pass the dev_name directly to native code, eg:

    This will automagically convert name to a const char * for you when you call open_dev. However, you should NOT store ‘name’ anywhere inside open_dev for later use as the const char * is temporary and will disappear after open_dev returns.

    in reply to: Ted2 – Monospaced font missing? #1668

    Mark Sibly
    Keymaster

    Actually, I was completely unaware it wasn’t using a monospaced font – will fix!

    in reply to: Help converting old Blitzmax code that uses Extern #1657

    Mark Sibly
    Keymaster

    You need a .h file that declares the externs, and the monkey2 code needs to import that too, eg:

    The weird #ifdef __cplusplus stuff is necessary because c and c++ ‘mangle’ names differently. If you make the c file a cpp file instead, you can ditch this.

    Also, you might want to prefix all the native code idents with ‘v412_’ or something to prevent potential name clashes with other native code.


    Mark Sibly
    Keymaster

    No idea sorry – I don’t do anything ‘special’ when making apps and have never had any admin problems.

    Try a reboot? Delete both .build dirs and try again?

    in reply to: V1.0.0 now out and hearts are back! #1590

    Mark Sibly
    Keymaster

    I’m in your paypal monthly donator list (not as much as I want but as I could).

    Sorry, I missed this bit! You’ve been hearted now…

    Please feel free to go back to paypal donations if you want.

    Since near two years, I’m fighting for PICO-8 (must be seen). It’s a very  tiny but smart game engine (128×128, 16 colors, 8Bit).

    I absolutely love PICO-8!

    in reply to: Memory Generating Vec2fs #1586

    Mark Sibly
    Keymaster

    ‘New Struct’ is always free in terms of memory management, as the new value is always created ‘on the stack’ which has no runtime cost.

    This is the cool thing about ‘value types’ – since they’re always copied and therefore never ‘shared’ via references, they don’t have to be managed in any way.

    ‘New Class’ is never free, but hopefully pretty quick – and it’ll get quicker as I can inline more here.

    in reply to: Ted2 (request) & website (bug) #1584

    Mark Sibly
    Keymaster

    Language reference is working here.

    I found when I added it there were problems with ‘css caching’ which I tried to handle by adding a ‘?v=1’ to the css import. But everything is munged up by wordpress so this may not be working.

    Can you try ‘Ctrl R’ in the developer console? That also flushes the css cache on Chrome anyway.

    in reply to: Implicit type conversions #1445

    Mark Sibly
    Keymaster

    This works fine here:

    If you have defined several overloads of ‘AreEqual’ you may have problems if the compiler can’t work out which one you are meaning to call, eg: if you define AreEqual( Double,Double ) and AreEqual( Long,Long ) then you’ll get an error as AreEqual( 123.45,123.45 ) is ambiguous.

    in reply to: V1.0.0 now out and hearts are back! #1324

    Mark Sibly
    Keymaster

    You’re welcome!

    in reply to: (Bug) Canvas-related? #1278

    Mark Sibly
    Keymaster

    16 canvases should be enough for anyone!

    Actually, I think this is fixed in my version…it works at 10000 anyway.

    New stuff coming soon!

    in reply to: When is Ted2 IDE coming out ? #1271

    Mark Sibly
    Keymaster

    Now at 99.99%! Release coming *very* soon so please hold tight.

    It’s nothing too flash though. I ended up holding back on several features because it was just consuming too much dev time, although I do intend to continue developing it slowly over time.

    But it can compile/run/debug mx2 apps, has a pretty usable editor and of course it will work *anywyhere* you can build mx2 itself. I’ve been using it exclusively myself over the last couple of weeks and am pretty happy with it.

    I think that realistically most people will likely go with 3rd party solutions for IDEs in the near future at least, but it fulfils my goal of making mx2 a completely self contained ‘product’ so I’m happy. And I’m sure that there are other minimalists out there like myself who will find it OK too!

    in reply to: Streaming Audio #1263

    Mark Sibly
    Keymaster

    > How do Monkey2 timers work? Do they interrupt code or fire on app update?

    Timers use the same mechanism as process.finished, process.stdoutready etc mentioned above.

    When the timer fires, it’s handled in timer thread which basically just sticks a custom event in the SDL event queue (which can be done safely from another thread), which will cause the callback to be invoked the next time events are updated.

    The nice thing is that posting the event will also wake up a WaitMsg blocked app so you don’t have to poll.

    in reply to: Streaming Audio #1261

    Mark Sibly
    Keymaster

    Ok, that looks like it’s basically just moving fillBuffer from SDL->mx2 which should work.

    It seems a little long-winded to me though – how about something like:

    I guess it depends on whether it needs to be able to handle variable sized chunks etc – my code assumes a fixed size but I still feel like yours does more copying than it needs to.

Viewing 15 posts - 1,321 through 1,335 (of 1,431 total)