nettemple's Recent Forum Activity

  • Works great! Now to push it further.... How can I pull out a random entry from the array or dictionary...

    Logic like so based on your comments:

    Works as static: arrayNames.At(2)

    Desire this though:

    arrayNames.At(+int(random(0,4))+)

    //// So the desired result might be:

    arrayNames.At(1)

    or

    arrayNames.At(4)

    or

    arrayNames.At(0)

  • I have two layout:

    1_ Splash screen

    2_ Select Character

    3_ Game

    When Construct loads in Remote Preview mode (on iPhone), It shows 1 propoerly then after 2 seconds goes to 2 properly, but when I hit PLAY button (in layout 2), it recycles back to the 1 and then 2, but wont go to 3.

    Note: It only does this when previewing remotely on Phone - playing and testing in browser works fine - no issues.

    The only thing I can think of is I have a GLOBAL event sheet that I "include" in layout 3. This means I have a ON START OF LAYOUT in both event sheets - "global events" and "game events"...

    It is hit and miss. I restarted browser, flushed cache, and then it worked fine via remote. Then the issue started again. I repeated restart and flush, but this time the issue persisted.

    It's basically flakey?

    Any thoughts?

  • I have a dictionary that stores messages

    0: Hello 1

    1: Hello 2

    2: Hello 3

    I want to set text "message" when an event happens...

    Basic logic is "messages.setText --> dictionaryName.2" (I realize that is totally abstract, but that is the logic I am after)

    Also how would this work from an array:

    Basic logic is "messages.setText --> ArrayAt(2)"

    I just need the proper syntax. Cheers!

  • You do not have permission to view this post

  • Note: In the description below, Obj A is the static object at the bottom of the screen and obj B are objects falling from the top of the screen in a space-invader like style.

    OK - a creative solution - When the collision (between Objs B and Obj A) would happen, I switched the animation (in B) to from "alive" to "die" but sometimes I would get two and three registered "hits" which made my score go up inaccurately (one point per hit). So some hits would register 2 or 3 therefore giving me multiple points - which was not my intention. One collision = 1 hit = 1 point. I was disabling collision on hit and this still did not work (as well as Trigger Once While True) so we out smarted it old-school style based on the comments and creative thinking in the above suggestions(?)

    SOLUTION: When the collision happens, the animation shifts to "die" and in the die animation, I made the collision area 2x2 pixels and tucked it in the bottom right hand corner, thus preventing a second collision from happening. I moved the collision area on Obj A "alive" up slightly so that when a collision happened the "die" collision was already below the Obj A thus making it impossible to hit a second time. I have tested this with dozens of falling Obj Bs and it is spot on accurate. (and no complicated code was required).

    Thanks for the assistance Lesley and Dr Hasan.

  • You were correct - I had to add a "trigger-once while true". Because it was placing particle object repeatedly. It wasn't under an "every-tick" but still repeating because it was being fired by a compare two values (showParticles = true) therefore was continually repeating. A common newbie error. Thank you for your assistance.

  • I tried that but the instance sprays continuously (I used "create object" in the event sheet)? Even though the particle in the frame on start is set to one-shot? There does not appear to be a "restart Particle" (similar to restart fade... Also I saw online that it destroys the one-shot particle on completion. Other suggestions?

  • How do I restart a one-shot particle in the event sheet? I have a particle fire once after load. But I want to trigger it again on an event. Any suggestions?

  • Creative solutions! I will try and report back.

  • I saw a video on TY where the presenter (posted recently) referred to this issue and stated In-App Purchases do not work with iOS and Construct "3". He advised that you export as Construct 2 then everything will go smooth. Not sure if this is still the case, (YT video was very recently posted BTW), but I am dependent on some of the features of C3... Can anyone tell me if this (C3, iOS and inAppPurchases) has been resolved and is working smoothly? Thank you in advance.

  • I cant disable the player collision because they are being "attacked" by multiple enemies - so I want the collision to be active in case they collide with a second enemy "while" the first collision enemy animation is playing. So for example - player collides with enemy 1, the enemy 1 death animation plays, then when animation finished, score is increased by 1. While that animation 1 was playing the played collided with a second enemy. So the second enemy death animation starts (before completion of the first enemy animation)... The real problem I am having actually deals the the SCORE... As the player collides with the enemy AND while the death animation is playing, the score rings up multiple hits (I have it coded as "Score = Score + 1". So instead of adding 1, it may add 2 or 3 to the score sometimes... (BTW, I already tried the TRIGGER ONCE WHILE TRUE and it doesn't fix the issue)

  • How do I: (a) on collision, (b) change animation of object, and then (c) wait until that animation (15 frames) fishes before continuing?

    I have (a) and (b) but am looking for the solution to (c)... I have tried a "wait 0.5 seconds" and this works but it is klunky. :-) Is there a better way: "wait to end of animation", "play after frame 15", etc?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
nettemple's avatar

nettemple

Member since 8 May, 2018

Twitter
nettemple has 3 followers

Connect with nettemple