Arima's Recent Forum Activity

  • When you click the mouse, the condition 'if mouse has been clicked' remains true for the whole event sheet until the next tick, not just for the first event that uses it. The simplest ways to fix it are to either order those events backwards or set a variable mouse clicked to 1 and check the variable in each event, like:

    1: On clicked Button:

    variable 'mouseclicked' = 0

    a.Write Text

    b. Button.Set"ChoiceA" to 0

    c. set variable 'mouseclicked' to 1

    2. On clicked Button:

    variable 'mouseclicked' = 0

    Value "ChoiceA" equal to 0

    a.Write second Text

    b.Button.Set"ChoiceA" to 1

    c. set variable 'mouseclicked' to 1

    3. On clicked Button:

    variable 'mouseclicked' = 0

    Value"ChoiceA" equal to 1

    a.Write third Text

    b. set variable 'mouseclicked' to 1

    Then set the mouse clicked variable to 0 at the end of the event sheet.

  • Totally awesome! Thanks, man!

  • I've wanted an effect that does what you describe for ages.

    Think you can make it happen, Davioware?

  • This topic was posted on Jan 21, 2008. Please check the dates of threads before responding to them.

  • another weird thing that i have just discovered is weird effect of "every X milisec's" contidion.

    for value regeneration i use plain "Each X miliseconds" conditions and offten my values are like 1.20 0.80 3.33 ect. my problem is on example of Shields Regeneration. it starts with

    0 value with 1.20 regen rate and goes all the way to 38 and then BLAM 40.7999999999999, and becomes even more and more messed up with each second. now how 1.2 value multiplyd by any round number can become 40.7999999999999??? O.o

    That's because of rounding errors - floating point numbers like 1.2 can't be counted on to be calculated exactly. It's a limitation of processors. If you want exact numbers, stick to integers (whole numbers without decimals like 1).

  • Chrisbrobs made one here:

  • Yep. Put everything you want to sort in a family, then use the system condition for each object ordered, select the family and input family.y, or give the family a variable via the family manager and use that instead, then add the action send to front.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Yep. No need for fear, tho - copy and paste the code, toggle the copied event off (in the ribbon under events) and you can mess with the code without worrying about messing up what you had.

  • Because of this part:

    and also change size depending on player/enemy health which I have no clue on how to do.

    This way it will automatically adjust its x position for the length of the bar.

  • The first image is almost correct. The reason it didn't work is because of the action in the first event. You have it so the variable is set to 1. Instead, set it to:

    Set global variable 'BattleEjectorsWeapons' to 1-global('BattleEjectorsWeapons')

    Get the logic? Because the way you had it, the variable was always set to 1.

  • That's a common issue - events are run in order, so immediately after it toggles the variable, the next event toggles it right back. Instead, use:

    • if key F1 pressed, set variable to 1-variable (set the variable to 1-itself)
    • - if variable = 0, set position to .x+150
    • - if variable = 1, set position to .x-150
  • Thanks guy's, both of you, however I wonder what the / actually is supposed to do?

    You mean the one in my post? It's division.

Arima's avatar

Arima

Member since 11 Jun, 2007

None one is following Arima yet!

Connect with Arima

Trophy Case

  • Coach One of your tutorials has over 1,000 readers
  • Educator One of your tutorials has over 10,000 readers
  • Email Verified

Progress

19/44
How to earn trophies