Fake animation - turn IMPLEMENTED

Any other ideas that does not fit to the specific categories.
Post Reply
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Fake animation - turn IMPLEMENTED

Post by Stratego (dev) »

i received many reqquests to unit to at least turn to their target - and maybe on moving direction by flipping the image.

i thought a "generated" way so we dont need to draw anything from the i can say thousands of unit images in all alternatives.

here is a way where the logic can flip automatically the image :
unit_teuton_turn.png
unit_teuton_turn.png (4.42 KiB) Viewed 3384 times
it has its drawback, if an unit is not symmetrical than would look not so nice changing hands of weilding a sword :)

but as on trebuchet or a tank would look better as that is symmetric.

any ideas?
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Fake animation - turn

Post by Stratego (dev) »

also a tank, not that nice...
Attachments
tiger_turn.png
tiger_turn.png (22.01 KiB) Viewed 3381 times
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Fake animation - turn

Post by Stratego (dev) »

or this
Attachments
tiger_turn2.png
tiger_turn2.png (17.72 KiB) Viewed 3375 times
User avatar
Puss_in_Boots
Posts: 3206
Joined: Fri Apr 21, 2017 1:23 am
Location: New Jersey

Re: Fake animation - turn

Post by Puss_in_Boots »

Oh like how Paper Mario - Super Paper Mario characters and enemies flip around? That'd be cool, my second idea on forum since I joined has resurrected in a new form.

Just make sure this doesn't happen to buildings(with exception of shielded ranged), it'd be weird.

I like the 2nd tank animation better, less space taking.

Also in mapeditor, it should probably play the animation and flip a placed unit whenever it is tapped on while the same unit is selected.
OLÉ
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Fake animation - turn

Post by Stratego (dev) »

yes, almost like mario, but i would not make a phase when the whole body is 1 pixel width when looking forward so i made only 2 other phases in angle of about 45degree (not rotation,, i used perspective tool)
Moh556
Posts: 326
Joined: Sun Nov 18, 2018 2:43 pm
Location: Iran

Re: Fake animation - turn

Post by Moh556 »

Can we do this for arrows and ...?
I mean when archers use bow . The arrow came to sky and go dawn again
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Fake animation - turn

Post by Stratego (dev) »

that is a different thing, open new topic if u like
User avatar
Dagravian
Posts: 938
Joined: Tue Sep 06, 2016 6:20 am
Location: Terra - Brasil

Re: Fake animation - turn

Post by Dagravian »

The one with teotonic knight looks nice... The ones with tiger looks ackward... I don't mind the unit being mirrored. But i think the 1-2px stage should not be skipped on the animation...
Stay Awesome!
(ノಠ益ಠ)ノ彡┻━┻
User avatar
Gral.Sturnn
Posts: 1877
Joined: Tue Feb 13, 2018 11:29 pm

Re: Fake animation - turn

Post by Gral.Sturnn »

We would only need 2 sprutes per unit, just flip the normal one and the addition of an arrow to indicate the direction of the unit
~Gral.Sturnn
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Fake animation - turn

Post by Stratego (dev) »

i dont understand the arrow thing.

this topic is about the idea that we only have 1 sprite (as we don on the thousands of units) and manipulating that one only. no one will make a next image for that housand sprites.
User avatar
Puss_in_Boots
Posts: 3206
Joined: Fri Apr 21, 2017 1:23 am
Location: New Jersey

Re: Fake animation - turn

Post by Puss_in_Boots »

It doesn't take much time to mirror all images on an image manipulating software, but it'd be a coding nightmare than to just code for all images to flip left/right accordingly. It'd also save space as that wouldn't require a duplicate image if it's the same sprite anyways but mirrored.
OLÉ
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Fake animation - turn

Post by Stratego (dev) »

no nightmare at all.
and better in memory consumption too.
User avatar
Dagravian
Posts: 938
Joined: Tue Sep 06, 2016 6:20 am
Location: Terra - Brasil

