Animation stuck and not working

hi i dont know what wrong with this, the dark knight in angle of leftside is not stand, even i set it must stand, and the dark knight of the rightside i stuck at frame 1(i make it loop)


c

General rule
You cannot let something happen and expect it happens only when you want it to happen
You also need to restrict it from NOT happening when you don’t want it to happen

Most basic example is if you make events like

Enemy is moving
Change animation to run

Enemy is jumping
Change animation to jump

Now what if enemy is jumping while moving?

Now you see the problem?
I already see conflicts in your events

Look here

What if dark knight is moving while its 80 pixels below in distance to some object from enemy group?
To which animation he should change?
You know to which you want him to change but how game should know if you allow 2 animation to be played at a same time
And so you get animation stuck on 1st frame

You need to restrict your animations from not being able to playing while other animations play

For example you could check if distance is above 80 pixels
Or check if animation is not run

You need to find balance yourself
Best to do it is by adding ONE animation change at a time and check does it work correctly with other animations
You can also toggle disable events with D or J or right click and choose toggle disable to check which animation is conflicting with another animation and try to restrict one or another

i get your mean, but when it reach 80 pixel it will stop all force= not moving when it not moving the animation “run” not work, and then he gonna do animation “attack”, but it stuck at frame 1,


this is how I fix it, thanks for help

1 Like

Wanna bet you don’t?

I told you what you need to do yet you are arguing just because you think you are right without checking what i told you to check
And before you think i say it as something bad
Believe me NO ONE here was able to avoid same situation you are currently in
We all believed we are doing something right and wonder why it does not do what we want it to do
That is perfectly normal thing that happened to all of us
Step one is accepting the fact we are not right and try to find conflict

SOOOOO
Lets take look at 1st event on that screenshot and lets look at last
And wonder which animation should play

You really need to test this stuff out yourself
Find conflicts and remove them

It seems like they are just confused about what is wrong, you’re getting awfully aggressive for someone trying to help a newbie…

There are some other issues with your events here. The “Repeat for each” thing is not necessary in a lot of cases. And if you need to use it, try to just use it ONCE and include all of the needed events under that one repeat.

So for example you could have

repeat for each dark_knight
   pick enemy nearest dark knight
       x position of dark knight is > enemy.X()        |      flip = yes
       ----------------------------------------------------------------------------
       x position of dark knight is <= enemy.X()       |      flip = no
       ----------------------------------------------------------------------------
       distance to enemy < 800 pixels                  |       move toward enemy
       distance to enemy > 80 pixels                   |       change animation, etc
       ----------------------------------------------------------------------------
       distance to eneme < 80 pixels                   |      stop dark knight
                                                       |      change animation to attack

Those are all sub-events of the one “repeat for all X”.

You also don’t need any of those AND (&) conditions. Those are only needed if you used OR (||). If you didn’t use OR, don’t use AND. All conditions are taken into account by default.

1 Like

How to say i dont really know does it make the game more heavy or not when we use repeat for each object, because yesterday somehow i make it without for each object it make all dark knight flip, so and repeat for each object( just in case) :sweat_smile: anyway thanks for suggest i gonna change to make it shorter

Agreed, tone it down. As a lecturer siad - “If you don’t understand what I’m saying, it’s because I haven’t explained it well enough”.


That’s most likely because you use the flip action without a condition.

This event will flip all knights, because there is no condition to select which knights to work on. If no condition is given, the default is all of them (or whatever was selected by the parent event if it’s a subevent):




This following event will only flip the knights that are to the right of the player, and not the knights on the left, because the condition selects which knights to act on:

Using a repeat and checking each one is computationally more expensive than checking them in batch. Because a “Repeat for each instance” event is a bit more processor expensive, too many of them can cause the game to slow down. Use them sparingly, when the change that needs to be applied is unique to each one.

In the case of your game, many of the events do not need a “Repeat for each instance of...

@MrMen @magicsofa
You should quote whole paragraph you are referring to and not just part of it
Because its ultra easy to interpret something any way you want what you only cut part of it out of context

And whole paragraph was

I told you what you need to do yet you are arguing just because you think you are right without checking what i told you to check
And before you think i say it as something bad
Believe me NO ONE here was able to avoid same situation you are currently in
We all believed we are doing something right and wonder why it does not do what we want it to do
That is perfectly normal thing that happened to all of us
Step one is accepting the fact we are not right and try to find conflict

You did not understand at all what i meant and get it all wrong
So to clarify the very line before you cut the quote

And before you think i say it as something bad

Was meant for any1 to understand i did not mean something bad with what i wrote
But that we ALL including me and every single user here were in same exact situation
Where we argued it should work instead of checking will it work if we make something in a different way

Yet you both decided to focus only on part of what i wrote instead of whole paragraph

What is even more bizarre to me is that OP did not have problem with what i wrote but users that did not come here to get help did

I would assume OP understood i wrote what i wrote to solve problem he was facing and not as something that was meant to sound hostile
(Other thing is i wrote my reply BEFORE OP replied that he solved his issue
Yet my reply was waiting for approval and that’s why it was posted AFTER OP got it working announcing it with his reply)
You two got it way wrong
And on top of that i do not see any of you offering me different choice of words
I would say by that you made it look more hostile than helpful
It would hard for me to believe you had bad intentions
Because i do not assume worst out of other users
I would suggest you should not also
And if something sounds bad to you then you can simply ask what author meant instead of jumping into conclusions

