User Tools

Site Tools


character:physics

This is an old revision of the document!


Physics

Define here how this character moves and reacts to applied forces in your game.

Horizontal Movement

Move Forward Speed: How fast this character moves when walking forward.

Move Back Speed: How fast this character moves when walking back.

High Moving Friction: When this character stops moving, should it stops immediately or slide slightly (based on the friction)?

Friction: When forces are applied to this character while on the ground, how far will it “slide”. If High Moving Friction is off, this friction will also be applied to the character when its walking. Characters like Hakan (SF4) while oiled up, has a very low friction.


Jump Options

Enable Jump: Toggle off to disable jumping for this character.

Jump Force: How much power is applied by this character when it jumps. The higher the force, the higher the jump.

Jump Distance: When making an angled jump, how far will this character move while in the air.

Jump Delay (frames): How many frames should the character wait before it jumps after you press the button.

Landing Delay (frames): How many frames before the character is allowed to move after landing from a jump (character can still block and cancel landing into moves).

Air Jumps: Set double/triple jumps here. This works as any game with double jump, aka, pressing up while in the air.


Mass Variation

Character's Weight: The weight of the character related to air resistance. Weight directly affects every air force applied to this character, including jumps. Example: A character like Dhalsim can have weight set to a very low value, making him almost “float”.

Ground Collision Mass: The density of the character's ground collision box. A lower value makes the character stronger when pushing into another character assuming both have same movement speed and weight. Best to leave this at default of 2 for consistent behaviour.

Cumulative Force: Anytime force is added, do we accumulate with current forces? Leaving on gives more expected behaviour with juggling, but some games may require forces reset on each hit.


Code access:

UFE.config.player1Character.physics

Code example 1:

void OnHit(HitBox strokeHitBox, MoveInfo move, CharacterInfo hitter){
	if (hitter == UFE.config.player1Character){
		if (UFE.config.player2Character.characterName == "Shozo Iizuka") {
			UFE.config.player2Character.physics.weight = 175;
		}
	}
}

Code example 2:

void OnMove(MoveInfo move, CharacterInfo player){
	if (move.moveName == "oil up"){
		player.physics.friction = 10;
	}
}

< Back to Character Editor

character/physics.1431926210.txt.gz · Last modified: 2015/05/18 01:16 by Mistermind