News:

MFG's Character of the Month: October 2026 Nominations

Main Menu

Mini animated "portrait" of character

Started by Ryon, September 30, 2015, 10:00:39 PM

Previous topic - Next topic

Ryon

Hello all, I'm trying to replicate an effect from the game Guardian Heroes.
The effect is very similar to how some older Guilty Gear character's are coded, where they have a mini version of themselves in the corner that mimic's there every motion.

I got some codes down and it works (thanks to alexei) I used a helper, but then I found another issue, when I jump the helpers would move.
I've tried various bind codes and possets and nothing.

So i'm here to you all asking what is the BEST way to get these results? Helper+Explods, or Helpers all the way?

and also if someone is willing to PM teach me, I'd be VERY grateful.

XGargoyle

use a PosSet to freeze the helper in a specific position?


XGargoyle: Battle posing since 1979
http://xgargoyle.mgbr.net
http://www.pandorabots.com/pandora/talk?botid=e71c0d43fe35093a  <-- Please click that link
http://paypal.me/XGargoyle  <-- Donations welcome!

Ryon

#2
I tried that and it works ok, but when they jump the small fighters slide.


Maybe im explaining it wrong. They are in the position they are supposed to be in, what I want is for them to stay within the portrait boxes.

or do you think I should make the lifebars also Helpers? so everything will move the same?

altoiddealer

The helper needs to have constant PosSet controllers

I think something like this...

type = PosSet
trigger1 = TeamSide = 1
x = -150
y = -ScreenPos Y + 60

type = PosSet
trigger1 = TeamSide = 2
x = 150
y = -ScreenPos Y + 60


Odb718

The first problem I'd see is the actual animation. Jumping sprites and air attacks and the rest of them physically move.
The second problem altoid already explained.
vVv Gouken718 vVv SabreTooth718 vVv


altoiddealer

Quote from: Odb718 on October 01, 2015, 01:49:03 AM
The first problem I'd see is the actual animation. Jumping sprites and air attacks and the rest of them physically move.
The second problem altoid already explained.
Yeeeeap

Maybe include an OffSet controller that triggers for certain anims / animelems


Ryon

This is what i have.
;---------------------------------------------------------------------------
; P1 Animated Portrait
[Statedef 5800]
movetype= I
sprpriority = 5
anim = 9999

[State 0, ChangeAnim]
type = ChangeAnim
trigger1 = 1;anim !=root,anim
value = root,anim
elem = root,animelemno(0)

[State 0, PosSet]
type = PosSet
triggerall = teamside = 1
trigger1 = 1
x = -137
y = -152
ignorehitpause = 1

[State 0, PosSet]
type = PosSet
trigger1 = teamside = 2
x = 137
y = -152
ignorehitpause = 1

[State 0, Turn]
type = Turn
trigger1 = teamside = 2
persistent = 0

[State 0, NotHitBy]
type = NotHitBy
trigger1 = !time
value = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
time = 999999


I tried a offset code with statetype and enemy,statetype codes, and sadly it didnt work, it seemed really jittery.

altoiddealer

The Y parameter of PosSet is based on the ground level, not the screen dimensions, so when the screen moves up during a jump that is probably causing issues.

Using the trigger -ScreenPos basically makes it relative to the cieling instead


Ryon

using these codes
[State 0, PosSet]
type = PosSet
trigger1 = teamside = 1
x = -137
y = -ScreenPos Y + 46
ignorehitpause = 1

[State 0, PosSet]
type = PosSet
trigger1 = teamside = 2
x = 137
y = -ScreenPos Y + 46
ignorehitpause = 1


It makes the helpers flicker in 2 positions, the floor and the portrait spot. also when p1 jumps, p2's slips over the portrait box.
This is for a full game, i should note.

altoiddealer

#9
I might have messed it up

Try ScreenPos Y (no negative) + 46


I'm sorry, I'm definitely not getting it right now lol

I don't have the time at the moment to put it together, but if it's still unanswered tomorrow, I'll help you out.


ninja edit... I feel like that should be working.

Try flooring it.

y = Floor(-Screenpos Y+46)


Ryon

it still flickers.
Take your time, I'm grateful for ANY help that I can get.

alternatively would a helper that spawns a explod work better?

Felkazz

#11
Is it for MUGEN 1.1?

EDIT:
I don't think ScreenPos would be usefull here because it returns the position of the helper on the screen...
I did it using CameraPos, but it works only on MUGEN 1.1

[State 0, PosSet]
type = PosSet
trigger1 = teamside = 1
x = -137
y = CameraPos Y - 152
ignorehitpause = 1

[State 0, PosSet]
type = PosSet
trigger1 = teamside = 2
x = 137
y = CameraPos Y - 152
ignorehitpause = 1


Also, I'd suggest you to add a few things on your stadef 5800:

[State 0, NotHitBy] ;<== Modify your NotHitBy
type = NotHitBy
trigger1 = 1
value = SCA,NA,SA,HA,NP,SP,HP,NT,ST,HT
time = 1

[State 0, AssertSpecial] ;<== Disable the helper's shadow
Type = AssertSpecial
Trigger1 = 1
Flag = NoShadow

[State 0, PlayerPush] ;<== Disable collision
Type = PlayerPush
Trigger1 = 1
Value = 0

Ryon

yes it is 1.1

I could revert to 1.0 in worst case scenario, but I really want the zoom feature as well as animated portrait thing.

Felkazz

I edited my previous answer, look for my solution there ^^

altoiddealer

Aha, yeah on 1.1 it's a whole different thing.

My code definitely works for 1.0 though!  I use it for setting my player's position relative to the screen during a special hyper move


Felkazz

I don't know why it was flickering... I tried it here on a char of mine and it was really flickering... Like it was changing it's position really fast...

altoiddealer

I only set it once, but I don't see why it couldn't hold the position.

Would probably be more stable if one of the triggers is: ScreenPos Y != value (so it only repositions when necessary)


Ryon

#17
Quote from: Thunderbert on October 01, 2015, 04:30:13 AM
I edited my previous answer, look for my solution there ^^

I LOVE YOU.
The amount of thank you I want to give you, I can't express in words only tears.

Thank you both Thunderbert and altoiddealer.

https://www.youtube.com/watch?v=aUGN6B3Xepo

EDIT:
Ok! So it works with great success!
but It seems I have over looked another issue.
Stages! I tested it strictly only on KFM's Temple, and it works great.

but then I tested it on some other stages and they arent aligned anymore because the floor distance or something? its odd.

This may be an issue for me (or not if i decided to code all the stages myself the same way)

Felkazz

You're welcome!
Just mark your post as solved ^^

Ryon

*on floor dying from not being fast enough*
NOT YET!!

Ok! So it works with great success!
but It seems I have over looked another issue.
Stages! I tested it strictly only on KFM's Temple, and it works great.

but then I tested it on some other stages and they arent aligned anymore because the floor distance or something? its odd.

This may be an issue for me (or not if i decided to code all the stages myself the same way)