collapse

Author Topic: CNS Help  (Read 389 times)

0 Members and 1 Guest are viewing this topic.

Offline -Whiplash-

  • Prince of Latis
  • RMM Contributor
  • ****
  • Posts: 1754
  • Country: Canada ca
  • Last Login:December 25, 2021, 12:18:48 AM
  • Destroy the Core!
    • Email
CNS Help
« on: December 25, 2011, 08:17:18 PM »
Hey, I'm trying to learn how to code a little bit so I can patch my shuma-gorath to be more like mvc3/mshvssf but I do not understand the CNS file very well.

I want to know how to make moves launch and edit chaining. But I do not understand how from reading the guides I've read so far. Can anyone reccomend a good guide for this sort of thing?
« Last Edit: December 30, 2011, 12:17:50 PM by Acey »



Offline Acey

  • Infinity Administrator
  • *
  • Posts: 9579
  • Country: United States us
  • Last Login:December 05, 2022, 10:43:15 PM
  • "Victory means nothing, the fight is everything."
    • Infinity Wiki - Acey
    • Email
Re: Help
« Reply #1 on: December 30, 2011, 12:10:26 PM »
http://www.infinitymugenteam.com/infinity.wiki/mediawiki/index.php?title=Character_Creation_Tutorial

Once you read this I can answer any and all of your questions. More importantly:

Launching:

The CNS file is broken into a ton of small code sections, each divided into [statedef]. For example [statedef 200] is typically light punch, [statedef 210] is medium punch and so on. With Shuma you're probably looking for [statedef 420] which would be crouching hard punch. In general all the code for that statedef is contained between the title [statedef 420] and ends when a new [statedef] title is made.

Each smaller set of code inside the [statedef] is called an sctrl (state control)

Now to make this move a launcher you'll need to find the sctrl labeled as typer=hitdef. This would be the sctrl for when Shuma hits the opponent. Then you can change the porperties here such as "ground.velocity = x, y" to make it work more like a launcher.

Chaining:

There are a few ways to program chaning in mugen but the way I strongly suggest is by using the code in the CMD file. Here is an example of an sctrl in the CMD file:

[State -1, Medium Hit]
type = ChangeState
value = 210
triggerall = Command = "y"
triggerall = Command != "holddown"
trigger1 = Ctrl
trigger2 = (StateNo = 200) && (Movecontact) && time > 3
trigger3 = (StateNo = 230) && (Movecontact) && time > 3


First notice the "triggerall", this means you must press "Y" to do this move, also you must not be holding down (since this is a standing attack). The notice "trigger1" is the main trigger, you can do this move when you have control of the character. In general if you are attacking or being hit you do not have control of the character until the move is completed. Next is "trigger2" which is important for chaining. StateNumber 200 is Light punch, so this code lets you cancel/chain from light punch into this medium punch as long as light punch has been active for more than 3 game clicks. "Trigger3" is similar to "trigger2" but it refers to light kick which can now chain into medium punch, which is typical for Versus series combos.

I hope all of this helps. The IMT wiki has a lot of great resources for programmers.

Tags:
 


* IMT Facebook

Help us by Donating!

IMT Discord

Join us at our Discord! Click the image below!

* IMT Shoutbox

Sorry, this shoutbox does not exist.

* Recent Posts

* IMT Calendar

April 2024
Sun Mon Tue Wed Thu Fri Sat
1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 [27]
28 29 30

SimplePortal 2.3.5 © 2008-2012, SimplePortal