skymen's Forum Posts

  • Yeah, 20%CPU could probably have been improved in my latest implementation. Also note that CPU % varies a lot between computers, so maybe you have worse perf because you're previewing on browser vs NW.js or because you have a lower end laptop, I don't know.

    As an effect, trail isn't possible as far as I know. C3's effect system doesn't allow us to define effects that get applied over multiple frames, and to work you'd need to specify a lot of parameters and it'd be too much work for an end result that wouldn't be insane.

    As a behavior however, there is a point to be made, but the main limitation would be drawing on screen, and behaviors can't do that on their own.

    The best solution IMO would be an object type with a ton of parameters that draws a trail over its last positions, and you'd just move it to wherever you want, and it'd draw a trail on its own. It'd be even more useful with the new Scene graph that's coming to C3, because then adding a trail would just be inserting the object as a child of another one.

    However, IMO to get a great trail object, C3 would need two new object parameters: Graph param and color gradients.

  • Hey!

    I indeed used the drawing canvas to make the effect. There is a lot of trickery going on to achieve the effect. I wrote that trail for Rhythmy initially: rhythmygame.com

    I can probably try to find the C3P or the code within Rhythmy and share it/make a tutorial about it :)

    EDIT: found an old version of the trail I made (the one in the video actually) :

    drive.google.com/file/d/1gJkYq2HEh9qrTjmAkCQELI5engDpG6aO/view

    But I'm pretty sure I made a better one that was a bit more efficient, better looking and that didn't break as much for Rhythmy. If I find it, I'll make a tutorial.

  • Yeah I didn't mean open source as in you can use it, but open source as in it's there and you can read it. Tbh the fact that I was able to read the code helped me understand the engine a lot more and make weird tests with what I understood from it.

    But yeah, this meant that the door was open for addons entirely based on hacks, or on copies of vanilla addons that cause users to ask for support when they should seek the 3rd party dev.

    It really is a shame but it did bring a ton of really cool addons as long as you knew their use cases and their limits.

  • I've checked game dev comparison websites and such, and I can't find a comparable product to C3, one that ticks the three boxes that caused my concern when combined:

    • Is subscription based only
    • Is Web based only
    • Creates a file format that is designed to run in one application (yes its a zip file technically, no you cannot easily view or edit it by extracting it if C3 was closed, minus assets)

    Dropping in to give my two cents:

    Subscription means it can keep getting maintained for years to come as long as the company doesn't explode.

    Web based means that the tool is easier to develop. HTML and JS are by far the most productive languages. A lot of other languages are moving towards what web has had for years in terms of productivity.

    Web also means cross platform so it will work anywhere as long as you have V8 (or any future version for that matter) which is maintained by a company that is litterally stronger than half the countries on this earth.

    Web also means it will NEVER stop working because of an OS/Web engine update. The whole reason you can still look at 1980s websites on the wayback machine is because JS tries to never ever break anything.

    Zip is standard on every OS known to man. Any data that isn't asset is JSON which is also now standard on pretty much any modern language known to man. JSON is arguably the most efficient way to store data by being both efficient, and human readable. Also parsing JSON is B R A I N D E A D easy, ESPECIALLY in JS. In MOST languages it's a single line of code to go from JSON to usable variables in code.

    All of your points actually prove that C3 is way less likely to randomly stop working than C2.

    C2 can break from any windows OS. Heck it's already falling apart for no reason on windows 10. C2 is only compatible on Windows. C2 is pretty much impossible to maintain as a community member because it has proprietary code, and needs really technical skills to be able to decompile. And even if you do, you'll have to deal with whatever the code you get actually looks like. Ashley, with full access to the source code and who wrote it all finds it difficult to work with, I doubt anyone will be able to make any meaningful step towards maintaining C2 if it fails to work.

    And while capx are also zip files, most data is stored in XML, which is still very used but not as easy to use and widespread as JSON.

    C2 ticks all the boxes of "I will become abandonware in 4 years time", C3 doesn't. The only amazing thing C2 has that C3 hasn't is a completely open source, unminified runtime, and the best stab at maintaining C2 would be to completely rewrite an editor for it and use its runtime. Doesn't that ring a bell? Yeah it's C3.

  • Using worker will prevent name overlap with code on the window object, and will prevent people from accessing your code from the console, but you'll still have to be weary of name overlaps between your own functions (which is a lot more manageable indeed)

  • This is a copy from the answer I provided on the Discord server, in case it might help anybody else.

    If I understand your struggle correctly you just want to have access to runtime globally

    Just add it to the global scope

    Something like this in your code will do.

    runOnStartup(async runtime => { globalThis.g_runtime = runtime })
    

    Then from any function, using g_runtime or globalThis.g_runtime will return the runtime object

    If you do not want runtime to be globally accessible however, there are other ways which I explained here:

    construct.net/en/tutorials/js-writing-javascript-modules-2384

    In summary, you can do this:

    runOnStartup(async runtime =>
    {
     let localVar; //Defines a local variable that will still be accessible to your global functions
     runtime.globalVar; //Defines a global variable in the runtime object
     runtime.globalFunction = () => {} //Defines a global function in the runtime object
     globalThis.globalVar; //Defines a global variable in the real global scope
     globalThis.globalFunction = () => {} //Defines a global function in the real global scope
     function localFunction () {} //Defines a local function that will still be accessible by your global functions
    });
    

    I do recommend reading through the tutorial as I go through a few other methods on how to properly design JS modules that are both powerful, easy to write, have access to whatever you might need and are easy to contain to avoid overlap with other modules and prevent external people from accessing unneeded data

  • Thank you very much, I will take a look a soon as possible :)

  • What has confused you?

  • HI Animate sadly that addon is very hard to port. That's mainly due to the fact that there is no accessible API for drawing text on the layout in C3.

    Also the C3 text plugin covers a lot of the tag text features now, so it's better for everyone to use it instead.

    Since it has 2.5 support, I really recommend you move to C3, and replace it with the regular text addon to be able to switch to c3runtime and add your missing features back.

    Sorry, but I don't see this plugin getting ported to C3runtime soon :(

    And finally, this is one of the rex plugins that should not get ported to C3runtime because new users might try using it when it's much better if they stay away from it because it won't get any kind of support or updates, and vanilla alternatives do exist, but this is the least important reason.

  • Hi, BL4CKWAT3R

    Well, moveto is one of the plugins that eren ported, he has a full list of the downloads hosted on the root of his github repo, right there:

    github.com/erenertugrul/construct-plugins

    and the download for moveto is here:

    github.com/erenertugrul/construct-plugins/raw/master/ported_plugins/behaviors/rex_moveto/dist/rex_moveto.c3addon

    If you need other plugins, take a look at the rest of the list, since the list is community maintained, it might not be always up to date. So if you find it somewhere, please add it to the list:

    docs.google.com/spreadsheets/d/1oxbmtXqXcW64IAU_4noZchLMxVrPeA4jD_rqTw35H2w/edit

  • Hi, BL4CKWAT3R

    Download options for the file depend on the plugin. When you click the plugin's name and click on the version you want, it will either download the file directly, or take you to an addon exchange page, or to a github repo.

    In case you end up with an addon that only provides the github repo as a download option, you can take a look at the root of the repo if direct downloads are made available in the readme. If that is not the case, you can either download the entire repo, or dowload the files manually and recreate the C3 addon (which is usually just the folder in the repo zipped and renamed to use a .c3addon extension).

    What addon are you trying to download? Maybe I can help a bit more with that.

  • Well, if your email even remotely resembles that post, that's pretty normal you're not getting any answer. You need to have a project that is ready and serious before trying to contact them, and try to respect people and their time.

    Understand that matpow might not have time to read through every request he's getting and might be busy with something else at the moment.

    Anyway, please calm down.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Hello, C3 updates have been amazing lately, and lots of new features from the ideas website have been added and it's pretty amazing to see.

    However, there is one feature that was announced right when C3 was initially announced, and that nobody mentionned since, the Editor SDK:

    Especially since lots of new editors and editor tweaks have been made during the year, I suppose that you guys have some kind of framework in house that makes it easier to integrate new windows and items. I just wonder if that will be available to the public any time soon.

  • Ah.

    Yeah, ok. Only bug that remains is on Chrome for Mac then.

    EDIT: Firefox Mac has the same issues.

    Thanks for your help guys :)

  • Ok, in that case, it doesn't seem to work properly on Chrome for Mac. That's an issue as it doesn't solve the issue it was supposed to solve initially :/

    EDIT: Ok it works properly on Chrome and Firefox for Linux (Tested with PopOS) It works on Safari for Mac, but the font doesn't change back to the regular font used before the Emoji (and defaults to Times new roman) and loading Twemoji just seems to fail on Chrome for Mac.

    This is better than what I initially thought from my tests, I just happened to test with the worst possible tools. That bug with the font not reverting back seems to be a weird one though, you might wanna look into it