Hi, my friends!
I have a problem: how can I make the AI (soldiers, snipers etc) shot from far far distances?
(or how can I increase the shot distance of the AI soldiers?)
I changed the codes of weapon's ODFs, but this did not work (its a rifle, not a sniper rifle):
MinRange = "0"
OptimalRange = "1000"
MaxRange = "1200"
LockOnRange = "1100.0"
LockTime = "0.4"
LockOnAngle = "1.0"
Please, someone help me (and sorry for the terrible english).
If you want to change the behaviour of the class itself, try to put this line in your unit odf at "properties":
[Properties]
UnitType = "Scout"
then you have to put those values in your weapon's odf:
MinRange = "8"
OptimalRange = "64"
MaxRange = "128"
AIUseBubbleCircle = "1"
AIBubbleSizeMultiplier = "0.6"
LockOnRange = "0.0"
LockTime = "0.0"
LockOnAngle = "1.0"
In SWBF1 at least, I believe there is a limit - no matter how high you set the max range, the AI will not detect you at a certain point.
What i2bros posted is correct except that Scout part. Changing the class type to scout will encourage the units to sit and lay down instead of battling.
Quote from: Anthony_b on December 15, 2017, 10:46:40 AM
What i2bros posted is correct except that Scout part. Changing the class type to scout will encourage the units to sit and lay down instead of battling.
I know, I suggested it cause I thought he wanted to make a sniper class. Pardon
Quote from: i2Bros on December 15, 2017, 01:26:51 AM
If you want to change the behaviour of the class itself, try to put this line in your unit odf at "properties":
[Properties]
UnitType = "Scout"
then you have to put those values in your weapon's odf:
MinRange = "8"
OptimalRange = "64"
MaxRange = "128"
AIUseBubbleCircle = "1"
AIBubbleSizeMultiplier = "0.6"
LockOnRange = "0.0"
LockTime = "0.0"
LockOnAngle = "1.0"
Oh, thank you so much, I2Bros! I followed your suggestion and works fine!
I have more two questions: what is "AIUseBubbleCircle = 1" and "AIBubbleSizeMultiplier = 0.6"?
How this thing works?
Can I improve AI by putting and setting the "scanning range" and the "transmit range" in other unit's ODF (like the officers)?
For exemple:
"[GameObjectClass]
ClassParent = "rep_inf_default"
[Properties]
MaxHealth = 100.0
MaxSpeed = 7.0 // base forward speed
ScanningRange = 150.0
TransmitRange = 75.0
WEAPONSECTION = 1
WeaponName = "rep_weap_inf_DC-15AR_Rifle"
WeaponAmmo = 4
WEAPONSECTION = 2
WeaponName = "rep_weap_inf_thermaldetonator"
WeaponAmmo = 4
WeaponChannel = 1
WEAPONSECTION = 3
WeaponName = "rep_weap_award_rifle"
WeaponAmmo = 4
VOUnitType = 121"