otomecha's Recent Forum Activity

  • Hello!

    I have some "repeat" loops and I'm having trouble because I feel they are not going sequentianly. For example the last condition doesn't work inside the 'on start layout' but it does work if I take it out (which I don't want). I feel I'm arranging it wrong :/

    code

    ibb.co/rQg3kpk

    Intended Result

    ibb.co/hX3MwZ8

    *Image attaching was not working for me today, so I just added links

    Any idea on how to arrange it better or wait for the loop to complete?

  • Where do you get the value from JSON and set the scale to the body? Is it in "On Start of layout" event? Then change the scale of baby arms/legs in the same event.

    You are either doing this before the hierarchy is created, or on every tick, it's not clear from your screenshots. There is no point in updating the scale on every tick.

    Also, like I said, use "Pick children" instead of picking by Member variable. It's possible that the variable is not yet set or set incorrectly, that's why it's not working.

    Try "Body pick children" and if this doesn't work, please post a screenshot of the event sheet showing all relevant events.

    I made it work with pick children! :3 Thank you for your help!!! you rock!

  • Looks like you are not using hierarchies properly. You can set "transform width/height" for all children in a hierarchy. Then when you change the scale of the parent object, all children will be scaled automatically with it.

    You also don't need to link parts of the hierarchy with instance variables. If collider_char is the parent object, to pick its head you simply use "collider_char Pick Children Head" condition.

    You can create a family called Limbs for all arms/legs sprites. Then the code may look like this:

    > if Body Scale=0.5
    Body pick children Limbs : Limbs set scale to 0.7
    
    

    Thank you for replying!

    Looks like you are not using hierarchies properly. You can set "transform width/height" for all children in a hierarchy. Then when you change the scale of the parent object, all children will be scaled automatically with it.

    I'm not sure I get this! I do have "transform width/height" ticked and they are scaling correctly. I scale the body and then everything scales acordingly. It's only that when I have the "baby size" (0.5), I don't want the head and the arms to scale to 0.5 but 0.7.to give the chibi look.

    I want to do this only for baby characters in the loading stage. But when I try to add at the end of 'on start layout' it does nothing. If I add it a single trigger it does affect all the bodies, regardless thir escale.

    I could only make it work when 'on drag', but i need it to happen before you interact with the character.

  • Hello!

    I have some characters based on a template. When I start the layout I load the config from the Json and call a function that changes the sprites to the frame, size and color I want.

    I have 3 sizes: Adult, Kid and baby. For the baby, additionaly to the sizing I wanted to modify the scale of the arms and head.

    this is the intended result.

    The problem I found is that when I try to load it by the condition for the body scale (since the condition doesn't exist I stored it as a var) It affects all the bodies, not just the "baby". I only could make it work by a trigger like 'on drag' or "on drop" but not in the normal loading where it should be :/

    Any ideas on how to trigger this?

  • I did some tests and I also ran into a thousand problems, I thought it was simpler to manage the timeline, I hope some expert user can explain to us if it's possible to change states without it going haywire.

    In any case you can obtain these angular movements for sure and very easily with the sine

    Yeah the thing is that I will have severala animations: idle, dragging, sitting, dancing, etc. So I would prefer them to all of them be tweens or all of them be timelines in a closed system :/ Thank you for for your help anyways! I appreciate it.

  • In my opinion you should change the conditions to start the timelines, perhaps using variables

    Well... that's another thing, this setup is placeholder. I actually couldn't get the timelines to play only in the replicas that are dragging for example, they play in all of them... I tried to pick them in different ways, tried with a state machine, etc. Nothing worked :/

    As for the angles, any idea of what it is happening? :/ is there an angle restriction?

  • Hello!

    I created this animation with the arms up.

    However when I play it the angles act funny, as you see instead of being up, they are closed behind.

    I have another animation that works just fine. In the photo I was not playing any other animation, so I don't have any weird value overlapping, and the setting in this one and the idle that works correctly are the same... default, default, loop. Also I tried with relative but looks the same...

    Added a video

    Subscribe to Construct videos now
  • Yeah sure, you can send it to diegoszs@scirra.com

    Mail sent ^^ Thank you!

  • Can you share your example project?

    Maybe there are some performance improvements that can be done on Construct's side.

    Yes! Is it okay if I share it privately by DM?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • > Thank you for those insights! My games are exclusive to android devices, is it still work to switch to 60hz and observe performance?

    You should definitely try your game with different monitor refresh rates, I do this regularly to make sure I didn't forget to use delta-time or something like that.

    But the performance on mobile is vastly different. The game that works perfectly on PC may lag pretty bad even on a high-spec mobile phone. So I suggest you test it on different mobiles.

    I'll try! Thank you very much! I have another game shipped and it works more or less okay!

  • You do not have permission to view this post

  • One thing I'd note, is, you have a 240hz monitor, and get around 70% gpu usage. Can assume if you divide by 4, that would be a more common result (so around 17% gpu usage for 60hz monitors).

    Maybe performance is fine but is struggling to render so quickly!

    To lower gpu usage overall, be mindful of any effects you use. You could also make a "quality" system by using System>Set Canvas Size, where you'd get a blurred result but allows people with weak GPU's or high refresh rates to be able to get a more stable FPS.

    Your cpu seems pretty good for 240hz.

    I'd recommend switching your refresh rate to 60hz to observe performance, so you have good idea of what most people would experience.

    Thank you for those insights! My games are exclusive to android devices, is it still work to switch to 60hz and observe performance?

otomecha's avatar

otomecha

Member since 26 Mar, 2015

None one is following otomecha yet!

Trophy Case

  • 9-Year Club
  • Forum Contributor Made 100 posts in the forums
  • Regular Visitor Visited Construct.net 7 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

13/44
How to earn trophies