Add LupGenericInteraction and Robot Citizen script

This commit is contained in:
Aaron Kimbre
2022-09-02 21:52:57 -05:00
parent 14d4bf3cc5
commit 67ec10ac0d
6 changed files with 61 additions and 1 deletions

View File

@@ -290,6 +290,8 @@
// WBL scripts
#include "WblGenericZone.h"
#include "LupGenericInteract.h"
#include "WblRobotCitizen.h"
//Big bad global bc this is a namespace and not a class:
InvalidScript* invalidToReturn = new InvalidScript();
@@ -847,6 +849,10 @@ CppScripts::Script* CppScripts::GetScript(Entity* parent, const std::string& scr
// WBL
else if (scriptName == "scripts\\zone\\LUPs\\WBL_generic_zone.lua")
script = new WblGenericZone();
else if (scriptName == "scripts\\ai\\WILD\\L_LUP_generic_interact.lua")
script = new LupGenericInteract();
else if (scriptName.rfind("scripts\\zone\\LUPs\\RobotCity Intro\\WBL_RCIntro_RobotCitizen", 0) == 0)
script = new WblRobotCitizen();
//Ignore these scripts:
else if (scriptName == "scripts\\02_server\\Enemy\\General\\L_SUSPEND_LUA_AI.lua")
@@ -855,7 +861,7 @@ CppScripts::Script* CppScripts::GetScript(Entity* parent, const std::string& scr
script = invalidToReturn;
else if (script == invalidToReturn) {
if (scriptName.length() > 0)
Game::logger->LogDebug("CppScripts", "Attempted to load CppScript for '%s', but returned InvalidScript.", scriptName.c_str());
Game::logger->Log("CppScripts", "Lot %i attempted to load CppScript for '%s', but returned InvalidScript.", parent->GetLOT(), scriptName.c_str());
// information not really needed for sys admins but is for developers
script = invalidToReturn;