mirror of
https://github.com/glest/glest-source.git
synced 2025-08-30 11:19:48 +02:00
Attack commands can now be queued
This commit is contained in:
@@ -726,7 +726,7 @@ namespace Game {
|
||||
|
||||
if (SystemFlags::getSystemSettingType(SystemFlags::debugPerformance).enabled && chrono.getMillis() > 0) SystemFlags::OutputDebug(SystemFlags::debugPerformance, "In [%s::%s Line: %d] took msecs: %lld\n", __FILE__, __FUNCTION__, __LINE__, chrono.getMillis());
|
||||
|
||||
if ((command->getUnit() == NULL || !(command->getUnit()->isAlive())) && unit->getCommandSize() > 1) {
|
||||
/*if ((command->getUnit() == NULL || !(command->getUnit()->isAlive())) && unit->getCommandSize() > 1) {
|
||||
|
||||
if (frameIndex < 0) {
|
||||
unit->finishCommand(); // all queued "ground attacks" are skipped if somthing else is queued after them.
|
||||
@@ -738,7 +738,7 @@ namespace Game {
|
||||
}
|
||||
}
|
||||
return;
|
||||
}
|
||||
}*/
|
||||
|
||||
//if found
|
||||
//if(frameIndex < 0) {
|
||||
|
@@ -157,7 +157,7 @@ namespace Game {
|
||||
bool attackableOnSight(Unit *unit, Unit **enemyPtr, const AttackSkillType *ast, bool evalMode = false);
|
||||
bool attackableOnRange(Unit *unit, Unit **enemyPtr, const AttackSkillType *ast, bool evalMode = false);
|
||||
bool unitOnRange(Unit *unit, int range, Unit **enemyPtr, const AttackSkillType *ast, bool evalMode = false);
|
||||
void enemiesAtDistance(const Unit *unit, const Unit *priorityUnit, int distance, vector<Unit*> &enemies);
|
||||
//void enemiesAtDistance(const Unit *unit, const Unit *priorityUnit, int distance, vector<Unit*> &enemies);
|
||||
|
||||
void spawn(Unit *unit, string spawnUnit, int spawnUnitcount, int healthMin, int healthMax, int probability);
|
||||
void spawnAttack(Unit *unit, string spawnUnit, int spawnUnitcount, int healthMin, int healthMax, int probability, bool spawnUnitAtTarget, Vec2i targetPos = Vec2i(-10, -10));
|
||||
|
Reference in New Issue
Block a user