mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-07-24 17:13:08 +00:00
#Bar borders and angle penalty
-Changes to notifications. They take different parameters now-see template_entity_script.js. You can choose to destroy the notifiers yourself in the script (useful for idle) -Added "idle" event with registerIdle and registerDamage to assist with the angle penalty. -Bar border stuff -Angle penalty is set up but untested-it just needs to use this.getAttackDirections() to find the number of directions the entity is being attacked from. The penalty is specified in template_unit There is a problem when the game exits-it attempts to destroy the notifiers in entity.cpp's constructor, where it calls DestroyAllNotifiers(). The problem is that the notifiers don't exist any longer because they've been destroyed. I would fix it but I'm leaving for vacation (Jason told me it was OK to comitt). Hope it isn't too much of a problem. This was SVN commit r3732.
This commit is contained in:
@@ -379,7 +379,7 @@ bool CEntity::processContactActionNoPathing( CEntityOrder* current, size_t times
|
||||
if(!DispatchEvent( contactEvent ))
|
||||
{
|
||||
// Cancel current order
|
||||
m_orderQueue.pop_front();
|
||||
popOrder();
|
||||
m_isRunning = false;
|
||||
m_shouldRun = false;
|
||||
m_actor->SetEntitySelection( L"idle" );
|
||||
@@ -406,7 +406,7 @@ bool CEntity::processContactActionNoPathing( CEntityOrder* current, size_t times
|
||||
//TODO: eventually when stances/formations are implemented, if applicable (e.g. not
|
||||
//heal or if defensive stance), the unit should expand and continue the order.
|
||||
|
||||
m_orderQueue.pop_front();
|
||||
popOrder();
|
||||
m_isRunning = false;
|
||||
m_shouldRun = false;
|
||||
return( false );
|
||||
|
||||
Reference in New Issue
Block a user