Je Fawk's Recent Forum Activity

  • Very awesome, C3 could surely use more dedicated devs and stand alone - straight to the point addons, that don't try to implement 1 million different things (like ProUI, which I used, and got burned as well)

  • Not looking forward to report a bug with Pin but to be closed since it's not recommended anymore.

  • Pin to image point. The hierarchy cannot achieve that.

    Imagine a sword pinned to the character's arm.

    Now the character performs a complex 20 frames animation, a whirlwind.

    The hierarchy, as far as I know, cannot be placed in relation to an image point, so this would have to be manual work, to check if that animation is playing, put the sword at the point, etc.

  • Could Scirra invest a bit of time to make sure the Offline mode works at all times? I've reported in the past a few bugs about this, I'd hate to be stuck on a 8h plane trip again with C3 not working.

    Tom Ashley

    Thank you.

  • Thank you for bringing this to my attention; your report is highly valuable.

    Given that I am currently engaged in a six-month project, which can extend indefinitely, I initially had reservations about taking on this task.

    I think I'll keep away from attempting this for the foreseeable future and just stick to the current good old fashion text-only tabs.

    It would be awesome if we could assign emojis or icons for the event sheet themselves in a way that would not interfere with their names Ashley

  • Keep track of the UIDS? Interesting... as in an array or a dictionary?

    Before the hierarchy I was adding all the attached "child" sprites of a main sprite as instance vars

    UID_Hand_Left

    UID_Hand_Right

    etc...

    Now i'm checking the hierarchy for children, which is more intense performance-wise but less hassle in order to code faster :/

  • The pick children could have a different behavior. I haven’t tried using that yet though. Anytime there’s events surrounding creating objects this sort of thing comes up one way or another. A bug report could be valid since there was more complexity added for the children feature.

    Most of the events I write work around when new objects can be picked. It is a rough aspect of the system. The picking system works great when all the objects already are created. It also works well when all you’re doing is modifying some object just created. Beyond that I tend to try a two pass method like create all the objects I need in one event then in a second event pick things again. The wait 0 can work but it makes it harder for me since I often require things to be done in a certain order.

    At one brief point the new objects were added to the object list once created. However that was changed to fix cases where infinite loops were being caused with some events. It’s an interesting design process to try to come up with a different way to handle the picking in a robust reliable way, but I know I haven’t come up with anything I’ve liked. Overall I’ve found the event system to be more complex and nuanced over time so I try to use a simple subset of it that I know the precise behavior of.

    Thank you very much for the detailed reply. Very interesting to hear your take on this. Sounds similar to coding nodejs apps actually, where newer js "eye candy" can cause performance issues.

    Regarding Construct, at some point I started creating my objects outside the layout, very far -10000, -10000. I added the Waits required, or used very short timers, and then once everything was initialized I moved them to the proper position.

    It was quite a hassle however to take care that everything finished initializing and there was a lot of back and forth checking and assigning "IsInitialized" variables.

    This was the most stable way for me for a while to do things.

  • Related to this bug I've reported, which is shows much simpler code: github.com/Scirra/Construct-bugs/issues/7184

  • As kindly answered:

    "I cannot reproduce it, works for me either way

    wait, no it's weird for me as well

    seems like pick children only works for newly created instances if that instance is specifically picked in that event

    so it doesn't seem to be part of the picked instance if you don't reference any instance of that object type

    for example this event works with copy picked or as a custom action as well without a wait 0"

  • The why has to do with when new objects are pickable. Basically new objects aren’t added to the list of objects till an event ends and the next event is a top level event. A top level event just means it’s not a sub event of another event, but it can be in a group. Search for “top level event” for other attempts to describe this behavior.

    Wait 0 will delay things being run till the end of the event sheet so the new objects will be added to the object list by then.

    Now pick by uid is a special case. If you created an object you can pick it at any point.

    Thank you for the detailed explanation.

    The top level event doesn't seem to apply here, unless I misunderstand it, in which case please correct me.

    I just use the same blocks:

    1. one in a function where I pass the UID beforehand by going through all the children of type Tattoo, and that works.

    2. one in a function where inside the function I go through all the children of type Tattoo, missing out on the UID, and that doesn't work.

    So when the UID is passed, somehow... it works, and the object is picked beforehand in the loop of that function call.

    Sorry if I don't understand still, it seems like code in one place works, but in another, it doesn't.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • EDIT: wait sorry, I may have misunderstood your original issue. I tend to use "wait 0" often and tends to behave correctly. I never risk a newly created object without using "wait 0", but perhaps there are specific times where this is OK. When is the 2nd function without a UID parameter called? If there's multiple of that one object, and no UID is specified, perhaps C3 is picking whatever first instance of that object that exists, then picking it's children and such.

    EDIT 2: oh wait, I just understood the colour-coded purple shows the 2nd function being called. From what I understand, if the 2nd function doesn't have "copy picked" or a UID to pass, then the 2nd function effectively "doesn't know" which instance to pick, so I guess unexpected behaviour happens. I'd always pass a UID just to be crystal clear for C3 to know which instance to pick (or copy picked if that works after a "wait 0").

    I always use "wait 0" on a "on created" event. Like every object that gets created, I have an "initialise" function or custom action for that object, but it seems that "wait 0" is always needed before calling the function.

    I think it's related to the whole "objects don't necessarily exist until the bottom of the event sheet/next tick" or something similar to this, so a "wait 0" solves this.

    Doesn't seem to cause issues as far as I am aware, even if multiple objects are created on the same tick and such. But yeah, hmm.

    Yes, sorry about the coloring, Photoshop tricked me to add the same color to the text in both places, making it a bit more confusing.

    Thank you for your reply. I run into this issue a lot, and I try to avoid using Wait 0 because it causes assets to flicker (eg.: i create the body, and then wait 0, and then the eyes—you will notice how the eyes get created slightly later; or if I need to replace something, again using Wait 0 will cause a flicker.)

    I think it's related to the whole "objects don't necessarily exist until the bottom of the event sheet/next tick" or something similar to this, so a "wait 0" solves this.

    Yes but you see, one function picks it in the same tick, the other doesn't.

  • If you are referring to sprite creation why have you blurred out the important events? When you create an instance yes you need to wait until next tick for it to be available.

    The blurred events aren't important. Wait 0 is not needed, as I explained in my post.

Je Fawk's avatar

Je Fawk

Early Adopter

Member since 7 Jul, 2014

Twitter
Je Fawk has 3 followers

Trophy Case

  • 10-Year Club
  • Entrepreneur Sold something in the asset store
  • Jupiter Mission Supports Gordon's mission to Jupiter
  • Forum Contributor Made 100 posts in the forums
  • Regular Visitor Visited Construct.net 7 days in a row
  • RTFM Read the fabulous manual
  • x3
    Quick Draw First 5 people to up-vote a new Construct 3 release
  • x6
    Great Comment One of your comments gets 3 upvotes
  • Delicious Comment One of your comments gets 10 upvotes
  • Email Verified

Progress

19/44
How to earn trophies