Weapon_Notes

Cannon and Launcher weapons now support heat values:

HeatPerShot - fraction of the heat gauge added per shot (note that each shot in a salvo counts!)

HeatRecoverRate - amount that the heat gauge decreases per second

HeatThreshold - when a weapon overheats (gauge fills), the gauge must drop below this before it can fire again

Cannon and Launcher also do scatter differently:

PitchScatter - scatter angle along the pitch axis (up and down), in degrees

YawScatter - scatter angle along the yaw axis (left and right), in degrees

MaxScatter - sets both pitch and yaw scatter for compatibility, in the same goofy units that it used to use

Yet another new weapon property for your amusement:

TriggerSingle - select automatic fire (0) or single fire (1)

All ammo-using weapons now support heat, and not just Cannon and Launcher:

HeatPerShot - fraction of the heat gauge added per shot (note that each shot in a salvo counts!)

HeatRecoverRate - amount that the heat gauge decreases per second

HeatThreshold - when a weapon overheats (gauge fills), the gauge must drop below this before it can fire again

Two new goodies:

WeaponDetonator ("detonator"):

Its primary task is to dispense mines (though technically it can dispense other things), keep track of a number of laid mines, and trigger them with alternate fire.

OrdnanceName: entity type to dispense

Velocity: speed to throw the entity

ShotDelay: recovery time after firing

MaxPressedTime: time to charge up (0 to fire instantly)

MinStrength: scale velocity at zero charge

MaxStrength: scale velocity at full charge

MaxItems: number of mines out at once; the weapon will not fire when this number is reached

TriggerAll: trigger all mines at once (1), or one at a time (0)

EntityMine ("mine"):

GeometryName: model used for the mine

LifeSpan: maximum life time

Rebound: coefficient of restitution (like a grenade)

Friction: coefficient of friction (like a grenade)

ExplosionTrigger: explosion used when triggered

ExplosionExpire: explosion used when its lifespan expires

ExplosionDeath: explosion used when destroyed

TriggerContact: trigger when touched by an enemy

TriggerRadius: radius to search for enemies; the mine will trigger when an enemy inside this radius stops or moves away

SuppressRadius: radius to search for friendlies; the mine will not trigger when a friend is inside

Mines bounce off of units and vehicles, but will stick to buildings and terrain.

Unlike grenades, mines should not be thrown very fast relative to their size.

WeaponRemote ("remote"), based on WeaponDispenser:

OrdnanceName: object type to create

Velocity: ejection speed

ShotDelay: delay between shots

MaxPressedTime: charge-up time

MinStrength: velocity scale at minimum charge

MaxStrength: velocity scale at maximum charge

SwitchImmediately: 0 = require L1 press to enter remote, 1 = enter remote immediately on launch

Any controllable class (soldier, droid, flyer, hover, walker, turret):

PilotType: "none" = unpilotable, "self" = self-piloting, "vehicle" = pilot enters, "remote" = remote-controlled

The object spawned by WeaponRemote must be set to "remote" type.

More weapon properties for WeaponSections:

LockOnRange = <range>

TargetEnemy = <0 or 1>

TargetNeutral = <0 or 1>

TargetFriendly = <0 or 1>

TargetPerson = <0 or 1>

TargetAnimal = <0 or 1>

TargetDroid = <0 or 1>

TargetVehicle = <0 or 1>

TargetBuilding = <0 or 1>

Now you can precisely control what each weapon mode does.

I've noticed that the thrown grenade weapons (e.g. "all_weap_inf_grenadethermal.odf") have InitialSalvoDelay set to zero. Now that weapons actually read that value, the grenades are launching too early. The default is 0.3, but you might want to adjust it until the grenade leaves the character's hand at the right time.

Ordnance now supports different charge levels, making MaxPressedTime on weapons much more useful.

Just add a NEXTCHARGE = "<level>" property, and that will create a new ordnance charge state with all properties duplicated from the previous state. You can then override any or all of the properties, and the values will be linearly interpolated whenever possible. For example:

[Properties]

Damage = "5.0"

NEXTCHARGE = "0.5"

Damage = "25.0"

NEXTCHARGE = "0.8"

Damage = "50.0"

NEXTCHARGE = "1.0"

Damage = "100.0"

At a strength value of 0.0 (button tapped), the ordnance will inflict only 5 points of damage. Charging from 0.0 to 0.5, damage linearly increases from 5 to 25. Charging from 0.5 to 0.8, damage linearly increases from 25 to 50. Charging from 0.8 and 1.0, damage linearly increases from 50 to 100.

I've already modified the grenades to use this mechanism instead of MinStrength and MaxStrength, so you can use those as reference.

I've added a new "destruct" weapon type for self-destructing droids.

InitialSalvoDelay - delay until the explosion triggers

ExplosionClass - explosion created after the delay

Fir Launcher

New weapon properties:

LockOnAngle - replaces AutoAimSize and is measured in degrees

LockOffAngle - provides a "sticky" lock cone (appears as eight tickmarks, requires an art reticule)

The Haywire grenade type sticks to vehicles and disables them for a specified time when it goes off.

[OrdnanceClass]

ClassLabel = "haywire"

...

[Properties]

<usual grenade stuff>

DisableTime = <time>

Game objects now support scanners:

ScanningRange - range within which enemy units show up on the map display

