您当前的位置:首页 > IT编程 > C++
| C语言 | Java | VB | VC | python | Android | TensorFlow | C++ | oracle | 学术与代码 | cnn卷积神经网络 | gnn | 图像修复 | Keras | 数据集 | Neo4j | 自然语言处理 | 深度学习 | 医学CAD | 医学影像 | 超参数 | pointnet | pytorch | 异常检测 | Transformers | 情感分类 | 知识图谱 |

自学教程:C++ GetCreatureEntry函数代码示例

51自学网 2021-06-01 21:05:45
  C++
这篇教程C++ GetCreatureEntry函数代码示例写得很实用,希望能帮到您。

本文整理汇总了C++中GetCreatureEntry函数的典型用法代码示例。如果您正苦于以下问题:C++ GetCreatureEntry函数的具体用法?C++ GetCreatureEntry怎么用?C++ GetCreatureEntry使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。

在下文中一共展示了GetCreatureEntry函数的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: switch

bool Vehicle::CheckCustomCanEnter(){	switch (GetCreatureEntry())	{	case 56682: // Keg in Stormstout Brewery		return true;	case 46185: // Sanitron		return true;	}	return false;}
开发者ID:Mystiko,项目名称:MoPCore5.4.8,代码行数:12,


示例2: TC_LOG_ERROR

void Vehicle::InstallAccessory(uint32 entry, int8 seatId, bool minion, uint8 type, uint32 summonTime){    /// @Prevent adding accessories when vehicle is uninstalling. (Bad script in OnUninstall/OnRemovePassenger/PassengerBoarded hook.)    if (_status == STATUS_UNINSTALLING)    {        TC_LOG_ERROR("entities.vehicle", "Vehicle (%s, Entry: %u) attempts to install accessory (Entry: %u) on seat %d with STATUS_UNINSTALLING! "            "Check Uninstall/PassengerBoarded script hooks for errors.", _me->GetGUID().ToString().c_str(), GetCreatureEntry(), entry, (int32)seatId);        return;    }    TC_LOG_DEBUG("entities.vehicle", "Vehicle (%s, Entry %u): installing accessory (Entry: %u) on seat: %d",        _me->GetGUID().ToString().c_str(), GetCreatureEntry(), entry, (int32)seatId);    TempSummon* accessory = _me->SummonCreature(entry, *_me, TempSummonType(type), summonTime);    ASSERT(accessory);    if (minion)        accessory->AddUnitTypeMask(UNIT_MASK_ACCESSORY);    (void)_me->HandleSpellClick(accessory, seatId);    /// If for some reason adding accessory to vehicle fails it will unsummon in    /// @VehicleJoinEvent::Abort}
开发者ID:Mathias-Nolam,项目名称:wtfisthis,代码行数:24,


示例3: TC_LOG_DEBUG

void Vehicle::Reset(bool evading /*= false*/){    if (GetBase()->GetTypeId() != TYPEID_UNIT)        return;    TC_LOG_DEBUG(LOG_FILTER_VEHICLES, "Vehicle::Reset (Entry: %u, GuidLow: %u, DBGuid: %u)", GetCreatureEntry(), _me->GetGUIDLow(), _me->ToCreature()->GetDBTableGUIDLow());    ApplyAllImmunities();    InstallAllAccessories(evading);    sScriptMgr->OnReset(this);}
开发者ID:MICHAL53Q,项目名称:TrinityCore,代码行数:12,


示例4: GetCreatureEntry

void Vehicle::InstallAccessory(uint32 entry, int8 seatId, bool minion, uint8 type, uint32 summonTime){	/// @Prevent adding accessories when vehicle is uninstalling. (Bad script in OnUninstall/OnRemovePassenger/PassengerBoarded hook.)	if (_status == STATUS_UNINSTALLING)	{		sLog->outDebug(LOG_FILTER_VEHICLES, "Vehicle GuidLow: %u, Entry: %u attempts to install accessory Entry: %u on seat %d with STATUS_UNINSTALLING! "			"Check Uninstall/PassengerBoarded script hooks for errors.", _me->GetGUIDLow(), _me->GetEntry(), entry, (int32)seatId);		return;	}	sLog->outDebug(LOG_FILTER_VEHICLES, "Vehicle: Installing accessory entry %u on vehicle entry %u (seat:%i)", entry, GetCreatureEntry(), seatId);	if (Unit* passenger = GetPassenger(seatId))	{		// already installed		if (passenger->GetEntry() == entry)		{			ASSERT(passenger->GetTypeId() == TYPEID_UNIT);			if (_me->GetTypeId() == TYPEID_UNIT)			{				if (_me->ToCreature()->IsInEvadeMode() && passenger->ToCreature()->IsAIEnabled)					passenger->ToCreature()->AI()->EnterEvadeMode();				return;			}		}		else			passenger->ExitVehicle(); // this should not happen	}	if (TempSummon* accessory = _me->SummonCreature(entry, *_me, TempSummonType(type), summonTime))	{		if (minion)			accessory->AddUnitTypeMask(UNIT_MASK_ACCESSORY);		if (!_me->HandleSpellClick(accessory, seatId))		{			accessory->UnSummon();			return;		}		if (GetBase()->GetTypeId() == TYPEID_UNIT)			sScriptMgr->OnInstallAccessory(this, accessory);	}}
开发者ID:Mystiko,项目名称:MoPCore5.4.8,代码行数:43,


示例5: GetCreatureEntry

void Vehicle::InstallAccessory(uint32 entry, int8 seatId, bool minion, uint8 type, uint32 summonTime){    sLog->outDebug(LOG_FILTER_VEHICLES, "Vehicle: Installing accessory entry %u on vehicle entry %u (seat:%i)", entry, GetCreatureEntry(), seatId);    if(Unit* passenger = GetPassenger(seatId))    {        // already installed        if(passenger->GetEntry() == entry)        {            ASSERT(passenger->GetTypeId() == TYPEID_UNIT);            if(_me->GetTypeId() == TYPEID_UNIT)            {                if(_me->ToCreature()->IsInEvadeMode() && passenger->ToCreature()->IsAIEnabled)                    passenger->ToCreature()->AI()->EnterEvadeMode();                return;            }        }        else            passenger->ExitVehicle(); // this should not happen    }    if(TempSummon* accessory = _me->SummonCreature(entry, *_me, TempSummonType(type), summonTime))    {        if(minion)            accessory->AddUnitTypeMask(UNIT_MASK_ACCESSORY);        if(!_me->HandleSpellClick(accessory, seatId))        {            accessory->UnSummon();            return;        }        // This is not good, we have to send update twice        accessory->SendMovementFlagUpdate();        if(GetBase()->GetTypeId() == TYPEID_UNIT)            sScriptMgr->OnInstallAccessory(this, accessory);    }}
开发者ID:FreedomEmu,项目名称:FreedomEmu,代码行数:38,


示例6: GetCreatureEntry

void Vehicle::InstallAccessory(uint32 entry, int8 seatId, bool minion, uint8 type, uint32 summonTime){    sLog->outDebug(LOG_FILTER_VEHICLES, "Vehicle: Installing accessory entry %u on vehicle entry %u (seat:%i)", entry, GetCreatureEntry(), seatId);    if (Unit* passenger = GetPassenger(seatId))    {        // already installed        if (passenger->GetEntry() == entry)        {            ASSERT(passenger->GetTypeId() == TYPEID_UNIT);            if (_me->GetTypeId() == TYPEID_UNIT)            {                if (_me->ToCreature()->IsInEvadeMode() && passenger->ToCreature()->IsAIEnabled)                    passenger->ToCreature()->AI()->EnterEvadeMode();                return;            }        }        else            passenger->ExitVehicle(); // this should not happen    }    if (TempSummon* accessory = _me->SummonCreature(entry, *_me, TempSummonType(type), summonTime))    {        if (minion)            accessory->AddUnitTypeMask(UNIT_MASK_ACCESSORY);        if (!_me->HandleSpellClick(accessory, seatId))        {            accessory->UnSummon();            return;        }        // this cannot be checked instantly like this        // spellsystem is delaying everything to next update tick        //if (!accessory->IsOnVehicle(me))        //{        //    accessory->UnSummon();        //    return;         // Something went wrong in the spellsystem        //}        if (GetBase()->GetTypeId() == TYPEID_UNIT)            sScriptMgr->OnInstallAccessory(this, accessory);    }}
开发者ID:AtVirus,项目名称:SkyFireEMU,代码行数:43,


示例7: GetCreatureEntry

void Vehicle::Dismiss(){    if (GetBase()->GetTypeId() != TYPEID_UNIT)        return;    sLog->outDebug(LOG_FILTER_VEHICLES, "Vehicle::Dismiss Entry: %u, GuidLow %u, DBGuid: %u", GetCreatureEntry(), _me->GetGUIDLow(), _me->ToCreature()->GetDBTableGUIDLow());    Uninstall();    GetBase()->ToCreature()->DespawnOrUnsummon();}
开发者ID:Lhorath94,项目名称:DisintegrationCore,代码行数:9,


示例8: accessory

void Vehicle::InstallAccessory(uint32 entry, int8 seatId, bool minion, uint8 type, uint32 summonTime){    /// @Prevent adding accessories when vehicle is uninstalling. (Bad script in OnUninstall/OnRemovePassenger/PassengerBoarded hook.)    if (_status == STATUS_UNINSTALLING)    {        sLog->outError(LOG_FILTER_VEHICLES, "Vehicle (GuidLow: %u, DB GUID: %u, Entry: %u) attempts to install accessory (Entry: %u) on seat %i with STATUS_UNINSTALLING! "            "Check Uninstall/PassengerBoarded script hooks for errors.", _me->GetGUIDLow(),            (_me->GetTypeId() == TYPEID_UNIT ? _me->ToCreature()->GetDBTableGUIDLow() : _me->GetGUIDLow()), GetCreatureEntry(), entry, (int32)seatId);        return;    }    sLog->outDebug(LOG_FILTER_VEHICLES, "Vehicle (GuidLow: %u, DB Guid: %u, Entry %u): installing accessory (Entry: %u) on seat: %i",        _me->GetGUIDLow(), (_me->GetTypeId() == TYPEID_UNIT ? _me->ToCreature()->GetDBTableGUIDLow() : _me->GetGUIDLow()), GetCreatureEntry(),        entry, (int32)seatId);    TempSummon* accessory = _me->SummonCreature(entry, *_me, TempSummonType(type), summonTime);    ASSERT(accessory);    if (minion)        accessory->AddUnitTypeMask(UNIT_MASK_ACCESSORY);    (void)_me->HandleSpellClick(accessory, seatId);    /// If for some reason adding accessory to vehicle fails it will unsummon in    /// @VehicleJoinEvent::Abort}
开发者ID:Lhorath94,项目名称:DisintegrationCore,代码行数:26,


示例9: TC_LOG_DEBUG

void Vehicle::Reset(bool evading /*= false*/){    if (GetBase()->GetTypeId() != TYPEID_UNIT)        return;    TC_LOG_DEBUG("entities.vehicle", "Vehicle::Reset (Entry: %u, GuidLow: %u, DBGuid: %u)", GetCreatureEntry(), _me->GetGUID().GetCounter(), _me->ToCreature()->GetSpawnId());    ApplyAllImmunities();    if (GetBase()->IsAlive())        InstallAllAccessories(evading);    sScriptMgr->OnReset(this);}
开发者ID:Refuge89,项目名称:TrinityCore,代码行数:13,


示例10: TC_LOG_DEBUG

void Vehicle::Reset(bool evading /*= false*/){    if (GetBase()->GetTypeId() != TYPEID_UNIT)        return;    TC_LOG_DEBUG("entities.vehicle", "Vehicle::Reset (Entry: %u, %s, DBGuid: " UI64FMTD ")", GetCreatureEntry(), _me->GetGUID().ToString().c_str(), _me->ToCreature()->GetSpawnId());    ApplyAllImmunities();    InstallAllAccessories(evading);    sScriptMgr->OnReset(this);}
开发者ID:Mathias-Nolam,项目名称:wtfisthis,代码行数:12,



注:本文中的GetCreatureEntry函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


C++ GetCreatureInfo函数代码示例
C++ GetCreatePowers函数代码示例
万事OK自学网:51自学网_软件自学网_CAD自学网自学excel、自学PS、自学CAD、自学C语言、自学css3实例,是一个通过网络自主学习工作技能的自学平台,网友喜欢的软件自学网站。