+ All Categories
Home > Documents > Read mepdf v3_0_07_00weaponcontrol

Read mepdf v3_0_07_00weaponcontrol

Date post: 06-Aug-2015
Category:
Upload: matumit-sombunjaroen
View: 64 times
Download: 0 times
Share this document with a friend
Popular Tags:
16
Controller Layers Setup Layers in Animation Controller accordingly Last Updated in 2.5 Layers controls are in WeaponControl_Base_RangeWeapon and WeaponControl_Base_CloseCombat Scripts Each Layer will got Control According to the Weapons used, and the Motion State that the Character is in **Layer Sync require Unity Pro** RightArm and FullBody Layers became obsolete in 2.5
Transcript

Controller Layers

Setup Layers in Animation Controller accordingly

Last Updated in 2.5

Layers controls are in WeaponControl_Base_RangeWeapon and WeaponControl_Base_CloseCombat Scripts Each Layer will got Control According to the Weapons used, and the Motion State that the

Character is in

**Layer Sync require Unity Pro** RightArm and FullBody Layers became obsolete in 2.5

Setup Weapon Manager

Either from UnitSetupEditor or Manual AddComponent,

Add UnitControl_WeaponManager to Character Unit During Game Start, Specific Weapon Control will be

added depending on which Weapons the Unit is Equipping

Last Updated in 2.3

WeaponManager Script

Inside UnitControl_WeaponManager This determine how many Weapon the Unit can equip static int eqNum = 4; This determine which weapon index the Unit is using public int currentWeaponIndex = 0; This function has sample on how to equip weapon via Script protected void EquipWeapon() Inside InputManager, SelectWeapon will return the Index of currently selected Weapon public int SelectWeapon() { if(Input.GetKey(KeyCode.Alpha1)) return 0; return -1; } See Next page for Details on WeaponData

Last Updated in 2.3

WeaponData Structure

This is a Completely new System in V3.0 onward, Previous Version WeaponData became Obsolete

Last Updated in 3.0

WeaponManager WeaponDataSet Slot

WeaponManager Hold A list of WeaponDataSet, that can be insert via Component Slot in Inspector

Weapon DataSet

WeaponData

AuxData

Weapon DataSet

WeaponData

AuxData

Weapon DataSet

WeaponData

AuxData

Weapon DataSet

WeaponData

AuxData

New to V3.0 Instead of using a Universal Weapon Data Class Each Weapon type have class specific to them

instead.

WeaponData common data

Last Updated in 3.0

Create Data via UnitSetupEditor WeaponObject is the GameModel use for the Weapon If it is not loaded, PreFab with the Same Name, inside any

Resourced Folder will be loaded and Instantiated. Material is specifically use for Hitting sound, will be

explain In ReadMePDF_V3_0_07_02MeleeWeaponControl

Transform Data determine how the weapon model will be

place on the Character’s hand when Instantiated. Type is WeaponType 3.0 Type is no longer used as each weaponType is specific to a class ATK is weapon’s Attack Power and Element Each WeaponType have their own Parameters that will be

explained individually

WeaponObject Prefab Position

Last Updated in 2.5

If UnitSetupEditor, Will use Weapon is use, the following Transform will be made. WeaponSlot_Head, as a child of Head WeaponSlot_Arm, as a child of Right and Left Arms WeaponSlot_Hand, as a child of Right and Left Hands WeaponSlot_Leg, as a child of Right and Left Legs ** If Will use Weapon is false, all Transform contain the name “WeaponSlot” will be deleted. ** These will be use for positioning of weapon, as well as Melee Attack Control If these were not made, bone Transform will be use instead.

Since not every rig will share the same Bone Rotation, each WeaponSlot transforms must be tweak manually

WeaponObject Prefab Position

Last Updated in 3.0

To Get the Correct Positioning of the Weapons to Unit’s hand, do the following 1. Make Weapon a Child of Desired Weapon Slot 2. Position the Weapon to desirable Position and Rotation 3. Record Transform variable numbers 4. Put those Numbers back to WeaponData

The Scripts will automatically place the weapon to correct position When Game Start **If the Weapon seems to disappear, it is possible that Scale got set to 0,0,0**

AuxData

Last Updated in 3.0

Create Data via UnitSetupEditor AuxData is abbreviated from Auxiliary Data. They act as supplement Data to Weapon Aux Prefab and AuxFX are GameObject that

got instantiated when Character Attack, such as Bullet or Punch Wave.

SoundFX is AudioClip that got Played when Character Attack

AuxMode and ATK determine how additional

Damage is Calculated If ATK’s element is not NONE, it will override

Weapon Consumption determine how much MP,

Battery, or Item is used per Attack ClipAmount_Recharge will be explained for

each Consumption Type **Currently, do not apply to Melee Combat**

ConsumptionType - NONE

Last Updated in 2.3

Character can do Attack Indefinitely

ConsumptionType - MP

Last Updated in 2.3

If Aux’s Consumption is MP, The Attack will consume MP from Unit Status per Attack If Consumption Value is Greater than Status’ MP, The Character cannot do Attack

ConsumptionType - Battery

Last Updated in 2.3

If Aux’s Consumption is Battery, Combo in WeaponControl will be set to 100 The Attack will consume Combo from Weapon when doing an Attack If Consumption Value is Greater than Combo Value, The Character cannot do Attack

ClipAmount_Recharge determine how fast Combo got recharge.

Recharge will be done even if Weapon is not being

equip To Edit Recharge rate formula, go to UnitControl_WeaponManager function RechargeBatteryCoroutine

ConsumptionType - Item

Last Updated in 2.3

If Aux’s Consumption is Item, Combo in WeaponControl will be set equal to ClipAmount_Recharge The Attack will consume Combo from Weapon when doing an Attack If Consumption Value is Greater than Combo Value, The Character cannot do Attack and will attempt to Reload

If the Character try to do Reload, it will find Item with the same AmmoName within Unit Inventory and refill the Combo from there.

Unit Inventory

Last Updated in 2.3

Inside Unit Inventory, the Player can adjust the data directly via the Editor. Or, via Script, call this function from a method of your choice. AdjustItem("Ammo",100); If the Item do not exist inside inventory, it will be added

WeaponDataSet

Last Updated in 3.0

Create Data via Unit Setup Editor 3.0 Onward Each Weapon type will only use weapon and

Aux that they can use. It is now possible to edit Weapon and Aux

data directly from WeaponSet instead of having to inspect each individual ScriptableObject

Weapon_DataSet_Melee

Last Updated in 3.0

By Pressing View Button on each part, Data for that part will be displayed and can be

edited directly. Each weapon can be apply to specific body

limb Melee combat will use the data from first

weapon slot, Unless a limb with specific weapon is allocated

Weapon_DataSet_FireArm

Last Updated in 3.0

Weapon_Dataset_Dual_FireArm can use both 1H and 2H FireArm

Weapon_Dataset_Dual_FireArm Can only use 1H FireArm Weapon type. If the 2nd set of Weapon Slot is empty, The data from 1st set will be automatically

allocated.


Recommended