The Mugen Fighters Guild
M.U.G.E.N Central => M.U.G.E.N Discussion => Development => Topic started by: Elix on October 08, 2007, 06:25:33 pm
-
Has anybody though about it? How to determine whether a character exists in his own states or in his opponent's. The application of this issue, if it was resloved, is wide. For example, we can properly stop the looping sound when the character goes to custom state.
-
i can't remember the actual code, but yes, it has been done , it has somethign to do with the fact that st-2 is always executed and st-3 is executed only when you are on your own states.
i am not sure which is executed first, but it should be something like this:
in state-3
varX = 1
in between, put whatever you need to check for.
in state-2
var X = 0
when varX = 0 you are not in yoru states.
-
In your statedef -3:
[state -3, something fancy here]
Type = VarSet
trigger1 = 1
var(1) = gametime
In your statedef -2
[state -2, check if I'm on a custom state]
Type = VarSet
trigger1 = 1
var(2) = var(1) = gametime
Statedef -3 is always processed first. Then we get statedef -2, -1 and the current player state.
Since statedef -3 is not processed while the player is on a custom state, var(2) will return 0 whenever he's on a custom state.
-
You are a bookshelf of knowledge, Bia :) I believe this topic should be added here:
http://mugenguild.com/forumx/index.php?topic=41715.0
-
Statedef -3 is always processed first. Then we get statedef -2, -1 and the current player state.
Since statedef -3 is not processed while the player is on a custom state, var(2) will return 0 whenever he's on a custom state.
And -2 and -1 are interpreted during a custom state, then?
-
And -2 and -1 are interpreted during a custom state, then?
Just -2.