NEONN64's Recent Forum Activity

  • +1 It's really annoying to not be able to do this yet, especially when working with layer, layout, overlay, and distortion effects.

    Yep, working with distortion effects is a pain <img src="smileys/smiley19.gif" border="0" align="middle" />

  • When you turn on Enable WebGL to use effects, the effects are also applied to the layout editor on Construct.

    If you have distortion effects, the simple action of clicking on anything becomes a very difficult task.

    If you have the brightness effect set at 0 (I do, in order to have a fade in), your layout will be only a black rectangle.

    Basically, some effects make the layout editor unusable. Because of this, you have to turn the Enable WebGL feature off to edit layout and turn it on to test and export. This is very inconvenient, sometimes yo export your project only to discover that WebGL was off, so you have to turn it back on and then export again.

    It would be very useful to have an option to turn effects off from the editor.

    Thanks.

    Note: If such option already exists, please let me know where is it, I've been looking for it.

  • I support this suggestion. It would be really useful.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Thank you very much for the answers   <img src="smileys/smiley1.gif" border="0" align="middle" />

    I moved the "every X seconds" to a sub event and tested it. The results were the same, usually it worked well, but every now and then it would activate a charged attack instead of a regular attack.

    Then, I used a timer, that did the trick.

    This was the resulting code:

    <img src="http://imageshack.us/a/img541/4773/a3qu.jpg" border="0" />

    Once again, thank you ^_^

  • Hi, I've been using Construct for a while, but this is my first time posting on the forums. I guess you'll be seeing more of me in the future as I'll surely get stuck again at some point, but I hope to eventually get good enough to help others.

    <font size="5">Ok, this is the situation:</font>

    I've been working on a game, I have a character (the player) always carrying a melee weapon (separate sprites) pointing upwards (0 degrees).

    When pressing "c" on the keyboard the weapon is tilted back -30 degrees and then it rotates 210 degrees (180 + the 30 it tilted in the begin).

    If the c key is hold for a certain amount of time and then released, the weapon will rotate 390 degrees (360 + the 30 it tilted in the begin)and will be a little faster. Something similar to the "spin attack" in Zelda games.

    The longer you hold c the stronger the attack will be, there are 3 levels of charge (these levels are not relevant for the current problem).

    <font size="5">To do all this, the player's sprite has 2 variables:</font>

    1) charge_lvl:It goes from 0 to 3, the default value is 0 representing a regular 210 degrees attack, from 1 to 3 is a charged 390 degree attack. For the issue at hand there is no difference between 1 to 3 values, it only matters if it is 0 or greater than 0.

    2) lock: It goes from 0 to 1. Default is 0. When the attack "animation" starts I set it to 1, when it ends I set it back to 0. An attack can be performed only when the value is 0, this is to prevent the player to interrupt the attack's animation by pressing c repeatedly.

    I do the attack's "animation" by rotating the weapon 30 degrees, waiting a fraction of a second(0.03 or 0.02), rotating another 30 degrees and so on until the 210 or 390 degrees are completed. At the end of each attack there is a little extra waiting time (0.5 seconds).

    <font size="5">There are 3 events:</font>

    1) c is pressed: This tilts the weapon -30 degrees.

    2) c is down: every X seconds the value of charge_lvl is increased.

    2) c is released: this is divided in 2 sub events: When charge_lvl is 0 and when it is greater than 0. In both cases the attack's "animation" is activated, the only difference is that when charge_lvl is greater than 0 it has additional rotation steps in order to complete the total 390 degree rotation, also, each step in the "animation" is faster (the waits are shorter).

    Ok, that is the way I'm working, now, the actual problem:

    Sometimes when pressing c without holding it does the charged attack(390 degrees) instead of the regular attack (210 degrees). This happens occasionally, try it a few times to see.

    I don't really know where is my error, but I have the feeling it has something to do with the "wait X seconds" condition.

    In my actual game there are enemies, sound effects, visual effects etc, to make sure none of these things had anything to do with my problem I recreated the basics elements associated with the problem into another very basic project. The results were the same so I guess there is a problem with my logic or my understanding of some event.

    (Also, I've tried with Firefox, Chrome and IE, same results)

    So, I'm asking for help to find out a solution to the problem.

    The .capx can be downloaded here:

    mediafire.com/download/67fmqlm7lpmzyj8/temp1.capx

    And these are some images of the project.

    <img src="http://imageshack.us/a/img201/82/o1ed.jpg" border="0" />

    <img src="http://imageshack.us/a/img24/2273/ipjb.jpg" border="0" />

    <img src="http://imageshack.us/a/img833/2126/5lkx.jpg" border="0" />

    Notes:

    * The number on screen is the current value of the charge_lvl variable I added it for debugging purposes.

    * The wait every X seconds sentence is set to high value (9 seconds) in order to make sure that said amount of time is NOT passing end therefore it shouldn't be activating the charged attack.

    Thanks in advance ^_^

NEONN64's avatar

NEONN64

Member since 10 Nov, 2012

None one is following NEONN64 yet!

Trophy Case

  • 12-Year Club
  • Email Verified

Progress

13/44
How to earn trophies