This will be a long read, you've been warned You’ve seen it in Dragon Ball: Captain Ginyu swaps his body for Goku’s one, but things don’t turn quite as expected, resulting in the characters unable to reach full potential on the new hosts. If you don’t know what I’m talking about, here’s a short clip of the Body Change’s side effectshttps://www.youtube.com/watch?feature=player_detailpage&v=MRZziD6WxoE#t=74 How can we replicate this effect in Mugen? The engine doesn’t allow switching control directly, but there are workarounds to achieve a similar effect. I’m going to propose one of them, which I’d like to discuss with you guys on how to improve it or even find a better method. The current implementations from other authors either rely on heavy customization of Ginyu and the other enemies (such as including other character’s sprites within the SFF) or requiring lots of code that need to be updated with every character “compatible” with Ginyu. Also, some of the current implementations are really cheap such as characters exchanging life values or similar tricks, unbalancing whatever balance had the original characters. My goal was to create a code that didn’t have the abusive behavior of the previous implementations, was balanced enough to bring an added value to the fight strategy, and required the least modification for the other characters to make it compatible with Ginyu. So, this is the result:VIDEO This is what you need to make it work: Ginyu needs to place the enemy on a custom state. In the concept video I’m using a projectile, but it really doesn’t matter if you use a hitdef, a projectile or a helper to place the enemy into a custom state. The custom state in which the enemy is placed is:[ Statedef XXXX ] type = U movetype = I physics = U ctrl = 0 velset = 0 , 0 poweradd = 0 [ State Enemy Helper on Player ] type = Helper trigger1 = ! time helpertype = normal ; player name = "P2onP1" ID = 9123 stateno = 9123 pos = 0 , 0 postype = p2 facing = 1 keyctrl = 0 ownpal = 0 supermovetime = 0 pausemovetime = 0 [ State ChangeState ] type = SelfState trigger1 = ! time value = 0 ctrl = 1 This code will make P2 create a Helper that will be placed on top of Ginyu (P1). The State for the Enemy’s Helper needs to be located on the Enemy’s files. Ginyu also needs the following state, which will be the “P1onP2” Helper:; GINYU [ Statedef 9124 ] type = U ; State - type : S - stand , C - crouch , A - air , L - liedown movetype = U ; Move - type : A - attack , I - idle , H - gethit physics = U ; Physics : S - stand , C - crouch , A - air juggle = 0 ; Number of air juggle points move takes ; Commonly - used controllers : velset = 0 , 0 ; Set velocity ( x , y ) ( Def : no change ) ctrl = 0 ; Set ctrl ( Def : no change ) ; Change animation ( Def : no change ) sprpriority = 10 [ State 9124 , NotHitBy ] type = NotHitBy trigger1 = 1 value = SCA , NA , SA , HA , NP , SP , HP , NT , ST , HT time = 1 ignorehitpause = 1 ; persistent = [ State 9124 , Pos ] ; bind the helper to a fixed position type = PosSet trigger1 = 1 x = ( enemy , pos x ) y = enemy , pos y ignorehitpause = 1 [ State 9124 , turn ] ; the helper will face the enemy type = Turn trigger1 = pos Y = 0 trigger1 = facing = root , facing ignorehitpause = 1 [ State 9124 , 2 ] ; this will allow the helper to replicate the same animation than the root type = ChangeAnim trigger1 = Anim != ( enemy , anim ) trigger2 = AnimElemNo ( 0 ) > ( enemy , AnimElemNo ( 0 )) value = enemy , anim elem = enemy , AnimElemNo ( 0 ) ignorehitpause = 1 [ State 9124 , DestroySelf ] type = DestroySelf trigger1 = root , var ( 51 )= 0 ; time = 500 ignorehitpause = 1 ; persistent = This code basically places a Helper on top of the Enemy (P2) and it replicates the same animation number as the Enemy. Ginyu also needs the following -2 states:[ State - 2 , Ginyu Mode ON ] type = VarSet trigger1 = 1 var ( 51 )= IfElse (( enemy , Numhelper ( 9123 )= 1 ), 1 , 0 ) [ State - 2 , Ginyu missing animation check ] type = VarSet triggerall = Teamside = 1 triggerall = NumHelper ( 9124 )= 1 trigger1 = ( helper ( 9124 ), AnimElemNo ( 0 )) = ( enemy , AnimElemNo ( 0 )) var ( 53 ) = Ifelse (( helper ( 9124 ), anim )!=( enemy , anim ), 0 , 1 ) [ State - 2 , Ginyu missing animation check ] type = VarSet triggerall = Teamside = 2 triggerall = NumHelper ( 9124 )= 1 trigger1 = ( helper ( 9124 ), AnimElemNo ( 0 )) = ( enemy , AnimElemNo ( 0 )+ 1 ) var ( 53 ) = Ifelse (( helper ( 9124 ), anim )!=( enemy , anim ), 0 , 1 ) [ State - 2 , AssertSpecial ] type = AssertSpecial trigger1 = var ( 51 )= 1 flag = invisible ignorehitpause = 1 [ state - 3 , remove afterimage ] type = afterimagetime trigger1 = var ( 51 )= 1 time = 0 [ State - 2 , Ginyu Helper on Enemy ] type = Helper trigger1 = ! NumHelper ( 9124 ) trigger1 = var ( 51 )= 1 helpertype = normal ; player name = "P1onP2" ID = 9124 stateno = 9124 pos = 0 , 0 postype = p2 ; p2 , front , back , left , right facing = 1 keyctrl = 0 ownpal = 0 supermovetime = 0 pausemovetime = 0 var(51) basically tells the game that the Body Swap has been enabled. Var(53) keeps track of the animation of the enemy versus the helper’s animation. Due that P2 code is executed with 1 tick after P1 code, we need to do a workaround to keep that 1 tick delay, otherwise the code will not work when performed by P2. Now, let’s see the code that needs to be added to the enemy’s files to make it compatible with Ginyu:; GINYU ’ s Helper [ Statedef 9123 ] type = U ; State - type : S - stand , C - crouch , A - air , L - liedown movetype = U ; Move - type : A - attack , I - idle , H - gethit physics = U ; Physics : S - stand , C - crouch , A - air juggle = 0 ; Number of air juggle points move takes ; Commonly - used controllers : velset = 0 , 0 ; Set velocity ( x , y ) ( Def : no change ) ctrl = 0 ; Set ctrl ( Def : no change ) sprpriority = 10 [ State 9123 , NotHitBy ] type = NotHitBy trigger1 = 1 value = SCA , NA , SA , HA , NP , SP , HP , NT , ST , HT time = 1 ignorehitpause = 1 [ State 9123 , Pos ] ; bind the helper to a fixed position type = PosSet trigger1 = 1 x = ( enemy , pos x ) y = enemy , pos y ignorehitpause = 1 [ State 9123 , turn ] ; the helper will face the enemy type = Turn trigger1 = pos Y = 0 trigger1 = facing = root , facing ignorehitpause = 1 [ State 9123 , 2 ] ; this will allow the helper to replicate the same animation than the root type = ChangeAnim trigger1 = anim != ( enemy , anim ) trigger2 = AnimElemNo ( 0 ) > ( enemy , AnimElemNo ( 0 )) value = enemy , anim elem = enemy , AnimElemNo ( 0 ) ignorehitpause = 1 [ State 0 , DestroySelf ] type = DestroySelf trigger1 = time = 500 ; it ’ s a good idea to kill the helper after some time , but we can find other ways to kill it . This is up to the author ignorehitpause = 1 The enemy also needs to include this code in their -2/-3 states:[ State - 3 , AssertSpecial ] type = AssertSpecial triggerall = enemy , Name = " Ginyu " trigger1 = enemy , var ( 51 )= 1 ; Ginyu Mode ON flag = invisible ignorehitpause = 1 [ state - 3 , remove afterimage ] type = afterimagetime triggerall = enemy , Name = " Ginyu " trigger1 = enemy , var ( 51 )= 1 ; Ginyu Mode ON time = 0 ignorehitpause = 1 [ State - 3 , Prevent playing missing anim ] ; HACK type = ChangeAnim triggerall = enemy , Name = " Ginyu " triggerall = enemy , var ( 51 )= 1 ; Ginyu Mode ON trigger1 = stateno = 0 trigger1 = ! time trigger2 = enemy , var ( 53 )= 0 value = 0 ; elem = 1 ignorehitpause = 1 [ State - 3 , Prevent Wrong State S ] type = ChangeState triggerall = enemy , Name = " Ginyu " triggerall = enemy , var ( 51 )= 1 ; Ginyu Mode ON triggerall = statetype = S trigger1 = enemy , var ( 53 )= 0 value = 0 ctrl = 1 ignorehitpause = 1 [ State - 3 , Prevent Wrong State C ] type = ChangeState triggerall = enemy , Name = " Ginyu " triggerall = enemy , var ( 51 )= 1 ; Ginyu Mode ON triggerall = statetype = C trigger1 = enemy , var ( 53 )= 0 value = 11 ctrl = 1 ignorehitpause = 1 [ State - 3 , Prevent Wrong State A ] type = ChangeState triggerall = enemy , Name = "Ginyu" triggerall = enemy , var ( 51 )= 1 ; Ginyu Mode ON triggerall = statetype = A trigger1 = enemy , var ( 53 )= 0 value = 50 ctrl = 1 ignorehitpause = 1 I’m using a enemy,name trigger to check the identity of Ginyu and then execute the necessary code. Other alternatives to this would be through a helper or anim check, but as this is a concept move, I’ll leave the possible methods of “standardization” open to discussion. The full code results in a helper on top of an invisible character repeating the same animation as the invisible character. That means if P1 plays animation 200, the Helper will play the same animation 200 using his own sprites (actually the other player’s ones). If the character plays an animation not available or if the animation from the character is longer or shorter than the one from the Helper, then it will revert to an idle state. This replicates the original concept of the move in which the characters weren’t able to reach the full potential of the new bodies. It also brings a new strategy layer as both characters are nerfed down having most of his attacks disabled for the duration of the move. The full code is also to implement in other characters as it can be placed at the end of statedef -2 or -3, requiring one single copy&paste process to make it compatible. There are no sprites to be added or modified, making it easier the compatibility with other characters Ginyu also doesn’t need to update his code every time a new character is added to the compatibility list. The code isn’t exempt of problems though. First of all, whenever a character tries to play a missing animation, there will be a debug warning. Also, the characters could get stuck for some ticks while performing some moves. Another known issue is that the actual animation and clsn boxes are the ones from the invisible character. This means that if animation 200 for the character is a high punch, but the enemy’s animation 200 is from a low kick, the hitsparks and the movehit behavior will not reflect on the animation being displayed. Effects such as Explods around a particular animation will still be played on the Helper (which in some cases will not match with what's shown on screen) Also, in the same fashion, the Helper could turn into a fireball if the animation numbers from one character match the Helper’s ones. A full game implementation using my “helper on top of character” would easily prevent such problems by restricting the attacks that could be performed during the Body Change being enabled -remember Ginyu’s var(51)- as well as limiting the explods that should be displayed during Ginyu’s Body Change mode. Obviously this will require more customization on the enemy’s files, but for full game authors, my method could be a viable option to implement a true Body Change attack. Let me know your thoughts or comments on this