Entity/AI

* store and display StringIds
 * unify storage of AI/Scripts for NPCs and Objects
 * store and display StringIds and AI/Scripts from individual spawns in
   mapper tooltip and infobox
This commit is contained in:
Sarjuuk 2025-12-29 19:23:00 +01:00
parent 9db943e8f4
commit 2b3b9de8bc
9 changed files with 124 additions and 24 deletions

View file

@ -723,18 +723,23 @@ trait spawnHelper
$info[4] = Lang::game('mode').implode(', ', $_);
}
if ($s['ScriptName'])
$info[5] = 'ScriptName'.Lang::main('colon').$s['ScriptName'];
if ($s['StringId'])
$info[6] = 'StringId'.Lang::main('colon').$s['StringId'];
if ($s['type'] == Type::AREATRIGGER)
{
// teleporter endpoint
if ($s['guid'] < 0)
{
$opts['type'] = 4;
$info[5] = 'Teleport Destination';
$info[7] = 'Teleport Destination';
}
else
{
$o = Util::O2Deg($this->getField('orientation'));
$info[5] = 'Orientation'.Lang::main('colon').$o[0].'° ('.$o[1].')';
$info[7] = 'Orientation'.Lang::main('colon').$o[0].'° ('.$o[1].')';
}
}