I am not bet i dont or not, i just find the way that i can easy to do, thanks for your suggest but that way you say i dont know how to do, just to let you know, calm down i not want make my instructor mad, :sweat_smile::+1:t3:

We both read it the same way as being a bit strong. Now that you explained it, I get that wasn’t your intention. The term “I told you” can be taken a number of ways, and I read it as it being used in a more patronising or “you-are-a-newbie-and-I-need-to-spell-things-out” manner. And as you wrote, that’s not what you meant.

Before hitting that Reply button, you could reread what you write and consider if it could be taken differently. I had to do that with this reply, because I don’t want to come across as a hypocrite or have what as I wrote misconstrued. And I probebly still failed :expressionless:

Oh i see, i gonna change it, you right it load little bit slower when many repeat, thank for help

See that’s the problem here
I do not need to reread it
I know exactly what i meant
You two just assume the worst and jump into conclusions
I would agree with you if i would get that from all users yet i do get it only from some so i question does some ppl understand what i meant or some just look for worst in what i write

Like i wrote you pointing out that my reply sound bad could be taken by me as something hostile
Where if any of you wrote “instead of that you could say blablablabla”
I would have no doubt your concern is about other users do not get something bad out of what i wrote instead of trying to humiliate me
Yet i don’t do that i do not assume any of you meant something bad
So as you see it is easy to interpret stuff way you want instead of way it was meant to be

I give every single tip i could to OP so he could solve his problem on his own without holding him by hand
Or more likely understand what is causing it and by that be able to avoid repeating it in the future as he will for sure add more animation change events
If you give plain solution like click here choose this and do that
In most cases you allowing person with problem not to learn from his mistakes and just allowing it to repeat them in the future
That is why i started my 1st post here with “General rule”
(Well other thing it would vary from problem to problem
This is logic conflict which needs to be understood where idk for example how to change object position to cursor position should be give plain explanation like click here and writhe this and that)

I am here almost 2 years and i found only ONE user who straight up insults other users just because he fell like it
So aside from that 1 user every single user i met here was trying either to provide help or get help and not here to lecture others or to act like A-hole
So i can’t really judge others by that one user standards

On top of that i hardly see how telling idiot that he is an idiot helps any1 (I am not calling any1 idiot i am just giving example here)
Where right course of action is not to point that out but provide solution to a problem and force said user to try that solution
Since in most cases if someone do not understand something in the 1st place he just need to try the solution instead of arguing or getting even more explanation he won’t understand or accept

And just to prove my point example from yesterday

User on discord wanted action to change healthbar based on players HP
it was different in example (guess old example) than what should be used
image


Said user was over an hour that it is different in example than what i show him instead of trying
image
I provided link to discord message when our conversation starts above
But let’s look what was final outcome
image

So bottom line i should do what i did here
Do not repeat myself over and over for an hour but just force user to try my solution
And said user would get it working much faster

SO i question if what i wrote here was wrong in any shape or form since it lead to solution very quickly

Yet on discord it turned out as user refuse to accept facts and not even care to try to do what he was told to do

I hope that all wall of text explain it perfectly


i make it look like this bring to sub-event like as you said, did i do right, thanks for help me :+1:

It doesn’t matter if your solution is correct or not. Your responses are written with a condescending tone. You can’t just always say “but I don’t mean it that way.” You’re inevitably going to make people feel like they are being attacked rather than taught. And, now ironically you are getting really offended after all I said was “you sound aggressive.” If you want examples of how to respond, just look at other posts in the forum.

Show me or even quote me the part where i mention anything about me getting offended
I only proved how easy it is to interpret something the way you want instead of the way it was meant to be
You again interpret my words as you please instead of either asking was this what i meant or not
I cannot take responsibility for what you or any user care to take out of my words
I can only take responsibility for what i actually meant
And like i said i refuse to believe you or any other user care to lecture me with something bad in mind

And i don’t see anything wrong in my messages because i know what i meant if you or any1 don’t know then you get it the wrong way and that is the issue here
I am here almost 2 years or over 2 years now
I speak to every1 the same way and only users i find having any problems with how i express myself are not the ones i try to help but bystanders which make off-topic just to address it not providing examples how i could correct it in their eyes
So i do see something is wrong here

Cause right now this

If you want examples of how to respond, just look at other posts in the forum.

Sounds like someone is coming here asking for help and your response is “use search function”

In same fashion i could say go to my profile look on some or all topics i reply to to help someone and you can notice NEVER person i did try to help had problem with how i express myself
Yet now you do? Where i did not even interact with you?
And you felt urge need to go out of your way to point that out without offering possible solution to it?

Now you will get that most likely also as something aggressive while i am just trying to explain something to you

And we can argue whole day and in the end i will stand by i know what i meant and its not what you are implying

So i think i explained it best way i can and i have nothing more to add
If you still see something wrong in my responses while person to which i respond don’t then it would be better if you just block me
Cause you are not solving anything but just going with personal issues you have toward me

This thread has derailed too far from the original topic. I’m closing it, as this arguing amongst ourselves is pointless and not contributing to the community.