MegaGlest Forum
MegaGlest => Bug reports => Closed bug reports => Topic started by: Ishmaru on 1 December 2013, 22:58:42
-
Something I've noticed for a while is that when a cpu player produces large (size 3+) units, it is very rare for them to be included when they launch their massive attacks.
I used to feel as though this was due to crowding at the base and poor pathfinding. However, after playing with the MinBuildSpacing Ai Behavior I believe this is not the reason.
Even with ample space these units still remain at base while the rest of the army charges at the enemy.
I'm wondering why that is? Has anyone else encountered this problem?
Computer Info:
Laptop Windows 7, 8 gigs ram, Nvidia Geforce card, Intel I7
-
What kind of attack has this big unit and which other skills does it have ? All this affects the decision if this unit is part of a big attack or not. PLease show us the xml file.
-
Only has one attack skill, but here is xml:
?xml version="1.0" standalone="no"?>
<unit>
<parameters>
<size value="3"/>
<height value="3"/>
<max-hp value="2400" regeneration="6"/>
<max-ep value="0" regeneration="1"/>
<armor value="150"/>
<armor-type value="hard"/>
<sight value="10"/>
<time value="60"/>
<multi-selection value="true"/>
<cellmap value="false"/>
<levels>
<level name="taste_blood" kills="10"/>
<level name="carnivore" kills="30"/>
<level name="ptreditor" kills="60"/>
</levels>
<fields>
<field value="land"/>
</fields>
<properties>
<property value="rotated_climb"/>
</properties>
<light enabled="false"/>
<unit-requirements>
</unit-requirements>
<upgrade-requirements/>
<resource-requirements>
<resource name="organic" amount="600"/>
<resource name="housing" amount="4" />
</resource-requirements>
<resources-stored>
</resources-stored>
<image path="images/swordman.bmp"/>
<image-cancel path="images/swordman_attack.bmp"/>
<meeting-point value="false"/>
<selection-sounds enabled="true">
<sound path="sounds/sel1.wav"/>
<sound path="sounds/sel2.wav"/>
<sound path="sounds/sel3.wav"/>
</selection-sounds>
<command-sounds enabled="true">
<sound path="sounds/sel1.wav"/>
<sound path="sounds/sel2.wav"/>
<sound path="sounds/sel3.wav"/>
</command-sounds>
</parameters>
<skills>
<skill>
<type value="stop"/>
<name value="stop_skill"/>
<ep-cost value="0"/>
<speed value="1000"/>
<anim-speed value="45"/>
<animation path="models/vore_stand.g3d"/>
<sound enabled="false"/>
</skill>
<skill>
<type value="move"/>
<name value="move_skill"/>
<ep-cost value="0"/>
<speed value="180"/>
<anim-speed value="100"/>
<animation path="models/vore_run.g3d"/>
<sound enabled="false"/>
</skill>
<skill>
<type value="be_built" />
<name value="be_built_skill"/>
<ep-cost value="0" />
<speed value="300" />
<anim-speed value="300" />
<animation path="models/vore_run.g3d" />
<sound enabled="false" />
</skill>
<skill>
<type value="move"/>
<name value="charge_skill"/>
<ep-cost value="0"/>
<speed value="180"/>
<anim-speed value="100"/>
<animation path="models/vore_run.g3d"/>
<sound enabled="false"/>
</skill>
<skill>
<type value="attack"/>
<name value="attack_skill"/>
<ep-cost value="0"/>
<speed value="100"/>
<anim-speed value="50"/>
<animation path="models/vore_eat.g3d"/>
<sound enabled="true" start-time="0.25">
<sound-file path="sounds/attack2.wav"/>
</sound>
<attack-strenght value="700"/>
<attack-var value="200"/>
<attack-range value="1"/>
<attack-type value="eat"/>
<attack-fields>
<field value="land"/>
</attack-fields>
<attack-start-time value="0.25"/>
<projectile value="false"/>
<splash value="true">
<radius value="0"/>
<damage-all value="false"/>
<particle value="false"/>
</splash>
</skill>
<skill>
<type value="die"/>
<name value="die_skill"/>
<ep-cost value="0"/>
<speed value="60"/>
<anim-speed value="60"/>
<animation path="models/vore_stand.g3d"/>
<particles value="true" start-time="0.0" end-time="0.1">
<particle-file path="splat.xml"/>
</particles>
<sound enabled="true" start-time="0">
<sound-file path="sounds/die1.ogg"/>
<sound-file path="sounds/die2.wav"/>
<sound-file path="sounds/die3.ogg"/>
</sound>
<fade value="true"/>
</skill>
<skill>
<type value="harvest"/>
<name value="mine_skill"/>
<ep-cost value="0"/>
<speed value="100"/>
<anim-speed value="50"/>
<animation path="models/vore_eat.g3d"/>
<sound enabled="true" start-time="0.5">
<sound-file path="sounds/attack2.wav"/>
</sound>
</skill>
<skill>
<type value="build"/>
<name value="build_skill"/>
<ep-cost value="0"/>
<speed value="225"/>
<anim-speed value="90"/>
<animation path="models/vore_eat.g3d"/>
<sound enabled="true" start-time="0.5">
</sound>
</skill>
</skills>
<commands>
<command>
<type value="stop"/>
<name value="stop"/>
<image path="images/swordman_attack.bmp"/>
<unit-requirements/>
<upgrade-requirements/>
<stop-skill value="stop_skill"/>
</command>
<command>
<type value="move"/>
<name value="move"/>
<image path="images/swordman_attack.bmp"/>
<unit-requirements/>
<upgrade-requirements/>
<move-skill value="move_skill"/>
</command>
<command>
<type value="attack"/>
<name value="devour"/>
<image path="images/swordman_attack.bmp"/>
<unit-requirements/>
<upgrade-requirements/>
<move-skill value="charge_skill"/>
<attack-skill value="attack_skill"/>
</command>
</commands>
</unit>
-
The reason is, it has a mine skill and a build skill. By this it is counted as a worker and is usually not send to fight. Compare this to the intiates of magic or the persian worker. both are not used to attack because they have "worker skills".
-
Actually they do attack when required, i think i had made a change a long time ago for that.
-
To me, this brings up three questions:
Which version is Ishmaru testing on?
Does this unit behave the same if it's size 1?
Should an option be added to the unit XML which, if set, makes a "worker" unit which also has an attack skill attack like any other unit. (And would this involve giving up harvesting to attack?)
-
The code already knows about workers that harvest AND attack. These units will attack when enemies are around.
-
The reason is, it has a mine skill and a build skill. By this it is counted as a worker and is usually not send to fight. Compare this to the intiates of magic or the persian worker. both are not used to attack because they have "worker skills".
you were correct titi that was the issue thanks!
softcoder: Yes you set it so that harvest units can attack. however it's dependant on weather or not the minimum workers harvesting is met. which explains why this unit rarely attacked instead of never.