SullyTheStrange's Recent Forum Activity

  • (Hopefully I get this one right >.>)

    With the "currentWeapon" sprite, you can have multiple frames, each one being a sprite of a different weapon, and set the animation speed to 0 so it'll never actually change frame on its own. Then you manually tell it which frame to go to based on the value of 'weapon', so if 1 means shotgun and the second frame of "currentWeapon" is the shotgun sprite, say this:

    + player: Value 'weapon' Equal to 1

    -> currentWeapon: Set animation frame to 2

    and so on and so forth.

  • Generate a random number from 0 to 10 and then add 10 to the result, effectively changing the range from 10 to 20. It works for that simple example, at least.

  • Yeahhh, numbers work too. I got myself into the habit of using text now that there's way too much stuff to remember by number, so that didn't even occur to me. My bad!

  • Yeah, that can be a problem sometimes. The easiest thing to do that I can think of is to make another variable called "Change" or something and add it in like this:

    + input: On player 1 pressed "Change Weapon"

    + System: Trigger once

    + System: player ('weapon') Equal to "bullet"

    + player ('change') Equal to "0"

    -> player: Set 'weapon' to "shotgun"

    -> Set 'change' to 1

    + System: player ('weapon') Equal to "shotgun"

    + player ('change') Equal to "0"

    -> player: Set 'weapon' to "missile"

    -> Set 'change' to 1

    + System: player ('weapon') Equal to "missile"

    + player ('change') Equal to "0"

    -> player: Set 'weapon' to "bullet"

    -> Set 'change' to 1

    And then set it back to zero. That limits it so that it can only pass through one of the conditions rather than all three.

  • You should use what they call a "state machine", which can be set up something like this:

    Weapon (player's private variable, default) = "Bullet"

    Pressed key D

    Trigger once

    • If Weapon = "Bullet"

    -> Set Weapon = "Shotgun"

    • If Weapon = "Shotgun"

    -> Set Weapon = "Bullet"

    Pressed key C

    • If Weapon = "Bullet"

    -> Shoot default gun

    • If Weapon = "Shotgun"

    -> Shoot shotgun

    Might take a bit of tweaking to get it to do what you want, but something like that should work fine.

  • Animations act a bit strange sometimes. You definitely don't ALWAYS need a Play Animation action, unless you're always pausing it or something, but sometimes it seems to be necessary. Not sure what's up with that.

  • For just starting a few days ago, you're doing very well so far. Looks like you've got a grasp on all the basics. I only started a few months ago myself, so I know how confusing things can be once you start getting more advanced -- don't be afraid to ask for help, there's a great community here.

    So, welcome to Construct, and good luck on your future work.

  • I just noticed that all this time, I've been completely ignoring the former in favor of the latter. I guess it's easier for me to differentiate between "Equal to" and inverted "Equal to" at a glance because of the red symbol, when I'd otherwise have to look closely for the "Not".

    So I randomly got curious -- which one do you guys tend to use?

  • Ahah, works beautifully. Thanks.

  • I know this has had topics in the past, but the last useful one was from 2008 and, well, I'm hoping things have changed since then.

    You're probably familiar with the issue, but just in case, it's when you're standing on a platform moving vertically and the player is constantly jittering instead of being attached to the top of the platform. I'd like to stop that. Has any concrete fix been found for it yet?

  • I'm interested in this fix too, and I have no idea what the "svn" is or where it can be found on source forge. Can someone point me in the right direction?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I love the mountain of indie platformers, personally -- I mean, it's the only way the genre gets any love nowadays outside of new Mario games, more or less. But hey, I'm a platformer junkie.

SullyTheStrange's avatar

SullyTheStrange

Member since 26 Jan, 2011

None one is following SullyTheStrange yet!

Trophy Case

  • 13-Year Club
  • Email Verified

Progress

14/44
How to earn trophies