Rikushi's Recent Forum Activity

  • This method dont alow to loop animation that must be looped. Like walk.

    But combining your and my method together is a solution for my issue. Many thanks.

  • "For each" loops are quite slow. If you are planning to have 17 animations, with this approach you'll need at least 19 loops, which may cause performance issues. So I suggest to do everything in one loop (see the screenshot in my previous comment)

    Already did thanks.

    But now i'm have another issue with "Trigger once" condition.

    When i'm clicking on unit i'm setting up currentAnimation to "Clicked".

    Next, when setting art animation

    base curAnim = Clicked -> art set animation to Clicked Trigger once

    It work only for first clicked instace of object. The others repeat they animation. How do i can fix it?

    Example: h*t*t*p*s://drive.google.com/file/d/1AIIYMTTczNN2GW5z6HaDPUCPPlCV3hke/view?usp=sharing

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Generally, when you pick multiple instances by UID, you need to use "For Each".

    Yeah, thanks. I'm already deal with that problem. I'm just tryed everything, and this one accidentally work perfect.

    drive.google.com/file/d/1eHDa-76T-BGPuREzOcwLVrIZ2xJEM1pI/view?usp=sharing

    Also, if you only have a few enemy types, it may be easier to combine them into two sprites.

    I'm may what i'm may. But what i'm need i'm described in a topic. There only example so simple, real project not so. 15 different units with 17 animations each. But thanks anyway.

  • Greetings.

    I'm trying to make an enemies units, using a two family for that.

    Enemy unit made of two objects:

    Base (sprite) - using for all interaction with other game bases.

    Art (sprite) - using for visualisation of current enemy activity.

    I have a two family, Base for all bases sprites and Art for all art sprites.

    Also i'm using a containers for each type of unit and put into that containers base and art sprites.

    So container 1 contain (base1 and art1).

    Container 2 (base2, art2).

    Container 3 (base3, art3).

    Art have a variable "baseUID".

    When art sprites created i'm put into that variable value of base.UID. So i'm can anytime compare value of base.UID and art.baseUID for choosing correct base and art of unit.

    Bases have a variable "currentAnimation". I'm seting this variable when i need to play a certain animation.

    Then i'm set animations for "Art" based on base.currentAnim value.

    And here i have a problem with correctly chsoosing of "art" sprites.

    This is an example: drive.google.com/file/d/1QhrTKNo-1PSF3KfJ9YDlk0dw3sBmZI2K/view

    As you can see (in debug mode of cource) the variable "currentAnimation" get correct value.

    But animation of art is incorrect.

    Help me please to understand what i'm doing wrong.

    Hope my engrish is understandable and i'm discribed my problem well.

Rikushi's avatar

Rikushi

Member since 12 Jul, 2018

None one is following Rikushi yet!

Trophy Case

  • 6-Year Club
  • Email Verified

Progress

7/44
How to earn trophies