Qualifiers?

0 favourites
  • 8 posts
  • I remember in MMF2 there was a way of setting a qualifier to various objects. This would be useful if you wanted to do specific things with certain items, but not others.

    For example, if you have various weapon types, and various weapons for that type, you could say "Qualifier Knife" or "Qualifier Unarmed" "Qualifier Sword" etc.

    This way, the knife changes depending on what you have, but since the character animations are all the same for each knife you get (the knives can be various looks and colors), it would be easier to say "qualifier knife equipped" then "set animation of qualifier knife to animation of char".

    I hope this was explained easily enough, and I appreciate any thoughts on this topic. If I've missed this somewhere, please tell me!

    Thanks!

    Rory

  • You can go with instance variables (IV) and the animations feature of the sprite object.

    Make an IV "Type" (text) and one "State" (text).

    Then be sure to name your different animations according to Type_State (ex: knife_drawn; deserteagle_reload; etc...)

    Then in your conditions you can check for the values of the IV you want.

    And to set the animation :

    Sprite_Set animation to: Sprite.Type & "_" & Sprite.State

    This is basicly the same logic you described.

  • Yeah I was poking around with what I was already doing and noticed that as a valid option (and possibly the best, but I second guess myself). Thank you for your input, makes this decision easier. <img src="smileys/smiley1.gif" border="0" align="middle" />

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I'm also an old mmf2 user and qualifiers are just a badly implemented version of what we call families in construct (I heard they will improve it for mmf3...).

    You already have them in construct classic, but it's not there yet for construct 2. Ashley is well aware of our expectations about families and I heard he is or will be working on it soon (:

  • That's very good to know. I'll design my game around the concept because it seems very nice in many cases that aren't what I was asking about here, and I know they'll come in handy.

  • well, be carefull, nobody know how much time it will take to have this feature. It's really not easty to implement (when I think about it).

  • Well I'm sure there are other ways of doing it. I usually wake up from my sleep hours earlier because my subconscious tells me how to do things. (or god or whatever you wanna call it). Luckily I know a few ways that will work just fine with what I had in mind.

    I'll just make a magenta colored version of a knife, blade, longsword, gun etc, then go to the sprites and draw the animations while making it "always set to image point X" and "always set animation to Player.AnimatinonName" along with "always set frame to Player.AnimationFrame"

    I'm going to have to make a new item for each one being used, but luckily I'm doing a Castlevania style game play, so shield and sword will only be used in combat (and when idle if it's the last weapon you used).

    And since I'm on the topic, is there any way of open sourcing this when I'm done so everyone can have a nice starting point to work with? I want to share this with others for rapid platform game development, but I don't know if my programming skills are good enough to ensure the fastest development experience. It's just a platform engine a la Castlevania (as I said) and not every animation is used, but can be implemented.

    For example, I have many event sheets (five so far) for all his actions and animations, that way to keep organized without going crazy, but should I eventually put them all in one sheet and put them in groups to save on any headaches?

    Sorry to sway so off topic there.

  • For open sourcing, simply share the final capx.

    Users will then implement/use it as they like.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)