/TGame/TCommon/Gene/Status/GEInvisibility.cpp
http://awoe.googlecode.com/ · C++ · 43 lines · 29 code · 7 blank · 7 comment · 1 complexity · 0be655646d3f2dae7c7a3a3e99e1c4d2 MD5 · raw file
- ///////////////////////////////////////////////////////////////////////////////////////////////////
- // GEInvisibility.cpp
- // 2010?1?20?
- // Copyright ?2007, 2010, 8DWorld, Inc. All rights reserved.
- //
- //
- ///////////////////////////////////////////////////////////////////////////////////////////////////
-
-
-
- #include "stdafx.h"
- #include "GEInvisibility.h"
- #include "Entity/EntityIf.h"
- #include "Combat/CombatSysIf.h"
- #include "Gene/GeneCreateDataIf.h"
-
-
- GEInvisibility::GEInvisibility()
- {
- }
- bool
- GEInvisibility::onAttach()
- {
- if (__super::onAttach())
- {
- m_wpHost->setVisible(400);
- m_wpCombat->clrFlg(Combat::FIdx_CanBeTargeted);
- return true;
- }
- else
- {
- return false;
- }
- }
-
- bool
- GEInvisibility::onDetach()
- {
- m_wpCombat->setFlg(Combat::FIdx_CanBeTargeted);
- m_wpHost->setVisible(1000);
-
- return __super::onDetach();
- }