|
|
|
@ -2418,6 +2418,7 @@ class CAHTarget : public IActionHandler
|
|
|
|
|
ucstring entityName;
|
|
|
|
|
entityName.fromUtf8 (getParam (Params, "entity"));
|
|
|
|
|
bool preferCompleteMatch = (getParam (Params, "prefer_complete_match") != "0");
|
|
|
|
|
bool quiet = (getParam (Params, "quiet") == "true");
|
|
|
|
|
|
|
|
|
|
if (!entityName.empty())
|
|
|
|
|
{
|
|
|
|
@ -2434,6 +2435,12 @@ class CAHTarget : public IActionHandler
|
|
|
|
|
entity = EntitiesMngr.getEntityByName (entityName, false, false);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (entity == NULL)
|
|
|
|
|
{
|
|
|
|
|
//Get the entity with a sheetName
|
|
|
|
|
entity = EntitiesMngr.getEntityBySheetName(entityName.toUtf8());
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (entity)
|
|
|
|
|
{
|
|
|
|
|
CCharacterCL *character = dynamic_cast<CCharacterCL*>(entity);
|
|
|
|
@ -2457,6 +2464,7 @@ class CAHTarget : public IActionHandler
|
|
|
|
|
// to avoid campfire selection exploit #316
|
|
|
|
|
nldebug("is not prop selectable");
|
|
|
|
|
CInterfaceManager *pIM= CInterfaceManager::getInstance();
|
|
|
|
|
if(!quiet)
|
|
|
|
|
pIM->displaySystemInfo(CI18N::get("uiTargetErrorCmd"));
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
@ -2467,6 +2475,7 @@ class CAHTarget : public IActionHandler
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
CInterfaceManager *pIM= CInterfaceManager::getInstance();
|
|
|
|
|
if(!quiet)
|
|
|
|
|
pIM->displaySystemInfo(CI18N::get("uiTargetErrorCmd"));
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|