TheRealDannyyy's Forum Posts

  • "chipmunk physics" behavior?

    It's a fancy name for a more advanced physics behavior inside C2. (HERE)

    HERE is an old topic of mine about that, it includes a basic unfinished but working example of my method.

    So, I'd like to ask again if you guys would consider adding a feature like that or should I keep on going with my currently old Spriter importing + ragdolling methods?

    It just feels like we've talked more about a workaround than my actual request, which isn't wrong of course.

  • TheRealDannyyy is there anyway you can use the Override Object Animation action to tell each sprite where to be while in ragdoll mode?

    I guess it would be possible with the use of heavy maths and a lot of events which could easily bloat the memory use.

    Sorry, I get the use of the action in general but I think that would be a little too advanced for me to handle compared to my current method.

    My current way is to create a family with all sprite parts and give them the "chipmunk physics" behavior which has a more advanced pivot joint feature.

    Could you perhaps create a small example so that I could get a better understanding?

    I'd appreciate the effort and thanks for the quick response.

  • Introduction:

    This is going to be a large post but first I'd like to start off with saying hello to the Brashmonkey team and hello to everyone that is providing support towards fixing bugs and many more things.

    My Case:

    I'm currently working on a fairly large game and as a proud owner of Spriter Pro I can only say, thank you so much for making my and my artists life easier.

    I recently decided to try out the new spritesheet feature because I'm getting closer and closer to the sprite limit.

    So far my tests have all been successful and I was surprised that even char maps worked using the new method.

    My Problem:

    My game is using custom ragdolls (physics joints that connect the single sprites with each other making them "wobbly"), this feature was working fine with the old method and as you might already be able to guess, spritesheeting unfortunately breaks this feature of mine.

    The Request:

    I know this probably sounds easy from my perspective but I would like to request a custom ragdoll feature that you could perhaps turn on/off at will. I understand that this won't be as easy to implement as I think but I'm sure that if you'd implement this feature, you wouldn't only make me happy but also a lot of other Spriter + C2 users here.

    Some Last Words:

    Adding this feature in combination with spritesheeting would be a blessing and honestly it would calm down my fear of reaching the sprite limit for sure.

    If you guys need someone to test it out (if it's possible), I'm willing to invest my time into it and surely all the other helpful people here will do it as well.

    Thanks again for this amazing product and looking forward to hear from you guys.

  • TheRealDannyyy

    No worries, you actually helped me fix the issue, what's left is a minor thing, the main problem is gone! Thanks!

    No probs we're all on the same messy but useful, web-based boat.

    May I plug you our Official C2 Discord Server,

    with a fairly large amount of active users and quick help with any kind of C2 related problems.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • The code is just like the one i found, works fine for "body". So i can assign form ID to whole button family? Because i can't find the form proprieties of the button family in the editor

    Yep not like I though it would be, damn C2 family system thought it would make this a little easier.

    Anyway for now I have nothing else to offer, I might come back later so either wait or let the annoying, repetitive work begin.

    To be honest, it's kinda weird that NWjs is showing that thing on your end.

    When I middle click (not inside forms) there is nothing appearing, might want to disable "unbounded scrolling" in the layout properties.

    Unless you plan to create some sort of website using C2, then you should leave it on.

  • Now, the only issue is not really a big deal, i just need to know if there is a "global" form/ID for button objects as well (like "body" for other objects", so i dont need to assign a formID to all the 100+ buttons in my projects

    Armaldio gave me this code, try this one out please:

    "$(function(){$(document.body).mousedown(function(e){if(e.button==1)return false});});"[/code:2ubgxa1g]
    [b][u]
    EDIT:[/u][/b] In the worst case you could create families for the form elements and assign them an ID.
  • The new code works fine for MMB, i just need to assign a form ID to buttons as well (unless there is another "body" for them too)

    Could you precisely explain your problem based on "what you want to achieve" and "what the problems are", sorry but I'm a little confused right now.

  • This one works as intended, it disables the scroll icon, but retains the ability to interact with MMB

    document.body.onmousedown = function(e) { if (e.button === 1) return false; }

    He's on it, might take a little while seems to be busy at the moment.

    By the way, what about the previous one with the rightclick context menu, do right click actions work as intended?

  • ...

    EDIT: nevermind, apparently, the code disabled every use of middle mouse, i would need a way to only prevent the scroll thing to appear, not disabling MMB as a whole

    I'm not an expert but doing that in JS sounds like a pain in the a**, I can give to over to Armaldio again but I promise you nothing.

  • Yes it's something about scrolling! But the new code still doesn't work (does "body" represents all the objects?).

    It should include everything exept form elements and how you block it for form elements is already mentioned above.

    EDIT: You only use NWjs for this right, like I've already stated the results of these scripts may vary on other browsers?

  • That's only for the button objects, the problem occurs when middle clicking on everything, even on the background

    So you kinda have scrollable game I guess, well try the code from below just execute it in the way you already know.

    "$(function(){$('body').mousedown(function(e){if(e.button==1)return false});});"[/code:5jm700ve]
  • Glad to see there is a way to prevent it! However, I'm stuck here:

    I didn't even know there is a way to assign an ID to whole categories of objects, how can i do it?

    In the object propeties of the form object that you want to use.

  • Did someone who currently has to deal with these issues, test out if it's still occurring in the recent versions of C2 (r239) and NWjs (v0.18.1)?

  • Thank you! I tried to take a screenshot but as i press any button the icon disappears. It's problematic not for the icon itself, but the fact it makes it difficult to properly use the middle mouse button.

    Yeah you would have to use an auto-screenshot program with a delay to screenshot that, whoops .

    Anyway, thanks to the JS magician Armaldio I've got this for you:

    1. Add the "browser" plugin to your project

    2. Add an event "on start of layout" (you might have to use it on a globally included eventsheet)

    3. Add the browser action "execute Javascript" and use the code from below

    4. Set an ID for the form element(s) where you want to prevent middle clicking

    5. Replace the ID inside the script with the ID you want to use (I've already set "test" as the ID in the script below, just replace the word after the "#" to whatever you like.)

    6. Middle clicking is now no longer an option, you rule over the middle click function now!

    "$(function(){$('#test').mousedown(function(e){if(e.button==1)return false});});"[/code:2ds8i2fa]
    
    [i]By the way, I think that it should be possible to implement features like this into the plugins themselves.
    If someone thinks about doing a "form +" plugin with additional features, feel free to add the stuff from above.[/i]
  • There is a similiar thing happening when middle-mouse clicking: it appears a scrolling icon and the some key actions are prevented unless i remove it. Is there a way to disable it too?

    Could you provide more details please, maybe screenshots?

    Also please note that I only tested this using NWjs, the result of this script may vary using other browsers.

    EDIT: Never mind I know what you mean now, I thought there were problems with the script.

    To be honest I have no clue how to prevent that icon from appearing, there might be a way to block the button itself.

    I'll ask this question to some experienced JS devs, they might find an easy solution for you soon.