TransmitRange - range within which friendly units receive scan data

(These only affect the map display)

You can now specify an item limit for all dispenser weapons, not just remote detonators. Additional dispensed items replace the oldest items to maintain the limit. This limit also persists between lives, so if you dispense 3 mines, die, and respawn, those three mines still count against your limit. On the plus side, you can take control of your remote detonated items when you return.

[Properties]

...

WEAPONSECTION = ...

MaxItems = <limit>

...

WEAPONSECTION = ...

MaxItems = <limit>

...

Setting MaxItems to zero disables the feature for that weapon mode. That doesn't work well for remote detonators, so don't do it. :)

Cannon and Launcher type weapons now support shot patterns. You can have as many pattern points as you want, and the weapon will cycle through the list, one per shot.

ShotPatternCount = <count>

ShotPatternPitchYaw = "<pitch> <yaw>"

For example, for a bowcaster shot with a five-way spread:

ShotPatternCount = 5

ShotPatternPitchYaw = "0.0 -4.0"

ShotPatternPitchYaw = "0.0 -2.0"

ShotPatternPitchYaw = "0.0 0.0"

ShotPatternPitchYaw = "0.0 2.0"

ShotPatternPitchYaw = "0.0 4.0"

You can make launchers lock only while the trigger is held by setting MaxPressedTime and leaving LockTime at zero. If you have a target, but aren't holding the trigger, you'll get a white reticule and lock-on diamond.

(I've noticed that AT-STs have enough target points that the lock tends to jump between them unless you aim carefully.)

You can now specify which types of objects sticky ordnance sticks to. By default, it sticks to everything.

StickPerson

StickAnimal

StickDroid

StickVehicle

StickBuilding

StickBuildingDead

StickBuildingUnbuilt

StickTerrain

I added new target and stick functionality to make setting that stuff up easier:

TargetAll = <0 for nothing, 1 for everything>

StickAll = <0 for nothing, 1 for everything>

You can then change specific target and stick types afterwards. This just avoids all the Target<whatever> = 0 everythwere.

Also, recoil spread works differently now. I added code to make sure existing values work fine, but here's the new thing:

SpreadPerShot = <spread per shot, in degrees>

SpreadRecoveryRate = <spread per second, in degrees>

SpreadThreshold = <amount of spread to "ignore", in degrees>

SpreadLimit = <maximum spread, in degrees>

The old values still work, but weapons with low SpreadRecovery (e.g. pistol) will act somewhat weird.

FYI: SpreadPerShot actually applies per group of shots, so if you have ShotsPerSalvo larger than one, the kick doesn't apply until the next group in the salvo. I can do the same thing for ammo and heat if you want. At some point I'm going to get the weapon charge state stuff working. :)

In case you're wondering what SpreadThreshold is for, it lets you give the weapon a little leeway before the spread starts to kick in. That's what I meant by "ignore".

I've just checked in a change to the way AI-controlled stationary turrets will work. Previously, the soldier would randomly turn the turret around, often resulting in it looking in a stupid direction, or facing into a wall. The fix is to have the turret only look in the original direction (that you set up in the world editor).

If shot at, then the soldier will turn the turret around to find the danger.

Ideally, we should extend the world editor to allow us to specify some angular range that the turret can look around in..

John

AI units will now lay mines in minefields that you can place in the editor. Make sure you've got latest data, then add some minefields to your maps. The minefields are hints: they need the "metanode" button selecting, and then enter a radius for the size of the minefield. AI will lay mines 3 meters apart. You�re probably best off laying a series of small minefields (say with a radius of 5m). If you lay a huge minefield, the AI will try to fill it in, so they could end up laying dozens of mines there.

AI units will not lay mines in minefields that contain enemy mines.

Also, you can associate a minefield with a Command Post. For now, this will only allow AI units whose team owns that Command Post to lay mines there. Of course, you do not have to associate a minefield with a CP, in which case any AI unit can lay mines there.

I've added two new parameters to weapon odfs:

ZoomTurnDivisorMin

ZoomTurnDivisorMax

They go hand in hand with the ZoomMin and ZoomMax variables. Basically, the TurnDivisorMin is used when you're on the minimum zoom, and the max is used when you're on the max zoom. The amount of the Divisor is how much the turnrate gets divided by, for example if TurnDivisorMin was 4, then you'd turn 4 times slower when zoomed in the minimum amount, 8 and it would go 8 times slower and so on.

These values MUST come after ZoomMin and ZoomMax in the ODF file, and default to the same value as ZoomMin and ZoomMax if they aren't set in the file.

We now have hit locations on soldiers and vehicles.

A headshot on a soldier makes damage x 3.

This is at the moment hardcoded, let me know if you need to specify it per soldier.

A vehicle/flyer/walker/turret can specify a multiplier for a specific collision body.

Look in the atst odf for an example, temporary I put in a multiplier of 1.5 for a hit in the head.

HitLocation = "p_head 1.5"

When a bullet hits a body that has a damage multiplier greater then 1.0 it displays an extra flash.

Its "headshot.fx" if anyone is interested in playing with it (in common). Same effect for vehicles and soldiers.

For a vehicle, the multiplier could be below 1.0, reducing the damage on that body.

So find body part that you want to add multipliers to or ask an artist to add extra, and Have fun!