Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Nov 27, 2017, 4:38:50 PM (7 years ago)
Author:
kohlia
Message:

Pawn killing works too now

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/ScriptableController_HS17/src/orxonox/items/ShipPart.cc

    r11099 r11606  
    4242#include "items/PartDestructionEvent.h"
    4343#include "chat/ChatManager.h"
     44#include "Level.h"
     45#include "scriptablecontroller/scriptable_controller.h"
    4446
    4547
     
    215217            }
    216218        }
     219
     220        // This is a bit hacky, but it takes away damage control from the pawn, so it has to handle
     221        // that as well.
     222        this->getLevel()->getScriptableController()->pawnHit(parent_, originator, parent_->getHealth(), parent_->getShieldHealth());
     223
    217224        if (this->health_ < 0)
    218225            this->death();
Note: See TracChangeset for help on using the changeset viewer.