ForesightBy: The Aboriginal One.Hey, ya'll. I'm Brandon Marquis Markail Green, A.K.A. The Aboriginal One, and today, I am going to teach you how to do a foresighting technique.Foresight is an ability to predetermine an opponent's move. Using foresight, a player can either do a more special move, or automatically dodge or evade said attack.Reading this tutorial means you know a little about M.U.G.E.N. CNS syntax, and you know how to do a simple move. The only prerequisites are that, and the knowledge of statedef -3 If you don't know statedef -3, that is a state that can only be executed when using own states. Congrats, you now have the prerequisites!First, lets make a simple statedef.[Statedef xxx]type = Sphysics = Smovetype = Ictrl = 1velset = 0This is not etched in stone. You can change it to whatever you like. Next it's the Forsighting technique.[State xxx, Foresight]type = VarSettrigger1 = 1var(10) = P2StateNoThis simple state just finds the state number of the target, or the nearest enemy towards you, and adds it to var(10), or any variable, it doesn't matter, unless you are already using that variable, then it's a no-no. Also, this just gives the recent stateno, so remember to add triggers to adjust it so that you don't go willy-nilly on the idle stances.Next, we'll use statedef -3 to automatically do something when that state is executed.[State -3, Foresight]type = ChangeStatetrigger1 = P2StateNo = var(10)value = YYYAs simple as that. Remember, that your variable will start with the value of 0, so you'll need a trigger like so.Trigger1 = P2StateNo != 0Now implement it on your character, and watch what happens. I implemented it of KFM, and he did his hyper Smash Kung-Fu Upper everytime someone did the low kick. Then I resetted it by pressing the button I implemented the move to and he did it as soon as someone crouched. Don't say I don't know M.U.G.E.N., and please give me reviews and join my forum. Peace and Love
Just tested it. It's really a nice feature. Nice thinking mate. Although it could be abused, but bleh. I'm supposing this could go with a psychic type char, or your usual OMFGUBERLEETCHEAPBO$$.
Great and simple. This will be really good for people with little M.U.G.E.N. knowledge. I was planning to do something like this for my DBZ/GT full mugen game. Except you'll teleport behind the opponent and attack when they try to attack you. Again, nice tut. Looking forward to more.
Valodim said, January 23, 2007, 06:47:47 pmthat's kinda the simplest ai possible, and since it depends on statenumbers it's hardly useful Shaza, It can be useful. It's simple, yes, but you can always make it as advanced as you want it to. Besides, sometimes the simple things are nice.Kratos said, January 23, 2007, 06:45:23 pmI was planning to do something like this for my DBZ/GT full mugen game. Except you'll teleport behind the opponent and attack when they try to attack you. Again, nice tut. Looking forward to more.to do that...[State -3, Foresight]type = ChangeStatetrigger1 = P2BodyDist <= ?trigger1 = P2MoveType = Atrigger1 = Stateno = YYYvalue = ZZZwhere YYY is the stateno you want to activate the forsight's capabilities, and ZZZ is the resulting coming-up-from-behind-and-bust-one-out-attack. it'll be a nice Warp Kamehameha Wave technique.
Kratos said, January 23, 2007, 06:45:23 pmGreat and simple. This will be really good for people with little M.U.G.E.N. knowledge. I was planning to do something like this for my DBZ/GT full mugen game. Except you'll teleport behind the opponent and attack when they try to attack you. Again, nice tut. Looking forward to more.You could use it for Kid Buu or something like that.