Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Oct 13, 2009, 5:05:17 PM (15 years ago)
Author:
dafrick
Message:

Hopefully merged trunk successfully into pickup branch.

Location:
code/branches/pickup
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/branches/pickup

  • code/branches/pickup/src/orxonox/infos/HumanPlayer.cc

    r5781 r5935  
    6464        {
    6565            if (this->humanHud_)
    66                 delete this->humanHud_;
     66                this->humanHud_->destroy();
    6767
    6868            if (this->gametypeHud_)
    69                 delete this->gametypeHud_;
     69                this->gametypeHud_->destroy();
    7070        }
    7171    }
     
    116116
    117117            if (!GameMode::isMaster())
    118                 this->setObjectMode(ObjectDirection::Bidirectional);
     118                this->setSyncMode(ObjectDirection::Bidirectional);
    119119            else
    120120                this->setName(this->nick_);
     
    162162
    163163        if (this->isInitialized() && this->isLocalPlayer())
    164             if (this->getGametype()->getHUDTemplate() != "")
     164        {
     165            if (this->getGametype() && this->getGametype()->getHUDTemplate() != "")
    165166                this->setGametypeHUDTemplate(this->getGametype()->getHUDTemplate());
     167            else
     168                this->setGametypeHUDTemplate("");
     169        }
    166170    }
    167171
     
    170174        if (this->humanHud_)
    171175        {
    172             delete this->humanHud_;
     176            this->humanHud_->destroy();
    173177            this->humanHud_ = 0;
    174178        }
    175179
    176         if (this->isLocalPlayer() && this->humanHudTemplate_ != "")
     180        if (this->isLocalPlayer() && this->humanHudTemplate_ != "" && GameMode::showsGraphics())
    177181        {
    178182            this->humanHud_ = new OverlayGroup(this);
     
    186190        if (this->gametypeHud_)
    187191        {
    188             delete this->gametypeHud_;
     192            this->gametypeHud_->destroy();
    189193            this->gametypeHud_ = 0;
    190194        }
Note: See TracChangeset for help on using the changeset viewer.