Re: Fake animation - turn

Post by Dagravian »

I got a new question... Does that will affect units with animated imgs? I mean, the generator will flip all frames of the animation or just a single (first) one?
Stay Awesome!
(ノಠ益ಠ)ノ彡┻━┻
User avatar
Puss_in_Boots
Posts: 3206
Joined: Fri Apr 21, 2017 1:23 am
Location: New Jersey

Re: Fake animation - turn

Post by Puss_in_Boots »

I meant inserting 2nd img name for all JSONs in game by hand would be the nightmare. Instead of just a simple image mirror logic.
OLÉ
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Fake animation - turn

Post by Stratego (dev) »

DoomsdayDragonfire wrote: Tue Aug 13, 2019 1:02 pm I got a new question... Does that will affect units with animated imgs? I mean, the generator will flip all frames of the animation or just a single (first) one?
if i can than it will animate while flipping.

if that is hard than only the first.
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Fake animation - turn

Post by Stratego (dev) »

ok, the first version of the logic is in AOS.
it is without animation, but it turns to the direction of attack or movement or any other action.

uos 10

please test it, and tell me if i missed to turn any unit images needed to flip to work in right direction.

in AOS all units are looking to right by default, so pelase make images this way from now.
User avatar
Puss_in_Boots
Posts: 3206
Joined: Fri Apr 21, 2017 1:23 am
Location: New Jersey

Re: Fake animation - turn

Post by Puss_in_Boots »

Right away I can tell that units flip left instead of keeping their last img when going up or down only.

But other than that, my mind was blown to see them flip when they moved or attacked to their left as I had never seen it before in this game.
OLÉ
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Fake animation - turn

Post by Stratego (dev) »

Right away I can tell that units flip left instead of keeping their last img when going up or down only.
i see, on totally vertical actions it should not flip anywhere - ok i go fix it.
User avatar
Puss_in_Boots
Posts: 3206
Joined: Fri Apr 21, 2017 1:23 am
Location: New Jersey

Re: Fake animation - turn

Post by Puss_in_Boots »

So the units that I caught facing left were:
-Fire Archer
-Huntress
-Dogmatix

*And every seige weapon that isn't a battering ram or ballista.
OLÉ
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Fake animation - turn

Post by Stratego (dev) »

yes they are already set to be lefty, or are they moving wrong-opposite way now?

update: fire archer and huntress and dogmatix was worng, fixed -thanks!

but i think all siege is ok - arent they? if not tell me one that is not good - thanks!
User avatar
Puss_in_Boots
Posts: 3206
Joined: Fri Apr 21, 2017 1:23 am
Location: New Jersey

Re: Fake animation - turn

Post by Puss_in_Boots »

Only the seige mantlet doesn't turn.
OLÉ
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Fake animation - turn

Post by Stratego (dev) »

good!
it is fixed too!

if u say that is all -> i build a new one uploading to server - thanks!
User avatar
Puss_in_Boots
Posts: 3206
Joined: Fri Apr 21, 2017 1:23 am
Location: New Jersey

Re: Fake animation - turn

Post by Puss_in_Boots »

Forward facing unit imgs aren't going to flip right? For example there is janissary unit that doesn't turn, but it doesn't seem to face right or left either.
OLÉ
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Fake animation - turn

Post by Stratego (dev) »

those will be flipped too but will not matter actually :)
tell me if i can update the version.
User avatar
Puss_in_Boots
Posts: 3206
Joined: Fri Apr 21, 2017 1:23 am
Location: New Jersey

Re: Fake animation - turn

Post by Puss_in_Boots »

Yeah it works well as it is, even the trojan horse flips.
OLÉ
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Fake animation - turn

Post by Stratego (dev) »

ok building a new uos 10 - thanks!
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Fake animation - turn

Post by Stratego (dev) »

also please keep your eyes on buildings, none of them should "turn" to direction they shoot (like towers) lol :)
Post Reply

Return to “Others”