271
edits
(→Combat behavior part 3: "They see me shootin', they hatin'...": Will finish it later) |
|||
Line 447: | Line 447: | ||
:*w10_sni (10) - Mukade's Devil star (annoying red ball) as a holdable weapon; probably a relic from game development | :*w10_sni (10) - Mukade's Devil star (annoying red ball) as a holdable weapon; probably a relic from game development | ||
:*w10_ba1 (11) - Barabus's gun | :*w10_ba1 (11) - Barabus's gun | ||
:*w11_ba2 (12) - Barabus's gun; | :*w11_ba2 (12) - Barabus's gun; this one cannot be shot and is probably just a development relic. | ||
Line 476: | Line 476: | ||
:*Ballistic projectile speed (ProjectileSpeed) - special prediction can be used if weapon is meant to fire relatively slow but gravity affected projectiles (grenades). A.I. then adjusts aiming in order to hit enemy with the projectile according to the ideal (parabolic) ballistic curve. This is a horizontal speed component. | :*Ballistic projectile speed (ProjectileSpeed) - special prediction can be used if weapon is meant to fire relatively slow but gravity affected projectiles (grenades). A.I. then adjusts aiming in order to hit enemy with the projectile according to the ideal (parabolic) ballistic curve. This is a horizontal speed component. | ||
:*Ballistic projectile gravity (ProjectileGravity) - vertical gravity attraction for the projectile. | :*Ballistic projectile gravity (ProjectileGravity) - vertical gravity attraction for the projectile. | ||
:*Targeting direction (Direction) - Vector with three components (x, y, z) which gives orientation of a firingspread. When set to wrong values, firingspread will not cover area where the weapon shoots, but will be pointing in some other direction ( can even point backwards ^_^). Friendly advice: do not alter unless needed. | |||
:*Targeting origin (Origin) - Vector with three components (x, y, z) which tells A.I. where to fire according to enemy's pelvis position. When armed A.I. is in combat mode with the enemy and shoots him, the A.I. searches for pelvis (see [[TRIA]]) as the pelvis is the only bone recognized by A.I. system. For A.I., pelvis is a representation of a whole character. Now when A.I. fires at its enemy, the A.I. aims for pelvis. The vector described in this parameter tells A.I. where and how much to deviate from enemy's pelvis position. | |||
::So when the vector is set as (0, 0, -2), A.I. will aim and fire at enemy's pelvis position + two units above. That means A.I. will fire ABOVE the pelvis position. Here is described effect of setting "x,y,z" from SHOOTER's point of view. First to positive, then to neative value: | |||
::*x - deviate forward/backward (does not have much of an effect) | |||
::*y - deviate right/left | |||
::*z - deviate down/up (headshots, anyone?) | |||
'''Miscellaneous [[ONWC]] A.I. setup''' - there are a few more parameters in ONWC which affect A.I. behavior with the weapon. They are (xml tags in brackets): | |||
:*Minimal shooting distance (MinShootingDistance) - defines how close can enemy be to the armed shooting A.I. character. If enemy comes closer than this distance, A.I. stops shooting and tends to move back a bit (vector type of movement, see [[Tricks behind Oni A.I.#Pathfinding and movement - "I think I will consult a map for a while..."|HERE]]) until the distance is again equal or greater than Minimal shooting distance. Then A.I. opens fire again. To witness the effect, see some A.I. operating an SBG when its enemy is close to it. | |||
::'''IMPORTANT''' - for some unknown reason, value from this field is '''divided by 2'''. So when 100 is set, ingame A.I. starts backing when its enemy is 50 units close to it. | |||
:*Maximal shooting distance (MaxShootingDistance) - contrary to the parameter described above, this limits how far can enemy be till the A.I. stops shooting and tends to come closer. See some A.I. character shooting with w2_sap at distant enemy. | |||
:*Fight timer (FightTimer) - a bit similar to timer-based BSL command '''chr_dontaim'''. Defines in frames for how long should A.I. switch from a weapon varient (shooting) to a melee varient (hand to hand combat) if this firing mode was used (don't forget, weapon can has two firing modes) and certain conditions were met. See below for ''KnockdownSwitcher'' and ''StunSwitcher'' flags explanations. | |||
:*basic parameters of a weapon (pistol or rifle type, type of ammunition etc.) can be set as a various flags in [[ONWC]] flags field (<Flags> in xml). These three flags from them affect A.I. behavior (xml tags in brackets): | |||
:**NoHolster - apart from holster and reload disabled, this flag also makes A.I. character ignore this weapon on the ground unless the A.I. character has set Superammo flag (InfiniteAmmo in xml) in its [[CHAR]] profile. If A.I. character is given the weapon it will fire it, but if the weapon is lying on the ground and A.I. character does not have superammo flag, this A.I. character will never pick it up. | |||
:**Stun switcher (StunSwitcher) - if the enemy is within armed A.I. character's shooting distance and was knockdowned, stunned or blownupped, the A.I. character switches to a melee for a time specified in the weapon's Fight timer (see above). The flag was designed specially for w6_vdg weapon. | |||
:**Knockdown switcher (KnockdownSwitcher) - Similar to Stun switcher, but only knockdown or blownup makes A.I. switch to melee. Tailored for w4_psm, probably to avoid A.I. abuse of an unfair advantage the w4_psm weapon grants (enemy cannot get up as long as she/he is shot). | |||
Modding hints: - this section's topic has plenty of modding possiblities. Still, modders should be aware fo a few things: | |||
:*Don't set too | |||
:*Unless really needed, do NOT alter [[ONCC]] prediction parameters. Bungie set them quite reasonably and if they are messed, A.I. character loses the ability of prediction. | |||
:*Weapon coefficients in [[ONCC]] |
edits