summaryrefslogtreecommitdiff
path: root/src/script
diff options
context:
space:
mode:
Diffstat (limited to 'src/script')
-rw-r--r--src/script/api/squirrel_export.awk6
-rw-r--r--src/script/api/squirrel_export.vbs6
-rw-r--r--src/script/api/template/template_accounting.hpp.sq2
-rw-r--r--src/script/api/template/template_admin.hpp.sq2
-rw-r--r--src/script/api/template/template_airport.hpp.sq2
-rw-r--r--src/script/api/template/template_base.hpp.sq2
-rw-r--r--src/script/api/template/template_basestation.hpp.sq2
-rw-r--r--src/script/api/template/template_bridge.hpp.sq2
-rw-r--r--src/script/api/template/template_bridgelist.hpp.sq4
-rw-r--r--src/script/api/template/template_cargo.hpp.sq2
-rw-r--r--src/script/api/template/template_cargolist.hpp.sq8
-rw-r--r--src/script/api/template/template_cargomonitor.hpp.sq2
-rw-r--r--src/script/api/template/template_client.hpp.sq2
-rw-r--r--src/script/api/template/template_clientlist.hpp.sq4
-rw-r--r--src/script/api/template/template_company.hpp.sq2
-rw-r--r--src/script/api/template/template_companymode.hpp.sq2
-rw-r--r--src/script/api/template/template_date.hpp.sq2
-rw-r--r--src/script/api/template/template_depotlist.hpp.sq2
-rw-r--r--src/script/api/template/template_engine.hpp.sq2
-rw-r--r--src/script/api/template/template_enginelist.hpp.sq2
-rw-r--r--src/script/api/template/template_error.hpp.sq2
-rw-r--r--src/script/api/template/template_event.hpp.sq4
-rw-r--r--src/script/api/template/template_event_types.hpp.sq56
-rw-r--r--src/script/api/template/template_execmode.hpp.sq2
-rw-r--r--src/script/api/template/template_game.hpp.sq2
-rw-r--r--src/script/api/template/template_gamesettings.hpp.sq2
-rw-r--r--src/script/api/template/template_goal.hpp.sq2
-rw-r--r--src/script/api/template/template_group.hpp.sq2
-rw-r--r--src/script/api/template/template_grouplist.hpp.sq2
-rw-r--r--src/script/api/template/template_industry.hpp.sq2
-rw-r--r--src/script/api/template/template_industrylist.hpp.sq6
-rw-r--r--src/script/api/template/template_industrytype.hpp.sq2
-rw-r--r--src/script/api/template/template_industrytypelist.hpp.sq2
-rw-r--r--src/script/api/template/template_infrastructure.hpp.sq2
-rw-r--r--src/script/api/template/template_list.hpp.sq2
-rw-r--r--src/script/api/template/template_log.hpp.sq2
-rw-r--r--src/script/api/template/template_map.hpp.sq2
-rw-r--r--src/script/api/template/template_marine.hpp.sq2
-rw-r--r--src/script/api/template/template_news.hpp.sq2
-rw-r--r--src/script/api/template/template_order.hpp.sq2
-rw-r--r--src/script/api/template/template_rail.hpp.sq2
-rw-r--r--src/script/api/template/template_railtypelist.hpp.sq2
-rw-r--r--src/script/api/template/template_road.hpp.sq2
-rw-r--r--src/script/api/template/template_sign.hpp.sq2
-rw-r--r--src/script/api/template/template_signlist.hpp.sq2
-rw-r--r--src/script/api/template/template_station.hpp.sq2
-rw-r--r--src/script/api/template/template_stationlist.hpp.sq26
-rw-r--r--src/script/api/template/template_story_page.hpp.sq2
-rw-r--r--src/script/api/template/template_storypageelementlist.hpp.sq2
-rw-r--r--src/script/api/template/template_storypagelist.hpp.sq2
-rw-r--r--src/script/api/template/template_subsidy.hpp.sq2
-rw-r--r--src/script/api/template/template_subsidylist.hpp.sq2
-rw-r--r--src/script/api/template/template_testmode.hpp.sq2
-rw-r--r--src/script/api/template/template_text.hpp.sq2
-rw-r--r--src/script/api/template/template_tile.hpp.sq2
-rw-r--r--src/script/api/template/template_tilelist.hpp.sq8
-rw-r--r--src/script/api/template/template_town.hpp.sq2
-rw-r--r--src/script/api/template/template_townlist.hpp.sq4
-rw-r--r--src/script/api/template/template_tunnel.hpp.sq2
-rw-r--r--src/script/api/template/template_vehicle.hpp.sq2
-rw-r--r--src/script/api/template/template_vehiclelist.hpp.sq12
-rw-r--r--src/script/api/template/template_viewport.hpp.sq2
-rw-r--r--src/script/api/template/template_waypoint.hpp.sq2
-rw-r--r--src/script/api/template/template_waypointlist.hpp.sq4
-rw-r--r--src/script/api/template/template_window.hpp.sq2
65 files changed, 126 insertions, 126 deletions
diff --git a/src/script/api/squirrel_export.awk b/src/script/api/squirrel_export.awk
index ef0a74c8d..a2782721c 100644
--- a/src/script/api/squirrel_export.awk
+++ b/src/script/api/squirrel_export.awk
@@ -34,7 +34,7 @@ function dump_class_templates(name)
print " template <> inline const " name " *GetParam(ForceType<const " name " *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (" name " *)instance; }" CR
print " template <> inline const " name " &GetParam(ForceType<const " name " &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(" name " *)instance; }" CR
if (name == "ScriptEvent") {
- print " template <> inline int Return<" name " *>(HSQUIRRELVM vm, " name " *res) { if (res == NULL) { sq_pushnull(vm); return 1; } Squirrel::CreateClassInstanceVM(vm, \"" realname "\", res, NULL, DefSQDestructorCallback<" name ">, true); return 1; }" CR
+ print " template <> inline int Return<" name " *>(HSQUIRRELVM vm, " name " *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } Squirrel::CreateClassInstanceVM(vm, \"" realname "\", res, nullptr, DefSQDestructorCallback<" name ">, true); return 1; }" CR
} else if (name == "ScriptText") {
print "" CR
print " template <> inline Text *GetParam(ForceType<Text *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) {" CR
@@ -44,10 +44,10 @@ function dump_class_templates(name)
print " if (sq_gettype(vm, index) == OT_STRING) {" CR
print " return new RawText(GetParam(ForceType<const char *>(), vm, index, ptr));" CR
print " }" CR
- print " return NULL;" CR
+ print " return nullptr;" CR
print " }" CR
} else {
- print " template <> inline int Return<" name " *>(HSQUIRRELVM vm, " name " *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, \"" realname "\", res, NULL, DefSQDestructorCallback<" name ">, true); return 1; }" CR
+ print " template <> inline int Return<" name " *>(HSQUIRRELVM vm, " name " *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, \"" realname "\", res, nullptr, DefSQDestructorCallback<" name ">, true); return 1; }" CR
}
}
diff --git a/src/script/api/squirrel_export.vbs b/src/script/api/squirrel_export.vbs
index a13869509..d9d5d643d 100644
--- a/src/script/api/squirrel_export.vbs
+++ b/src/script/api/squirrel_export.vbs
@@ -62,7 +62,7 @@ Function DumpClassTemplates(name, file)
file.WriteLine " template <> inline const " & name & " *GetParam(ForceType<const " & name & " *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (" & name & " *)instance; }"
file.WriteLine " template <> inline const " & name & " &GetParam(ForceType<const " & name & " &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(" & name & " *)instance; }"
If name = "ScriptEvent" Then
- file.WriteLine " template <> inline int Return<" & name & " *>(HSQUIRRELVM vm, " & name & " *res) { if (res == NULL) { sq_pushnull(vm); return 1; } Squirrel::CreateClassInstanceVM(vm, " & Chr(34) & realname & Chr(34) & ", res, NULL, DefSQDestructorCallback<" & name & ">, true); return 1; }"
+ file.WriteLine " template <> inline int Return<" & name & " *>(HSQUIRRELVM vm, " & name & " *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } Squirrel::CreateClassInstanceVM(vm, " & Chr(34) & realname & Chr(34) & ", res, nullptr, DefSQDestructorCallback<" & name & ">, true); return 1; }"
ElseIf name = "ScriptText" Then
file.WriteLine ""
file.WriteLine " template <> inline Text *GetParam(ForceType<Text *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) {"
@@ -72,10 +72,10 @@ Function DumpClassTemplates(name, file)
file.WriteLine " if (sq_gettype(vm, index) == OT_STRING) {"
file.WriteLine " return new RawText(GetParam(ForceType<const char *>(), vm, index, ptr));"
file.WriteLine " }"
- file.WriteLine " return NULL;"
+ file.WriteLine " return nullptr;"
file.WriteLine " }"
Else
- file.WriteLine " template <> inline int Return<" & name & " *>(HSQUIRRELVM vm, " & name & " *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, " & Chr(34) & realname & Chr(34) & ", res, NULL, DefSQDestructorCallback<" & name & ">, true); return 1; }"
+ file.WriteLine " template <> inline int Return<" & name & " *>(HSQUIRRELVM vm, " & name & " *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, " & Chr(34) & realname & Chr(34) & ", res, nullptr, DefSQDestructorCallback<" & name & ">, true); return 1; }"
End If
End Function
diff --git a/src/script/api/template/template_accounting.hpp.sq b/src/script/api/template/template_accounting.hpp.sq
index 298217a22..58f011a4e 100644
--- a/src/script/api/template/template_accounting.hpp.sq
+++ b/src/script/api/template/template_accounting.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptAccounting &GetParam(ForceType<ScriptAccounting &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptAccounting *)instance; }
template <> inline const ScriptAccounting *GetParam(ForceType<const ScriptAccounting *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptAccounting *)instance; }
template <> inline const ScriptAccounting &GetParam(ForceType<const ScriptAccounting &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptAccounting *)instance; }
- template <> inline int Return<ScriptAccounting *>(HSQUIRRELVM vm, ScriptAccounting *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Accounting", res, NULL, DefSQDestructorCallback<ScriptAccounting>, true); return 1; }
+ template <> inline int Return<ScriptAccounting *>(HSQUIRRELVM vm, ScriptAccounting *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Accounting", res, nullptr, DefSQDestructorCallback<ScriptAccounting>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_admin.hpp.sq b/src/script/api/template/template_admin.hpp.sq
index 2256d674b..394304be0 100644
--- a/src/script/api/template/template_admin.hpp.sq
+++ b/src/script/api/template/template_admin.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptAdmin &GetParam(ForceType<ScriptAdmin &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptAdmin *)instance; }
template <> inline const ScriptAdmin *GetParam(ForceType<const ScriptAdmin *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptAdmin *)instance; }
template <> inline const ScriptAdmin &GetParam(ForceType<const ScriptAdmin &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptAdmin *)instance; }
- template <> inline int Return<ScriptAdmin *>(HSQUIRRELVM vm, ScriptAdmin *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Admin", res, NULL, DefSQDestructorCallback<ScriptAdmin>, true); return 1; }
+ template <> inline int Return<ScriptAdmin *>(HSQUIRRELVM vm, ScriptAdmin *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Admin", res, nullptr, DefSQDestructorCallback<ScriptAdmin>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_airport.hpp.sq b/src/script/api/template/template_airport.hpp.sq
index 402eea076..d091837ce 100644
--- a/src/script/api/template/template_airport.hpp.sq
+++ b/src/script/api/template/template_airport.hpp.sq
@@ -23,5 +23,5 @@ namespace SQConvert {
template <> inline ScriptAirport &GetParam(ForceType<ScriptAirport &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptAirport *)instance; }
template <> inline const ScriptAirport *GetParam(ForceType<const ScriptAirport *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptAirport *)instance; }
template <> inline const ScriptAirport &GetParam(ForceType<const ScriptAirport &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptAirport *)instance; }
- template <> inline int Return<ScriptAirport *>(HSQUIRRELVM vm, ScriptAirport *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Airport", res, NULL, DefSQDestructorCallback<ScriptAirport>, true); return 1; }
+ template <> inline int Return<ScriptAirport *>(HSQUIRRELVM vm, ScriptAirport *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Airport", res, nullptr, DefSQDestructorCallback<ScriptAirport>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_base.hpp.sq b/src/script/api/template/template_base.hpp.sq
index 0ff19bcb8..be19e8bad 100644
--- a/src/script/api/template/template_base.hpp.sq
+++ b/src/script/api/template/template_base.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptBase &GetParam(ForceType<ScriptBase &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptBase *)instance; }
template <> inline const ScriptBase *GetParam(ForceType<const ScriptBase *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptBase *)instance; }
template <> inline const ScriptBase &GetParam(ForceType<const ScriptBase &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptBase *)instance; }
- template <> inline int Return<ScriptBase *>(HSQUIRRELVM vm, ScriptBase *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Base", res, NULL, DefSQDestructorCallback<ScriptBase>, true); return 1; }
+ template <> inline int Return<ScriptBase *>(HSQUIRRELVM vm, ScriptBase *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Base", res, nullptr, DefSQDestructorCallback<ScriptBase>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_basestation.hpp.sq b/src/script/api/template/template_basestation.hpp.sq
index c11a7745e..272c58e4a 100644
--- a/src/script/api/template/template_basestation.hpp.sq
+++ b/src/script/api/template/template_basestation.hpp.sq
@@ -21,5 +21,5 @@ namespace SQConvert {
template <> inline ScriptBaseStation &GetParam(ForceType<ScriptBaseStation &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptBaseStation *)instance; }
template <> inline const ScriptBaseStation *GetParam(ForceType<const ScriptBaseStation *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptBaseStation *)instance; }
template <> inline const ScriptBaseStation &GetParam(ForceType<const ScriptBaseStation &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptBaseStation *)instance; }
- template <> inline int Return<ScriptBaseStation *>(HSQUIRRELVM vm, ScriptBaseStation *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "BaseStation", res, NULL, DefSQDestructorCallback<ScriptBaseStation>, true); return 1; }
+ template <> inline int Return<ScriptBaseStation *>(HSQUIRRELVM vm, ScriptBaseStation *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "BaseStation", res, nullptr, DefSQDestructorCallback<ScriptBaseStation>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_bridge.hpp.sq b/src/script/api/template/template_bridge.hpp.sq
index f62715511..90a1569de 100644
--- a/src/script/api/template/template_bridge.hpp.sq
+++ b/src/script/api/template/template_bridge.hpp.sq
@@ -21,5 +21,5 @@ namespace SQConvert {
template <> inline ScriptBridge &GetParam(ForceType<ScriptBridge &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptBridge *)instance; }
template <> inline const ScriptBridge *GetParam(ForceType<const ScriptBridge *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptBridge *)instance; }
template <> inline const ScriptBridge &GetParam(ForceType<const ScriptBridge &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptBridge *)instance; }
- template <> inline int Return<ScriptBridge *>(HSQUIRRELVM vm, ScriptBridge *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Bridge", res, NULL, DefSQDestructorCallback<ScriptBridge>, true); return 1; }
+ template <> inline int Return<ScriptBridge *>(HSQUIRRELVM vm, ScriptBridge *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Bridge", res, nullptr, DefSQDestructorCallback<ScriptBridge>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_bridgelist.hpp.sq b/src/script/api/template/template_bridgelist.hpp.sq
index 1f78a7874..61c0ccf40 100644
--- a/src/script/api/template/template_bridgelist.hpp.sq
+++ b/src/script/api/template/template_bridgelist.hpp.sq
@@ -17,7 +17,7 @@ namespace SQConvert {
template <> inline ScriptBridgeList &GetParam(ForceType<ScriptBridgeList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptBridgeList *)instance; }
template <> inline const ScriptBridgeList *GetParam(ForceType<const ScriptBridgeList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptBridgeList *)instance; }
template <> inline const ScriptBridgeList &GetParam(ForceType<const ScriptBridgeList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptBridgeList *)instance; }
- template <> inline int Return<ScriptBridgeList *>(HSQUIRRELVM vm, ScriptBridgeList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "BridgeList", res, NULL, DefSQDestructorCallback<ScriptBridgeList>, true); return 1; }
+ template <> inline int Return<ScriptBridgeList *>(HSQUIRRELVM vm, ScriptBridgeList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "BridgeList", res, nullptr, DefSQDestructorCallback<ScriptBridgeList>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -26,5 +26,5 @@ namespace SQConvert {
template <> inline ScriptBridgeList_Length &GetParam(ForceType<ScriptBridgeList_Length &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptBridgeList_Length *)instance; }
template <> inline const ScriptBridgeList_Length *GetParam(ForceType<const ScriptBridgeList_Length *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptBridgeList_Length *)instance; }
template <> inline const ScriptBridgeList_Length &GetParam(ForceType<const ScriptBridgeList_Length &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptBridgeList_Length *)instance; }
- template <> inline int Return<ScriptBridgeList_Length *>(HSQUIRRELVM vm, ScriptBridgeList_Length *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "BridgeList_Length", res, NULL, DefSQDestructorCallback<ScriptBridgeList_Length>, true); return 1; }
+ template <> inline int Return<ScriptBridgeList_Length *>(HSQUIRRELVM vm, ScriptBridgeList_Length *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "BridgeList_Length", res, nullptr, DefSQDestructorCallback<ScriptBridgeList_Length>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_cargo.hpp.sq b/src/script/api/template/template_cargo.hpp.sq
index b57e5c05a..2d85ef862 100644
--- a/src/script/api/template/template_cargo.hpp.sq
+++ b/src/script/api/template/template_cargo.hpp.sq
@@ -27,5 +27,5 @@ namespace SQConvert {
template <> inline ScriptCargo &GetParam(ForceType<ScriptCargo &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCargo *)instance; }
template <> inline const ScriptCargo *GetParam(ForceType<const ScriptCargo *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptCargo *)instance; }
template <> inline const ScriptCargo &GetParam(ForceType<const ScriptCargo &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCargo *)instance; }
- template <> inline int Return<ScriptCargo *>(HSQUIRRELVM vm, ScriptCargo *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Cargo", res, NULL, DefSQDestructorCallback<ScriptCargo>, true); return 1; }
+ template <> inline int Return<ScriptCargo *>(HSQUIRRELVM vm, ScriptCargo *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Cargo", res, nullptr, DefSQDestructorCallback<ScriptCargo>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_cargolist.hpp.sq b/src/script/api/template/template_cargolist.hpp.sq
index 5b39aa66d..eee554027 100644
--- a/src/script/api/template/template_cargolist.hpp.sq
+++ b/src/script/api/template/template_cargolist.hpp.sq
@@ -17,7 +17,7 @@ namespace SQConvert {
template <> inline ScriptCargoList &GetParam(ForceType<ScriptCargoList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCargoList *)instance; }
template <> inline const ScriptCargoList *GetParam(ForceType<const ScriptCargoList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptCargoList *)instance; }
template <> inline const ScriptCargoList &GetParam(ForceType<const ScriptCargoList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCargoList *)instance; }
- template <> inline int Return<ScriptCargoList *>(HSQUIRRELVM vm, ScriptCargoList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "CargoList", res, NULL, DefSQDestructorCallback<ScriptCargoList>, true); return 1; }
+ template <> inline int Return<ScriptCargoList *>(HSQUIRRELVM vm, ScriptCargoList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "CargoList", res, nullptr, DefSQDestructorCallback<ScriptCargoList>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -26,7 +26,7 @@ namespace SQConvert {
template <> inline ScriptCargoList_IndustryAccepting &GetParam(ForceType<ScriptCargoList_IndustryAccepting &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCargoList_IndustryAccepting *)instance; }
template <> inline const ScriptCargoList_IndustryAccepting *GetParam(ForceType<const ScriptCargoList_IndustryAccepting *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptCargoList_IndustryAccepting *)instance; }
template <> inline const ScriptCargoList_IndustryAccepting &GetParam(ForceType<const ScriptCargoList_IndustryAccepting &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCargoList_IndustryAccepting *)instance; }
- template <> inline int Return<ScriptCargoList_IndustryAccepting *>(HSQUIRRELVM vm, ScriptCargoList_IndustryAccepting *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "CargoList_IndustryAccepting", res, NULL, DefSQDestructorCallback<ScriptCargoList_IndustryAccepting>, true); return 1; }
+ template <> inline int Return<ScriptCargoList_IndustryAccepting *>(HSQUIRRELVM vm, ScriptCargoList_IndustryAccepting *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "CargoList_IndustryAccepting", res, nullptr, DefSQDestructorCallback<ScriptCargoList_IndustryAccepting>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -35,7 +35,7 @@ namespace SQConvert {
template <> inline ScriptCargoList_IndustryProducing &GetParam(ForceType<ScriptCargoList_IndustryProducing &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCargoList_IndustryProducing *)instance; }
template <> inline const ScriptCargoList_IndustryProducing *GetParam(ForceType<const ScriptCargoList_IndustryProducing *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptCargoList_IndustryProducing *)instance; }
template <> inline const ScriptCargoList_IndustryProducing &GetParam(ForceType<const ScriptCargoList_IndustryProducing &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCargoList_IndustryProducing *)instance; }
- template <> inline int Return<ScriptCargoList_IndustryProducing *>(HSQUIRRELVM vm, ScriptCargoList_IndustryProducing *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "CargoList_IndustryProducing", res, NULL, DefSQDestructorCallback<ScriptCargoList_IndustryProducing>, true); return 1; }
+ template <> inline int Return<ScriptCargoList_IndustryProducing *>(HSQUIRRELVM vm, ScriptCargoList_IndustryProducing *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "CargoList_IndustryProducing", res, nullptr, DefSQDestructorCallback<ScriptCargoList_IndustryProducing>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -44,5 +44,5 @@ namespace SQConvert {
template <> inline ScriptCargoList_StationAccepting &GetParam(ForceType<ScriptCargoList_StationAccepting &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCargoList_StationAccepting *)instance; }
template <> inline const ScriptCargoList_StationAccepting *GetParam(ForceType<const ScriptCargoList_StationAccepting *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptCargoList_StationAccepting *)instance; }
template <> inline const ScriptCargoList_StationAccepting &GetParam(ForceType<const ScriptCargoList_StationAccepting &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCargoList_StationAccepting *)instance; }
- template <> inline int Return<ScriptCargoList_StationAccepting *>(HSQUIRRELVM vm, ScriptCargoList_StationAccepting *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "CargoList_StationAccepting", res, NULL, DefSQDestructorCallback<ScriptCargoList_StationAccepting>, true); return 1; }
+ template <> inline int Return<ScriptCargoList_StationAccepting *>(HSQUIRRELVM vm, ScriptCargoList_StationAccepting *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "CargoList_StationAccepting", res, nullptr, DefSQDestructorCallback<ScriptCargoList_StationAccepting>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_cargomonitor.hpp.sq b/src/script/api/template/template_cargomonitor.hpp.sq
index ce0a358ac..2010bf6eb 100644
--- a/src/script/api/template/template_cargomonitor.hpp.sq
+++ b/src/script/api/template/template_cargomonitor.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptCargoMonitor &GetParam(ForceType<ScriptCargoMonitor &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCargoMonitor *)instance; }
template <> inline const ScriptCargoMonitor *GetParam(ForceType<const ScriptCargoMonitor *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptCargoMonitor *)instance; }
template <> inline const ScriptCargoMonitor &GetParam(ForceType<const ScriptCargoMonitor &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCargoMonitor *)instance; }
- template <> inline int Return<ScriptCargoMonitor *>(HSQUIRRELVM vm, ScriptCargoMonitor *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "CargoMonitor", res, NULL, DefSQDestructorCallback<ScriptCargoMonitor>, true); return 1; }
+ template <> inline int Return<ScriptCargoMonitor *>(HSQUIRRELVM vm, ScriptCargoMonitor *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "CargoMonitor", res, nullptr, DefSQDestructorCallback<ScriptCargoMonitor>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_client.hpp.sq b/src/script/api/template/template_client.hpp.sq
index 13b9d68b6..7e9314197 100644
--- a/src/script/api/template/template_client.hpp.sq
+++ b/src/script/api/template/template_client.hpp.sq
@@ -21,5 +21,5 @@ namespace SQConvert {
template <> inline ScriptClient &GetParam(ForceType<ScriptClient &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptClient *)instance; }
template <> inline const ScriptClient *GetParam(ForceType<const ScriptClient *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptClient *)instance; }
template <> inline const ScriptClient &GetParam(ForceType<const ScriptClient &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptClient *)instance; }
- template <> inline int Return<ScriptClient *>(HSQUIRRELVM vm, ScriptClient *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Client", res, NULL, DefSQDestructorCallback<ScriptClient>, true); return 1; }
+ template <> inline int Return<ScriptClient *>(HSQUIRRELVM vm, ScriptClient *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Client", res, nullptr, DefSQDestructorCallback<ScriptClient>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_clientlist.hpp.sq b/src/script/api/template/template_clientlist.hpp.sq
index 74c3f4525..6373994a1 100644
--- a/src/script/api/template/template_clientlist.hpp.sq
+++ b/src/script/api/template/template_clientlist.hpp.sq
@@ -17,7 +17,7 @@ namespace SQConvert {
template <> inline ScriptClientList &GetParam(ForceType<ScriptClientList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptClientList *)instance; }
template <> inline const ScriptClientList *GetParam(ForceType<const ScriptClientList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptClientList *)instance; }
template <> inline const ScriptClientList &GetParam(ForceType<const ScriptClientList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptClientList *)instance; }
- template <> inline int Return<ScriptClientList *>(HSQUIRRELVM vm, ScriptClientList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "ClientList", res, NULL, DefSQDestructorCallback<ScriptClientList>, true); return 1; }
+ template <> inline int Return<ScriptClientList *>(HSQUIRRELVM vm, ScriptClientList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "ClientList", res, nullptr, DefSQDestructorCallback<ScriptClientList>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -26,5 +26,5 @@ namespace SQConvert {
template <> inline ScriptClientList_Company &GetParam(ForceType<ScriptClientList_Company &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptClientList_Company *)instance; }
template <> inline const ScriptClientList_Company *GetParam(ForceType<const ScriptClientList_Company *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptClientList_Company *)instance; }
template <> inline const ScriptClientList_Company &GetParam(ForceType<const ScriptClientList_Company &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptClientList_Company *)instance; }
- template <> inline int Return<ScriptClientList_Company *>(HSQUIRRELVM vm, ScriptClientList_Company *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "ClientList_Company", res, NULL, DefSQDestructorCallback<ScriptClientList_Company>, true); return 1; }
+ template <> inline int Return<ScriptClientList_Company *>(HSQUIRRELVM vm, ScriptClientList_Company *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "ClientList_Company", res, nullptr, DefSQDestructorCallback<ScriptClientList_Company>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_company.hpp.sq b/src/script/api/template/template_company.hpp.sq
index 82c10381a..77ca0c933 100644
--- a/src/script/api/template/template_company.hpp.sq
+++ b/src/script/api/template/template_company.hpp.sq
@@ -31,5 +31,5 @@ namespace SQConvert {
template <> inline ScriptCompany &GetParam(ForceType<ScriptCompany &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCompany *)instance; }
template <> inline const ScriptCompany *GetParam(ForceType<const ScriptCompany *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptCompany *)instance; }
template <> inline const ScriptCompany &GetParam(ForceType<const ScriptCompany &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCompany *)instance; }
- template <> inline int Return<ScriptCompany *>(HSQUIRRELVM vm, ScriptCompany *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Company", res, NULL, DefSQDestructorCallback<ScriptCompany>, true); return 1; }
+ template <> inline int Return<ScriptCompany *>(HSQUIRRELVM vm, ScriptCompany *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Company", res, nullptr, DefSQDestructorCallback<ScriptCompany>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_companymode.hpp.sq b/src/script/api/template/template_companymode.hpp.sq
index f99f1d42d..c25f04708 100644
--- a/src/script/api/template/template_companymode.hpp.sq
+++ b/src/script/api/template/template_companymode.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptCompanyMode &GetParam(ForceType<ScriptCompanyMode &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCompanyMode *)instance; }
template <> inline const ScriptCompanyMode *GetParam(ForceType<const ScriptCompanyMode *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptCompanyMode *)instance; }
template <> inline const ScriptCompanyMode &GetParam(ForceType<const ScriptCompanyMode &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptCompanyMode *)instance; }
- template <> inline int Return<ScriptCompanyMode *>(HSQUIRRELVM vm, ScriptCompanyMode *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "CompanyMode", res, NULL, DefSQDestructorCallback<ScriptCompanyMode>, true); return 1; }
+ template <> inline int Return<ScriptCompanyMode *>(HSQUIRRELVM vm, ScriptCompanyMode *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "CompanyMode", res, nullptr, DefSQDestructorCallback<ScriptCompanyMode>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_date.hpp.sq b/src/script/api/template/template_date.hpp.sq
index cca4a258b..c6d65a867 100644
--- a/src/script/api/template/template_date.hpp.sq
+++ b/src/script/api/template/template_date.hpp.sq
@@ -21,5 +21,5 @@ namespace SQConvert {
template <> inline ScriptDate &GetParam(ForceType<ScriptDate &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptDate *)instance; }
template <> inline const ScriptDate *GetParam(ForceType<const ScriptDate *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptDate *)instance; }
template <> inline const ScriptDate &GetParam(ForceType<const ScriptDate &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptDate *)instance; }
- template <> inline int Return<ScriptDate *>(HSQUIRRELVM vm, ScriptDate *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Date", res, NULL, DefSQDestructorCallback<ScriptDate>, true); return 1; }
+ template <> inline int Return<ScriptDate *>(HSQUIRRELVM vm, ScriptDate *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Date", res, nullptr, DefSQDestructorCallback<ScriptDate>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_depotlist.hpp.sq b/src/script/api/template/template_depotlist.hpp.sq
index f5fcbcf54..4305552cf 100644
--- a/src/script/api/template/template_depotlist.hpp.sq
+++ b/src/script/api/template/template_depotlist.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptDepotList &GetParam(ForceType<ScriptDepotList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptDepotList *)instance; }
template <> inline const ScriptDepotList *GetParam(ForceType<const ScriptDepotList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptDepotList *)instance; }
template <> inline const ScriptDepotList &GetParam(ForceType<const ScriptDepotList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptDepotList *)instance; }
- template <> inline int Return<ScriptDepotList *>(HSQUIRRELVM vm, ScriptDepotList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "DepotList", res, NULL, DefSQDestructorCallback<ScriptDepotList>, true); return 1; }
+ template <> inline int Return<ScriptDepotList *>(HSQUIRRELVM vm, ScriptDepotList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "DepotList", res, nullptr, DefSQDestructorCallback<ScriptDepotList>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_engine.hpp.sq b/src/script/api/template/template_engine.hpp.sq
index 3d652df9e..6aa13a94e 100644
--- a/src/script/api/template/template_engine.hpp.sq
+++ b/src/script/api/template/template_engine.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptEngine &GetParam(ForceType<ScriptEngine &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEngine *)instance; }
template <> inline const ScriptEngine *GetParam(ForceType<const ScriptEngine *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEngine *)instance; }
template <> inline const ScriptEngine &GetParam(ForceType<const ScriptEngine &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEngine *)instance; }
- template <> inline int Return<ScriptEngine *>(HSQUIRRELVM vm, ScriptEngine *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Engine", res, NULL, DefSQDestructorCallback<ScriptEngine>, true); return 1; }
+ template <> inline int Return<ScriptEngine *>(HSQUIRRELVM vm, ScriptEngine *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Engine", res, nullptr, DefSQDestructorCallback<ScriptEngine>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_enginelist.hpp.sq b/src/script/api/template/template_enginelist.hpp.sq
index f17c244eb..3d42f8c53 100644
--- a/src/script/api/template/template_enginelist.hpp.sq
+++ b/src/script/api/template/template_enginelist.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptEngineList &GetParam(ForceType<ScriptEngineList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEngineList *)instance; }
template <> inline const ScriptEngineList *GetParam(ForceType<const ScriptEngineList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEngineList *)instance; }
template <> inline const ScriptEngineList &GetParam(ForceType<const ScriptEngineList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEngineList *)instance; }
- template <> inline int Return<ScriptEngineList *>(HSQUIRRELVM vm, ScriptEngineList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EngineList", res, NULL, DefSQDestructorCallback<ScriptEngineList>, true); return 1; }
+ template <> inline int Return<ScriptEngineList *>(HSQUIRRELVM vm, ScriptEngineList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EngineList", res, nullptr, DefSQDestructorCallback<ScriptEngineList>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_error.hpp.sq b/src/script/api/template/template_error.hpp.sq
index 8e61f0810..817a2226d 100644
--- a/src/script/api/template/template_error.hpp.sq
+++ b/src/script/api/template/template_error.hpp.sq
@@ -23,5 +23,5 @@ namespace SQConvert {
template <> inline ScriptError &GetParam(ForceType<ScriptError &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptError *)instance; }
template <> inline const ScriptError *GetParam(ForceType<const ScriptError *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptError *)instance; }
template <> inline const ScriptError &GetParam(ForceType<const ScriptError &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptError *)instance; }
- template <> inline int Return<ScriptError *>(HSQUIRRELVM vm, ScriptError *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Error", res, NULL, DefSQDestructorCallback<ScriptError>, true); return 1; }
+ template <> inline int Return<ScriptError *>(HSQUIRRELVM vm, ScriptError *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Error", res, nullptr, DefSQDestructorCallback<ScriptError>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_event.hpp.sq b/src/script/api/template/template_event.hpp.sq
index c0a8afdc9..3847a81ca 100644
--- a/src/script/api/template/template_event.hpp.sq
+++ b/src/script/api/template/template_event.hpp.sq
@@ -21,7 +21,7 @@ namespace SQConvert {
template <> inline ScriptEvent &GetParam(ForceType<ScriptEvent &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEvent *)instance; }
template <> inline const ScriptEvent *GetParam(ForceType<const ScriptEvent *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEvent *)instance; }
template <> inline const ScriptEvent &GetParam(ForceType<const ScriptEvent &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEvent *)instance; }
- template <> inline int Return<ScriptEvent *>(HSQUIRRELVM vm, ScriptEvent *res) { if (res == NULL) { sq_pushnull(vm); return 1; } Squirrel::CreateClassInstanceVM(vm, "Event", res, NULL, DefSQDestructorCallback<ScriptEvent>, true); return 1; }
+ template <> inline int Return<ScriptEvent *>(HSQUIRRELVM vm, ScriptEvent *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } Squirrel::CreateClassInstanceVM(vm, "Event", res, nullptr, DefSQDestructorCallback<ScriptEvent>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -30,5 +30,5 @@ namespace SQConvert {
template <> inline ScriptEventController &GetParam(ForceType<ScriptEventController &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventController *)instance; }
template <> inline const ScriptEventController *GetParam(ForceType<const ScriptEventController *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventController *)instance; }
template <> inline const ScriptEventController &GetParam(ForceType<const ScriptEventController &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventController *)instance; }
- template <> inline int Return<ScriptEventController *>(HSQUIRRELVM vm, ScriptEventController *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventController", res, NULL, DefSQDestructorCallback<ScriptEventController>, true); return 1; }
+ template <> inline int Return<ScriptEventController *>(HSQUIRRELVM vm, ScriptEventController *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventController", res, nullptr, DefSQDestructorCallback<ScriptEventController>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_event_types.hpp.sq b/src/script/api/template/template_event_types.hpp.sq
index eb6d1f1b4..4b4e00ecf 100644
--- a/src/script/api/template/template_event_types.hpp.sq
+++ b/src/script/api/template/template_event_types.hpp.sq
@@ -21,7 +21,7 @@ namespace SQConvert {
template <> inline ScriptEventVehicleCrashed &GetParam(ForceType<ScriptEventVehicleCrashed &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventVehicleCrashed *)instance; }
template <> inline const ScriptEventVehicleCrashed *GetParam(ForceType<const ScriptEventVehicleCrashed *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventVehicleCrashed *)instance; }
template <> inline const ScriptEventVehicleCrashed &GetParam(ForceType<const ScriptEventVehicleCrashed &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventVehicleCrashed *)instance; }
- template <> inline int Return<ScriptEventVehicleCrashed *>(HSQUIRRELVM vm, ScriptEventVehicleCrashed *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventVehicleCrashed", res, NULL, DefSQDestructorCallback<ScriptEventVehicleCrashed>, true); return 1; }
+ template <> inline int Return<ScriptEventVehicleCrashed *>(HSQUIRRELVM vm, ScriptEventVehicleCrashed *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventVehicleCrashed", res, nullptr, DefSQDestructorCallback<ScriptEventVehicleCrashed>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -30,7 +30,7 @@ namespace SQConvert {
template <> inline ScriptEventSubsidyOffer &GetParam(ForceType<ScriptEventSubsidyOffer &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventSubsidyOffer *)instance; }
template <> inline const ScriptEventSubsidyOffer *GetParam(ForceType<const ScriptEventSubsidyOffer *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventSubsidyOffer *)instance; }
template <> inline const ScriptEventSubsidyOffer &GetParam(ForceType<const ScriptEventSubsidyOffer &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventSubsidyOffer *)instance; }
- template <> inline int Return<ScriptEventSubsidyOffer *>(HSQUIRRELVM vm, ScriptEventSubsidyOffer *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventSubsidyOffer", res, NULL, DefSQDestructorCallback<ScriptEventSubsidyOffer>, true); return 1; }
+ template <> inline int Return<ScriptEventSubsidyOffer *>(HSQUIRRELVM vm, ScriptEventSubsidyOffer *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventSubsidyOffer", res, nullptr, DefSQDestructorCallback<ScriptEventSubsidyOffer>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -39,7 +39,7 @@ namespace SQConvert {
template <> inline ScriptEventSubsidyOfferExpired &GetParam(ForceType<ScriptEventSubsidyOfferExpired &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventSubsidyOfferExpired *)instance; }
template <> inline const ScriptEventSubsidyOfferExpired *GetParam(ForceType<const ScriptEventSubsidyOfferExpired *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventSubsidyOfferExpired *)instance; }
template <> inline const ScriptEventSubsidyOfferExpired &GetParam(ForceType<const ScriptEventSubsidyOfferExpired &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventSubsidyOfferExpired *)instance; }
- template <> inline int Return<ScriptEventSubsidyOfferExpired *>(HSQUIRRELVM vm, ScriptEventSubsidyOfferExpired *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventSubsidyOfferExpired", res, NULL, DefSQDestructorCallback<ScriptEventSubsidyOfferExpired>, true); return 1; }
+ template <> inline int Return<ScriptEventSubsidyOfferExpired *>(HSQUIRRELVM vm, ScriptEventSubsidyOfferExpired *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventSubsidyOfferExpired", res, nullptr, DefSQDestructorCallback<ScriptEventSubsidyOfferExpired>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -48,7 +48,7 @@ namespace SQConvert {
template <> inline ScriptEventSubsidyAwarded &GetParam(ForceType<ScriptEventSubsidyAwarded &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventSubsidyAwarded *)instance; }
template <> inline const ScriptEventSubsidyAwarded *GetParam(ForceType<const ScriptEventSubsidyAwarded *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventSubsidyAwarded *)instance; }
template <> inline const ScriptEventSubsidyAwarded &GetParam(ForceType<const ScriptEventSubsidyAwarded &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventSubsidyAwarded *)instance; }
- template <> inline int Return<ScriptEventSubsidyAwarded *>(HSQUIRRELVM vm, ScriptEventSubsidyAwarded *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventSubsidyAwarded", res, NULL, DefSQDestructorCallback<ScriptEventSubsidyAwarded>, true); return 1; }
+ template <> inline int Return<ScriptEventSubsidyAwarded *>(HSQUIRRELVM vm, ScriptEventSubsidyAwarded *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventSubsidyAwarded", res, nullptr, DefSQDestructorCallback<ScriptEventSubsidyAwarded>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -57,7 +57,7 @@ namespace SQConvert {
template <> inline ScriptEventSubsidyExpired &GetParam(ForceType<ScriptEventSubsidyExpired &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventSubsidyExpired *)instance; }
template <> inline const ScriptEventSubsidyExpired *GetParam(ForceType<const ScriptEventSubsidyExpired *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventSubsidyExpired *)instance; }
template <> inline const ScriptEventSubsidyExpired &GetParam(ForceType<const ScriptEventSubsidyExpired &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventSubsidyExpired *)instance; }
- template <> inline int Return<ScriptEventSubsidyExpired *>(HSQUIRRELVM vm, ScriptEventSubsidyExpired *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventSubsidyExpired", res, NULL, DefSQDestructorCallback<ScriptEventSubsidyExpired>, true); return 1; }
+ template <> inline int Return<ScriptEventSubsidyExpired *>(HSQUIRRELVM vm, ScriptEventSubsidyExpired *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventSubsidyExpired", res, nullptr, DefSQDestructorCallback<ScriptEventSubsidyExpired>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -66,7 +66,7 @@ namespace SQConvert {
template <> inline ScriptEventEnginePreview &GetParam(ForceType<ScriptEventEnginePreview &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventEnginePreview *)instance; }
template <> inline const ScriptEventEnginePreview *GetParam(ForceType<const ScriptEventEnginePreview *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventEnginePreview *)instance; }
template <> inline const ScriptEventEnginePreview &GetParam(ForceType<const ScriptEventEnginePreview &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventEnginePreview *)instance; }
- template <> inline int Return<ScriptEventEnginePreview *>(HSQUIRRELVM vm, ScriptEventEnginePreview *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventEnginePreview", res, NULL, DefSQDestructorCallback<ScriptEventEnginePreview>, true); return 1; }
+ template <> inline int Return<ScriptEventEnginePreview *>(HSQUIRRELVM vm, ScriptEventEnginePreview *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventEnginePreview", res, nullptr, DefSQDestructorCallback<ScriptEventEnginePreview>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -75,7 +75,7 @@ namespace SQConvert {
template <> inline ScriptEventCompanyNew &GetParam(ForceType<ScriptEventCompanyNew &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventCompanyNew *)instance; }
template <> inline const ScriptEventCompanyNew *GetParam(ForceType<const ScriptEventCompanyNew *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventCompanyNew *)instance; }
template <> inline const ScriptEventCompanyNew &GetParam(ForceType<const ScriptEventCompanyNew &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventCompanyNew *)instance; }
- template <> inline int Return<ScriptEventCompanyNew *>(HSQUIRRELVM vm, ScriptEventCompanyNew *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventCompanyNew", res, NULL, DefSQDestructorCallback<ScriptEventCompanyNew>, true); return 1; }
+ template <> inline int Return<ScriptEventCompanyNew *>(HSQUIRRELVM vm, ScriptEventCompanyNew *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventCompanyNew", res, nullptr, DefSQDestructorCallback<ScriptEventCompanyNew>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -84,7 +84,7 @@ namespace SQConvert {
template <> inline ScriptEventCompanyInTrouble &GetParam(ForceType<ScriptEventCompanyInTrouble &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventCompanyInTrouble *)instance; }
template <> inline const ScriptEventCompanyInTrouble *GetParam(ForceType<const ScriptEventCompanyInTrouble *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventCompanyInTrouble *)instance; }
template <> inline const ScriptEventCompanyInTrouble &GetParam(ForceType<const ScriptEventCompanyInTrouble &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventCompanyInTrouble *)instance; }
- template <> inline int Return<ScriptEventCompanyInTrouble *>(HSQUIRRELVM vm, ScriptEventCompanyInTrouble *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventCompanyInTrouble", res, NULL, DefSQDestructorCallback<ScriptEventCompanyInTrouble>, true); return 1; }
+ template <> inline int Return<ScriptEventCompanyInTrouble *>(HSQUIRRELVM vm, ScriptEventCompanyInTrouble *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventCompanyInTrouble", res, nullptr, DefSQDestructorCallback<ScriptEventCompanyInTrouble>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -93,7 +93,7 @@ namespace SQConvert {
template <> inline ScriptEventCompanyAskMerger &GetParam(ForceType<ScriptEventCompanyAskMerger &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventCompanyAskMerger *)instance; }
template <> inline const ScriptEventCompanyAskMerger *GetParam(ForceType<const ScriptEventCompanyAskMerger *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventCompanyAskMerger *)instance; }
template <> inline const ScriptEventCompanyAskMerger &GetParam(ForceType<const ScriptEventCompanyAskMerger &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventCompanyAskMerger *)instance; }
- template <> inline int Return<ScriptEventCompanyAskMerger *>(HSQUIRRELVM vm, ScriptEventCompanyAskMerger *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventCompanyAskMerger", res, NULL, DefSQDestructorCallback<ScriptEventCompanyAskMerger>, true); return 1; }
+ template <> inline int Return<ScriptEventCompanyAskMerger *>(HSQUIRRELVM vm, ScriptEventCompanyAskMerger *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventCompanyAskMerger", res, nullptr, DefSQDestructorCallback<ScriptEventCompanyAskMerger>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -102,7 +102,7 @@ namespace SQConvert {
template <> inline ScriptEventCompanyMerger &GetParam(ForceType<ScriptEventCompanyMerger &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventCompanyMerger *)instance; }
template <> inline const ScriptEventCompanyMerger *GetParam(ForceType<const ScriptEventCompanyMerger *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventCompanyMerger *)instance; }
template <> inline const ScriptEventCompanyMerger &GetParam(ForceType<const ScriptEventCompanyMerger &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventCompanyMerger *)instance; }
- template <> inline int Return<ScriptEventCompanyMerger *>(HSQUIRRELVM vm, ScriptEventCompanyMerger *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventCompanyMerger", res, NULL, DefSQDestructorCallback<ScriptEventCompanyMerger>, true); return 1; }
+ template <> inline int Return<ScriptEventCompanyMerger *>(HSQUIRRELVM vm, ScriptEventCompanyMerger *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventCompanyMerger", res, nullptr, DefSQDestructorCallback<ScriptEventCompanyMerger>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -111,7 +111,7 @@ namespace SQConvert {
template <> inline ScriptEventCompanyBankrupt &GetParam(ForceType<ScriptEventCompanyBankrupt &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventCompanyBankrupt *)instance; }
template <> inline const ScriptEventCompanyBankrupt *GetParam(ForceType<const ScriptEventCompanyBankrupt *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventCompanyBankrupt *)instance; }
template <> inline const ScriptEventCompanyBankrupt &GetParam(ForceType<const ScriptEventCompanyBankrupt &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventCompanyBankrupt *)instance; }
- template <> inline int Return<ScriptEventCompanyBankrupt *>(HSQUIRRELVM vm, ScriptEventCompanyBankrupt *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventCompanyBankrupt", res, NULL, DefSQDestructorCallback<ScriptEventCompanyBankrupt>, true); return 1; }
+ template <> inline int Return<ScriptEventCompanyBankrupt *>(HSQUIRRELVM vm, ScriptEventCompanyBankrupt *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventCompanyBankrupt", res, nullptr, DefSQDestructorCallback<ScriptEventCompanyBankrupt>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -120,7 +120,7 @@ namespace SQConvert {
template <> inline ScriptEventVehicleLost &GetParam(ForceType<ScriptEventVehicleLost &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventVehicleLost *)instance; }
template <> inline const ScriptEventVehicleLost *GetParam(ForceType<const ScriptEventVehicleLost *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventVehicleLost *)instance; }
template <> inline const ScriptEventVehicleLost &GetParam(ForceType<const ScriptEventVehicleLost &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventVehicleLost *)instance; }
- template <> inline int Return<ScriptEventVehicleLost *>(HSQUIRRELVM vm, ScriptEventVehicleLost *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventVehicleLost", res, NULL, DefSQDestructorCallback<ScriptEventVehicleLost>, true); return 1; }
+ template <> inline int Return<ScriptEventVehicleLost *>(HSQUIRRELVM vm, ScriptEventVehicleLost *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventVehicleLost", res, nullptr, DefSQDestructorCallback<ScriptEventVehicleLost>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -129,7 +129,7 @@ namespace SQConvert {
template <> inline ScriptEventVehicleWaitingInDepot &GetParam(ForceType<ScriptEventVehicleWaitingInDepot &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventVehicleWaitingInDepot *)instance; }
template <> inline const ScriptEventVehicleWaitingInDepot *GetParam(ForceType<const ScriptEventVehicleWaitingInDepot *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventVehicleWaitingInDepot *)instance; }
template <> inline const ScriptEventVehicleWaitingInDepot &GetParam(ForceType<const ScriptEventVehicleWaitingInDepot &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventVehicleWaitingInDepot *)instance; }
- template <> inline int Return<ScriptEventVehicleWaitingInDepot *>(HSQUIRRELVM vm, ScriptEventVehicleWaitingInDepot *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventVehicleWaitingInDepot", res, NULL, DefSQDestructorCallback<ScriptEventVehicleWaitingInDepot>, true); return 1; }
+ template <> inline int Return<ScriptEventVehicleWaitingInDepot *>(HSQUIRRELVM vm, ScriptEventVehicleWaitingInDepot *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventVehicleWaitingInDepot", res, nullptr, DefSQDestructorCallback<ScriptEventVehicleWaitingInDepot>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -138,7 +138,7 @@ namespace SQConvert {
template <> inline ScriptEventVehicleUnprofitable &GetParam(ForceType<ScriptEventVehicleUnprofitable &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventVehicleUnprofitable *)instance; }
template <> inline const ScriptEventVehicleUnprofitable *GetParam(ForceType<const ScriptEventVehicleUnprofitable *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventVehicleUnprofitable *)instance; }
template <> inline const ScriptEventVehicleUnprofitable &GetParam(ForceType<const ScriptEventVehicleUnprofitable &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventVehicleUnprofitable *)instance; }
- template <> inline int Return<ScriptEventVehicleUnprofitable *>(HSQUIRRELVM vm, ScriptEventVehicleUnprofitable *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventVehicleUnprofitable", res, NULL, DefSQDestructorCallback<ScriptEventVehicleUnprofitable>, true); return 1; }
+ template <> inline int Return<ScriptEventVehicleUnprofitable *>(HSQUIRRELVM vm, ScriptEventVehicleUnprofitable *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventVehicleUnprofitable", res, nullptr, DefSQDestructorCallback<ScriptEventVehicleUnprofitable>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -147,7 +147,7 @@ namespace SQConvert {
template <> inline ScriptEventIndustryOpen &GetParam(ForceType<ScriptEventIndustryOpen &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventIndustryOpen *)instance; }
template <> inline const ScriptEventIndustryOpen *GetParam(ForceType<const ScriptEventIndustryOpen *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventIndustryOpen *)instance; }
template <> inline const ScriptEventIndustryOpen &GetParam(ForceType<const ScriptEventIndustryOpen &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventIndustryOpen *)instance; }
- template <> inline int Return<ScriptEventIndustryOpen *>(HSQUIRRELVM vm, ScriptEventIndustryOpen *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventIndustryOpen", res, NULL, DefSQDestructorCallback<ScriptEventIndustryOpen>, true); return 1; }
+ template <> inline int Return<ScriptEventIndustryOpen *>(HSQUIRRELVM vm, ScriptEventIndustryOpen *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventIndustryOpen", res, nullptr, DefSQDestructorCallback<ScriptEventIndustryOpen>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -156,7 +156,7 @@ namespace SQConvert {
template <> inline ScriptEventIndustryClose &GetParam(ForceType<ScriptEventIndustryClose &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventIndustryClose *)instance; }
template <> inline const ScriptEventIndustryClose *GetParam(ForceType<const ScriptEventIndustryClose *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventIndustryClose *)instance; }
template <> inline const ScriptEventIndustryClose &GetParam(ForceType<const ScriptEventIndustryClose &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventIndustryClose *)instance; }
- template <> inline int Return<ScriptEventIndustryClose *>(HSQUIRRELVM vm, ScriptEventIndustryClose *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventIndustryClose", res, NULL, DefSQDestructorCallback<ScriptEventIndustryClose>, true); return 1; }
+ template <> inline int Return<ScriptEventIndustryClose *>(HSQUIRRELVM vm, ScriptEventIndustryClose *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventIndustryClose", res, nullptr, DefSQDestructorCallback<ScriptEventIndustryClose>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -165,7 +165,7 @@ namespace SQConvert {
template <> inline ScriptEventEngineAvailable &GetParam(ForceType<ScriptEventEngineAvailable &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventEngineAvailable *)instance; }
template <> inline const ScriptEventEngineAvailable *GetParam(ForceType<const ScriptEventEngineAvailable *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventEngineAvailable *)instance; }
template <> inline const ScriptEventEngineAvailable &GetParam(ForceType<const ScriptEventEngineAvailable &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventEngineAvailable *)instance; }
- template <> inline int Return<ScriptEventEngineAvailable *>(HSQUIRRELVM vm, ScriptEventEngineAvailable *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventEngineAvailable", res, NULL, DefSQDestructorCallback<ScriptEventEngineAvailable>, true); return 1; }
+ template <> inline int Return<ScriptEventEngineAvailable *>(HSQUIRRELVM vm, ScriptEventEngineAvailable *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventEngineAvailable", res, nullptr, DefSQDestructorCallback<ScriptEventEngineAvailable>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -174,7 +174,7 @@ namespace SQConvert {
template <> inline ScriptEventStationFirstVehicle &GetParam(ForceType<ScriptEventStationFirstVehicle &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventStationFirstVehicle *)instance; }
template <> inline const ScriptEventStationFirstVehicle *GetParam(ForceType<const ScriptEventStationFirstVehicle *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventStationFirstVehicle *)instance; }
template <> inline const ScriptEventStationFirstVehicle &GetParam(ForceType<const ScriptEventStationFirstVehicle &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventStationFirstVehicle *)instance; }
- template <> inline int Return<ScriptEventStationFirstVehicle *>(HSQUIRRELVM vm, ScriptEventStationFirstVehicle *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventStationFirstVehicle", res, NULL, DefSQDestructorCallback<ScriptEventStationFirstVehicle>, true); return 1; }
+ template <> inline int Return<ScriptEventStationFirstVehicle *>(HSQUIRRELVM vm, ScriptEventStationFirstVehicle *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventStationFirstVehicle", res, nullptr, DefSQDestructorCallback<ScriptEventStationFirstVehicle>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -183,7 +183,7 @@ namespace SQConvert {
template <> inline ScriptEventDisasterZeppelinerCrashed &GetParam(ForceType<ScriptEventDisasterZeppelinerCrashed &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventDisasterZeppelinerCrashed *)instance; }
template <> inline const ScriptEventDisasterZeppelinerCrashed *GetParam(ForceType<const ScriptEventDisasterZeppelinerCrashed *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventDisasterZeppelinerCrashed *)instance; }
template <> inline const ScriptEventDisasterZeppelinerCrashed &GetParam(ForceType<const ScriptEventDisasterZeppelinerCrashed &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventDisasterZeppelinerCrashed *)instance; }
- template <> inline int Return<ScriptEventDisasterZeppelinerCrashed *>(HSQUIRRELVM vm, ScriptEventDisasterZeppelinerCrashed *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventDisasterZeppelinerCrashed", res, NULL, DefSQDestructorCallback<ScriptEventDisasterZeppelinerCrashed>, true); return 1; }
+ template <> inline int Return<ScriptEventDisasterZeppelinerCrashed *>(HSQUIRRELVM vm, ScriptEventDisasterZeppelinerCrashed *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventDisasterZeppelinerCrashed", res, nullptr, DefSQDestructorCallback<ScriptEventDisasterZeppelinerCrashed>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -192,7 +192,7 @@ namespace SQConvert {
template <> inline ScriptEventDisasterZeppelinerCleared &GetParam(ForceType<ScriptEventDisasterZeppelinerCleared &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventDisasterZeppelinerCleared *)instance; }
template <> inline const ScriptEventDisasterZeppelinerCleared *GetParam(ForceType<const ScriptEventDisasterZeppelinerCleared *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventDisasterZeppelinerCleared *)instance; }
template <> inline const ScriptEventDisasterZeppelinerCleared &GetParam(ForceType<const ScriptEventDisasterZeppelinerCleared &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventDisasterZeppelinerCleared *)instance; }
- template <> inline int Return<ScriptEventDisasterZeppelinerCleared *>(HSQUIRRELVM vm, ScriptEventDisasterZeppelinerCleared *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventDisasterZeppelinerCleared", res, NULL, DefSQDestructorCallback<ScriptEventDisasterZeppelinerCleared>, true); return 1; }
+ template <> inline int Return<ScriptEventDisasterZeppelinerCleared *>(HSQUIRRELVM vm, ScriptEventDisasterZeppelinerCleared *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventDisasterZeppelinerCleared", res, nullptr, DefSQDestructorCallback<ScriptEventDisasterZeppelinerCleared>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -201,7 +201,7 @@ namespace SQConvert {
template <> inline ScriptEventTownFounded &GetParam(ForceType<ScriptEventTownFounded &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventTownFounded *)instance; }
template <> inline const ScriptEventTownFounded *GetParam(ForceType<const ScriptEventTownFounded *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventTownFounded *)instance; }
template <> inline const ScriptEventTownFounded &GetParam(ForceType<const ScriptEventTownFounded &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventTownFounded *)instance; }
- template <> inline int Return<ScriptEventTownFounded *>(HSQUIRRELVM vm, ScriptEventTownFounded *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventTownFounded", res, NULL, DefSQDestructorCallback<ScriptEventTownFounded>, true); return 1; }
+ template <> inline int Return<ScriptEventTownFounded *>(HSQUIRRELVM vm, ScriptEventTownFounded *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventTownFounded", res, nullptr, DefSQDestructorCallback<ScriptEventTownFounded>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -210,7 +210,7 @@ namespace SQConvert {
template <> inline ScriptEventAircraftDestTooFar &GetParam(ForceType<ScriptEventAircraftDestTooFar &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventAircraftDestTooFar *)instance; }
template <> inline const ScriptEventAircraftDestTooFar *GetParam(ForceType<const ScriptEventAircraftDestTooFar *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventAircraftDestTooFar *)instance; }
template <> inline const ScriptEventAircraftDestTooFar &GetParam(ForceType<const ScriptEventAircraftDestTooFar &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventAircraftDestTooFar *)instance; }
- template <> inline int Return<ScriptEventAircraftDestTooFar *>(HSQUIRRELVM vm, ScriptEventAircraftDestTooFar *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventAircraftDestTooFar", res, NULL, DefSQDestructorCallback<ScriptEventAircraftDestTooFar>, true); return 1; }
+ template <> inline int Return<ScriptEventAircraftDestTooFar *>(HSQUIRRELVM vm, ScriptEventAircraftDestTooFar *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventAircraftDestTooFar", res, nullptr, DefSQDestructorCallback<ScriptEventAircraftDestTooFar>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -219,7 +219,7 @@ namespace SQConvert {
template <> inline ScriptEventAdminPort &GetParam(ForceType<ScriptEventAdminPort &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventAdminPort *)instance; }
template <> inline const ScriptEventAdminPort *GetParam(ForceType<const ScriptEventAdminPort *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventAdminPort *)instance; }
template <> inline const ScriptEventAdminPort &GetParam(ForceType<const ScriptEventAdminPort &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventAdminPort *)instance; }
- template <> inline int Return<ScriptEventAdminPort *>(HSQUIRRELVM vm, ScriptEventAdminPort *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventAdminPort", res, NULL, DefSQDestructorCallback<ScriptEventAdminPort>, true); return 1; }
+ template <> inline int Return<ScriptEventAdminPort *>(HSQUIRRELVM vm, ScriptEventAdminPort *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventAdminPort", res, nullptr, DefSQDestructorCallback<ScriptEventAdminPort>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -228,7 +228,7 @@ namespace SQConvert {
template <> inline ScriptEventWindowWidgetClick &GetParam(ForceType<ScriptEventWindowWidgetClick &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventWindowWidgetClick *)instance; }
template <> inline const ScriptEventWindowWidgetClick *GetParam(ForceType<const ScriptEventWindowWidgetClick *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventWindowWidgetClick *)instance; }
template <> inline const ScriptEventWindowWidgetClick &GetParam(ForceType<const ScriptEventWindowWidgetClick &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventWindowWidgetClick *)instance; }
- template <> inline int Return<ScriptEventWindowWidgetClick *>(HSQUIRRELVM vm, ScriptEventWindowWidgetClick *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventWindowWidgetClick", res, NULL, DefSQDestructorCallback<ScriptEventWindowWidgetClick>, true); return 1; }
+ template <> inline int Return<ScriptEventWindowWidgetClick *>(HSQUIRRELVM vm, ScriptEventWindowWidgetClick *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventWindowWidgetClick", res, nullptr, DefSQDestructorCallback<ScriptEventWindowWidgetClick>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -237,7 +237,7 @@ namespace SQConvert {
template <> inline ScriptEventGoalQuestionAnswer &GetParam(ForceType<ScriptEventGoalQuestionAnswer &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventGoalQuestionAnswer *)instance; }
template <> inline const ScriptEventGoalQuestionAnswer *GetParam(ForceType<const ScriptEventGoalQuestionAnswer *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventGoalQuestionAnswer *)instance; }
template <> inline const ScriptEventGoalQuestionAnswer &GetParam(ForceType<const ScriptEventGoalQuestionAnswer &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventGoalQuestionAnswer *)instance; }
- template <> inline int Return<ScriptEventGoalQuestionAnswer *>(HSQUIRRELVM vm, ScriptEventGoalQuestionAnswer *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventGoalQuestionAnswer", res, NULL, DefSQDestructorCallback<ScriptEventGoalQuestionAnswer>, true); return 1; }
+ template <> inline int Return<ScriptEventGoalQuestionAnswer *>(HSQUIRRELVM vm, ScriptEventGoalQuestionAnswer *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventGoalQuestionAnswer", res, nullptr, DefSQDestructorCallback<ScriptEventGoalQuestionAnswer>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -246,7 +246,7 @@ namespace SQConvert {
template <> inline ScriptEventCompanyTown &GetParam(ForceType<ScriptEventCompanyTown &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventCompanyTown *)instance; }
template <> inline const ScriptEventCompanyTown *GetParam(ForceType<const ScriptEventCompanyTown *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventCompanyTown *)instance; }
template <> inline const ScriptEventCompanyTown &GetParam(ForceType<const ScriptEventCompanyTown &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventCompanyTown *)instance; }
- template <> inline int Return<ScriptEventCompanyTown *>(HSQUIRRELVM vm, ScriptEventCompanyTown *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventCompanyTown", res, NULL, DefSQDestructorCallback<ScriptEventCompanyTown>, true); return 1; }
+ template <> inline int Return<ScriptEventCompanyTown *>(HSQUIRRELVM vm, ScriptEventCompanyTown *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventCompanyTown", res, nullptr, DefSQDestructorCallback<ScriptEventCompanyTown>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -255,7 +255,7 @@ namespace SQConvert {
template <> inline ScriptEventExclusiveTransportRights &GetParam(ForceType<ScriptEventExclusiveTransportRights &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventExclusiveTransportRights *)instance; }
template <> inline const ScriptEventExclusiveTransportRights *GetParam(ForceType<const ScriptEventExclusiveTransportRights *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventExclusiveTransportRights *)instance; }
template <> inline const ScriptEventExclusiveTransportRights &GetParam(ForceType<const ScriptEventExclusiveTransportRights &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventExclusiveTransportRights *)instance; }
- template <> inline int Return<ScriptEventExclusiveTransportRights *>(HSQUIRRELVM vm, ScriptEventExclusiveTransportRights *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventExclusiveTransportRights", res, NULL, DefSQDestructorCallback<ScriptEventExclusiveTransportRights>, true); return 1; }
+ template <> inline int Return<ScriptEventExclusiveTransportRights *>(HSQUIRRELVM vm, ScriptEventExclusiveTransportRights *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventExclusiveTransportRights", res, nullptr, DefSQDestructorCallback<ScriptEventExclusiveTransportRights>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -264,5 +264,5 @@ namespace SQConvert {
template <> inline ScriptEventRoadReconstruction &GetParam(ForceType<ScriptEventRoadReconstruction &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventRoadReconstruction *)instance; }
template <> inline const ScriptEventRoadReconstruction *GetParam(ForceType<const ScriptEventRoadReconstruction *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptEventRoadReconstruction *)instance; }
template <> inline const ScriptEventRoadReconstruction &GetParam(ForceType<const ScriptEventRoadReconstruction &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptEventRoadReconstruction *)instance; }
- template <> inline int Return<ScriptEventRoadReconstruction *>(HSQUIRRELVM vm, ScriptEventRoadReconstruction *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventRoadReconstruction", res, NULL, DefSQDestructorCallback<ScriptEventRoadReconstruction>, true); return 1; }
+ template <> inline int Return<ScriptEventRoadReconstruction *>(HSQUIRRELVM vm, ScriptEventRoadReconstruction *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "EventRoadReconstruction", res, nullptr, DefSQDestructorCallback<ScriptEventRoadReconstruction>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_execmode.hpp.sq b/src/script/api/template/template_execmode.hpp.sq
index 4c8326bc1..b7030774e 100644
--- a/src/script/api/template/template_execmode.hpp.sq
+++ b/src/script/api/template/template_execmode.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptExecMode &GetParam(ForceType<ScriptExecMode &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptExecMode *)instance; }
template <> inline const ScriptExecMode *GetParam(ForceType<const ScriptExecMode *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptExecMode *)instance; }
template <> inline const ScriptExecMode &GetParam(ForceType<const ScriptExecMode &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptExecMode *)instance; }
- template <> inline int Return<ScriptExecMode *>(HSQUIRRELVM vm, ScriptExecMode *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "ExecMode", res, NULL, DefSQDestructorCallback<ScriptExecMode>, true); return 1; }
+ template <> inline int Return<ScriptExecMode *>(HSQUIRRELVM vm, ScriptExecMode *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "ExecMode", res, nullptr, DefSQDestructorCallback<ScriptExecMode>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_game.hpp.sq b/src/script/api/template/template_game.hpp.sq
index 495aeada4..db30d893e 100644
--- a/src/script/api/template/template_game.hpp.sq
+++ b/src/script/api/template/template_game.hpp.sq
@@ -21,5 +21,5 @@ namespace SQConvert {
template <> inline ScriptGame &GetParam(ForceType<ScriptGame &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptGame *)instance; }
template <> inline const ScriptGame *GetParam(ForceType<const ScriptGame *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptGame *)instance; }
template <> inline const ScriptGame &GetParam(ForceType<const ScriptGame &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptGame *)instance; }
- template <> inline int Return<ScriptGame *>(HSQUIRRELVM vm, ScriptGame *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Game", res, NULL, DefSQDestructorCallback<ScriptGame>, true); return 1; }
+ template <> inline int Return<ScriptGame *>(HSQUIRRELVM vm, ScriptGame *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Game", res, nullptr, DefSQDestructorCallback<ScriptGame>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_gamesettings.hpp.sq b/src/script/api/template/template_gamesettings.hpp.sq
index 9c6e91746..4882951a1 100644
--- a/src/script/api/template/template_gamesettings.hpp.sq
+++ b/src/script/api/template/template_gamesettings.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptGameSettings &GetParam(ForceType<ScriptGameSettings &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptGameSettings *)instance; }
template <> inline const ScriptGameSettings *GetParam(ForceType<const ScriptGameSettings *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptGameSettings *)instance; }
template <> inline const ScriptGameSettings &GetParam(ForceType<const ScriptGameSettings &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptGameSettings *)instance; }
- template <> inline int Return<ScriptGameSettings *>(HSQUIRRELVM vm, ScriptGameSettings *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "GameSettings", res, NULL, DefSQDestructorCallback<ScriptGameSettings>, true); return 1; }
+ template <> inline int Return<ScriptGameSettings *>(HSQUIRRELVM vm, ScriptGameSettings *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "GameSettings", res, nullptr, DefSQDestructorCallback<ScriptGameSettings>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_goal.hpp.sq b/src/script/api/template/template_goal.hpp.sq
index 6aa3014ee..7b392eca7 100644
--- a/src/script/api/template/template_goal.hpp.sq
+++ b/src/script/api/template/template_goal.hpp.sq
@@ -27,5 +27,5 @@ namespace SQConvert {
template <> inline ScriptGoal &GetParam(ForceType<ScriptGoal &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptGoal *)instance; }
template <> inline const ScriptGoal *GetParam(ForceType<const ScriptGoal *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptGoal *)instance; }
template <> inline const ScriptGoal &GetParam(ForceType<const ScriptGoal &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptGoal *)instance; }
- template <> inline int Return<ScriptGoal *>(HSQUIRRELVM vm, ScriptGoal *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Goal", res, NULL, DefSQDestructorCallback<ScriptGoal>, true); return 1; }
+ template <> inline int Return<ScriptGoal *>(HSQUIRRELVM vm, ScriptGoal *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Goal", res, nullptr, DefSQDestructorCallback<ScriptGoal>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_group.hpp.sq b/src/script/api/template/template_group.hpp.sq
index ac4abe5a1..0bb83765a 100644
--- a/src/script/api/template/template_group.hpp.sq
+++ b/src/script/api/template/template_group.hpp.sq
@@ -21,5 +21,5 @@ namespace SQConvert {
template <> inline ScriptGroup &GetParam(ForceType<ScriptGroup &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptGroup *)instance; }
template <> inline const ScriptGroup *GetParam(ForceType<const ScriptGroup *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptGroup *)instance; }
template <> inline const ScriptGroup &GetParam(ForceType<const ScriptGroup &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptGroup *)instance; }
- template <> inline int Return<ScriptGroup *>(HSQUIRRELVM vm, ScriptGroup *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Group", res, NULL, DefSQDestructorCallback<ScriptGroup>, true); return 1; }
+ template <> inline int Return<ScriptGroup *>(HSQUIRRELVM vm, ScriptGroup *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Group", res, nullptr, DefSQDestructorCallback<ScriptGroup>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_grouplist.hpp.sq b/src/script/api/template/template_grouplist.hpp.sq
index 858abcf01..8638ef52f 100644
--- a/src/script/api/template/template_grouplist.hpp.sq
+++ b/src/script/api/template/template_grouplist.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptGroupList &GetParam(ForceType<ScriptGroupList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptGroupList *)instance; }
template <> inline const ScriptGroupList *GetParam(ForceType<const ScriptGroupList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptGroupList *)instance; }
template <> inline const ScriptGroupList &GetParam(ForceType<const ScriptGroupList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptGroupList *)instance; }
- template <> inline int Return<ScriptGroupList *>(HSQUIRRELVM vm, ScriptGroupList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "GroupList", res, NULL, DefSQDestructorCallback<ScriptGroupList>, true); return 1; }
+ template <> inline int Return<ScriptGroupList *>(HSQUIRRELVM vm, ScriptGroupList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "GroupList", res, nullptr, DefSQDestructorCallback<ScriptGroupList>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_industry.hpp.sq b/src/script/api/template/template_industry.hpp.sq
index e1e02263c..3b60c0fd3 100644
--- a/src/script/api/template/template_industry.hpp.sq
+++ b/src/script/api/template/template_industry.hpp.sq
@@ -21,5 +21,5 @@ namespace SQConvert {
template <> inline ScriptIndustry &GetParam(ForceType<ScriptIndustry &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptIndustry *)instance; }
template <> inline const ScriptIndustry *GetParam(ForceType<const ScriptIndustry *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptIndustry *)instance; }
template <> inline const ScriptIndustry &GetParam(ForceType<const ScriptIndustry &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptIndustry *)instance; }
- template <> inline int Return<ScriptIndustry *>(HSQUIRRELVM vm, ScriptIndustry *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Industry", res, NULL, DefSQDestructorCallback<ScriptIndustry>, true); return 1; }
+ template <> inline int Return<ScriptIndustry *>(HSQUIRRELVM vm, ScriptIndustry *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Industry", res, nullptr, DefSQDestructorCallback<ScriptIndustry>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_industrylist.hpp.sq b/src/script/api/template/template_industrylist.hpp.sq
index 0c0316346..184b42775 100644
--- a/src/script/api/template/template_industrylist.hpp.sq
+++ b/src/script/api/template/template_industrylist.hpp.sq
@@ -17,7 +17,7 @@ namespace SQConvert {
template <> inline ScriptIndustryList &GetParam(ForceType<ScriptIndustryList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptIndustryList *)instance; }
template <> inline const ScriptIndustryList *GetParam(ForceType<const ScriptIndustryList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptIndustryList *)instance; }
template <> inline const ScriptIndustryList &GetParam(ForceType<const ScriptIndustryList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptIndustryList *)instance; }
- template <> inline int Return<ScriptIndustryList *>(HSQUIRRELVM vm, ScriptIndustryList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "IndustryList", res, NULL, DefSQDestructorCallback<ScriptIndustryList>, true); return 1; }
+ template <> inline int Return<ScriptIndustryList *>(HSQUIRRELVM vm, ScriptIndustryList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "IndustryList", res, nullptr, DefSQDestructorCallback<ScriptIndustryList>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -26,7 +26,7 @@ namespace SQConvert {
template <> inline ScriptIndustryList_CargoAccepting &GetParam(ForceType<ScriptIndustryList_CargoAccepting &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptIndustryList_CargoAccepting *)instance; }
template <> inline const ScriptIndustryList_CargoAccepting *GetParam(ForceType<const ScriptIndustryList_CargoAccepting *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptIndustryList_CargoAccepting *)instance; }
template <> inline const ScriptIndustryList_CargoAccepting &GetParam(ForceType<const ScriptIndustryList_CargoAccepting &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptIndustryList_CargoAccepting *)instance; }
- template <> inline int Return<ScriptIndustryList_CargoAccepting *>(HSQUIRRELVM vm, ScriptIndustryList_CargoAccepting *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "IndustryList_CargoAccepting", res, NULL, DefSQDestructorCallback<ScriptIndustryList_CargoAccepting>, true); return 1; }
+ template <> inline int Return<ScriptIndustryList_CargoAccepting *>(HSQUIRRELVM vm, ScriptIndustryList_CargoAccepting *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "IndustryList_CargoAccepting", res, nullptr, DefSQDestructorCallback<ScriptIndustryList_CargoAccepting>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -35,5 +35,5 @@ namespace SQConvert {
template <> inline ScriptIndustryList_CargoProducing &GetParam(ForceType<ScriptIndustryList_CargoProducing &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptIndustryList_CargoProducing *)instance; }
template <> inline const ScriptIndustryList_CargoProducing *GetParam(ForceType<const ScriptIndustryList_CargoProducing *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptIndustryList_CargoProducing *)instance; }
template <> inline const ScriptIndustryList_CargoProducing &GetParam(ForceType<const ScriptIndustryList_CargoProducing &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptIndustryList_CargoProducing *)instance; }
- template <> inline int Return<ScriptIndustryList_CargoProducing *>(HSQUIRRELVM vm, ScriptIndustryList_CargoProducing *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "IndustryList_CargoProducing", res, NULL, DefSQDestructorCallback<ScriptIndustryList_CargoProducing>, true); return 1; }
+ template <> inline int Return<ScriptIndustryList_CargoProducing *>(HSQUIRRELVM vm, ScriptIndustryList_CargoProducing *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "IndustryList_CargoProducing", res, nullptr, DefSQDestructorCallback<ScriptIndustryList_CargoProducing>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_industrytype.hpp.sq b/src/script/api/template/template_industrytype.hpp.sq
index 79495053e..dfc735d03 100644
--- a/src/script/api/template/template_industrytype.hpp.sq
+++ b/src/script/api/template/template_industrytype.hpp.sq
@@ -21,5 +21,5 @@ namespace SQConvert {
template <> inline ScriptIndustryType &GetParam(ForceType<ScriptIndustryType &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptIndustryType *)instance; }
template <> inline const ScriptIndustryType *GetParam(ForceType<const ScriptIndustryType *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptIndustryType *)instance; }
template <> inline const ScriptIndustryType &GetParam(ForceType<const ScriptIndustryType &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptIndustryType *)instance; }
- template <> inline int Return<ScriptIndustryType *>(HSQUIRRELVM vm, ScriptIndustryType *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "IndustryType", res, NULL, DefSQDestructorCallback<ScriptIndustryType>, true); return 1; }
+ template <> inline int Return<ScriptIndustryType *>(HSQUIRRELVM vm, ScriptIndustryType *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "IndustryType", res, nullptr, DefSQDestructorCallback<ScriptIndustryType>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_industrytypelist.hpp.sq b/src/script/api/template/template_industrytypelist.hpp.sq
index 044f9cced..cac1fc0e3 100644
--- a/src/script/api/template/template_industrytypelist.hpp.sq
+++ b/src/script/api/template/template_industrytypelist.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptIndustryTypeList &GetParam(ForceType<ScriptIndustryTypeList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptIndustryTypeList *)instance; }
template <> inline const ScriptIndustryTypeList *GetParam(ForceType<const ScriptIndustryTypeList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptIndustryTypeList *)instance; }
template <> inline const ScriptIndustryTypeList &GetParam(ForceType<const ScriptIndustryTypeList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptIndustryTypeList *)instance; }
- template <> inline int Return<ScriptIndustryTypeList *>(HSQUIRRELVM vm, ScriptIndustryTypeList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "IndustryTypeList", res, NULL, DefSQDestructorCallback<ScriptIndustryTypeList>, true); return 1; }
+ template <> inline int Return<ScriptIndustryTypeList *>(HSQUIRRELVM vm, ScriptIndustryTypeList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "IndustryTypeList", res, nullptr, DefSQDestructorCallback<ScriptIndustryTypeList>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_infrastructure.hpp.sq b/src/script/api/template/template_infrastructure.hpp.sq
index 39460e140..c2a7b7191 100644
--- a/src/script/api/template/template_infrastructure.hpp.sq
+++ b/src/script/api/template/template_infrastructure.hpp.sq
@@ -21,5 +21,5 @@ namespace SQConvert {
template <> inline ScriptInfrastructure &GetParam(ForceType<ScriptInfrastructure &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptInfrastructure *)instance; }
template <> inline const ScriptInfrastructure *GetParam(ForceType<const ScriptInfrastructure *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptInfrastructure *)instance; }
template <> inline const ScriptInfrastructure &GetParam(ForceType<const ScriptInfrastructure &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptInfrastructure *)instance; }
- template <> inline int Return<ScriptInfrastructure *>(HSQUIRRELVM vm, ScriptInfrastructure *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Infrastructure", res, NULL, DefSQDestructorCallback<ScriptInfrastructure>, true); return 1; }
+ template <> inline int Return<ScriptInfrastructure *>(HSQUIRRELVM vm, ScriptInfrastructure *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Infrastructure", res, nullptr, DefSQDestructorCallback<ScriptInfrastructure>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_list.hpp.sq b/src/script/api/template/template_list.hpp.sq
index fa8d2b36d..b16117af3 100644
--- a/src/script/api/template/template_list.hpp.sq
+++ b/src/script/api/template/template_list.hpp.sq
@@ -21,5 +21,5 @@ namespace SQConvert {
template <> inline ScriptList &GetParam(ForceType<ScriptList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptList *)instance; }
template <> inline const ScriptList *GetParam(ForceType<const ScriptList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptList *)instance; }
template <> inline const ScriptList &GetParam(ForceType<const ScriptList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptList *)instance; }
- template <> inline int Return<ScriptList *>(HSQUIRRELVM vm, ScriptList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "List", res, NULL, DefSQDestructorCallback<ScriptList>, true); return 1; }
+ template <> inline int Return<ScriptList *>(HSQUIRRELVM vm, ScriptList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "List", res, nullptr, DefSQDestructorCallback<ScriptList>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_log.hpp.sq b/src/script/api/template/template_log.hpp.sq
index 91c0511d0..fd9737388 100644
--- a/src/script/api/template/template_log.hpp.sq
+++ b/src/script/api/template/template_log.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptLog &GetParam(ForceType<ScriptLog &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptLog *)instance; }
template <> inline const ScriptLog *GetParam(ForceType<const ScriptLog *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptLog *)instance; }
template <> inline const ScriptLog &GetParam(ForceType<const ScriptLog &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptLog *)instance; }
- template <> inline int Return<ScriptLog *>(HSQUIRRELVM vm, ScriptLog *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Log", res, NULL, DefSQDestructorCallback<ScriptLog>, true); return 1; }
+ template <> inline int Return<ScriptLog *>(HSQUIRRELVM vm, ScriptLog *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Log", res, nullptr, DefSQDestructorCallback<ScriptLog>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_map.hpp.sq b/src/script/api/template/template_map.hpp.sq
index 4d34cc734..980bd7a53 100644
--- a/src/script/api/template/template_map.hpp.sq
+++ b/src/script/api/template/template_map.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptMap &GetParam(ForceType<ScriptMap &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptMap *)instance; }
template <> inline const ScriptMap *GetParam(ForceType<const ScriptMap *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptMap *)instance; }
template <> inline const ScriptMap &GetParam(ForceType<const ScriptMap &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptMap *)instance; }
- template <> inline int Return<ScriptMap *>(HSQUIRRELVM vm, ScriptMap *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Map", res, NULL, DefSQDestructorCallback<ScriptMap>, true); return 1; }
+ template <> inline int Return<ScriptMap *>(HSQUIRRELVM vm, ScriptMap *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Map", res, nullptr, DefSQDestructorCallback<ScriptMap>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_marine.hpp.sq b/src/script/api/template/template_marine.hpp.sq
index d2415b699..1dc3eaa33 100644
--- a/src/script/api/template/template_marine.hpp.sq
+++ b/src/script/api/template/template_marine.hpp.sq
@@ -23,5 +23,5 @@ namespace SQConvert {
template <> inline ScriptMarine &GetParam(ForceType<ScriptMarine &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptMarine *)instance; }
template <> inline const ScriptMarine *GetParam(ForceType<const ScriptMarine *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptMarine *)instance; }
template <> inline const ScriptMarine &GetParam(ForceType<const ScriptMarine &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptMarine *)instance; }
- template <> inline int Return<ScriptMarine *>(HSQUIRRELVM vm, ScriptMarine *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Marine", res, NULL, DefSQDestructorCallback<ScriptMarine>, true); return 1; }
+ template <> inline int Return<ScriptMarine *>(HSQUIRRELVM vm, ScriptMarine *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Marine", res, nullptr, DefSQDestructorCallback<ScriptMarine>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_news.hpp.sq b/src/script/api/template/template_news.hpp.sq
index 445a055e1..db65507cc 100644
--- a/src/script/api/template/template_news.hpp.sq
+++ b/src/script/api/template/template_news.hpp.sq
@@ -23,5 +23,5 @@ namespace SQConvert {
template <> inline ScriptNews &GetParam(ForceType<ScriptNews &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptNews *)instance; }
template <> inline const ScriptNews *GetParam(ForceType<const ScriptNews *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptNews *)instance; }
template <> inline const ScriptNews &GetParam(ForceType<const ScriptNews &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptNews *)instance; }
- template <> inline int Return<ScriptNews *>(HSQUIRRELVM vm, ScriptNews *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "News", res, NULL, DefSQDestructorCallback<ScriptNews>, true); return 1; }
+ template <> inline int Return<ScriptNews *>(HSQUIRRELVM vm, ScriptNews *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "News", res, nullptr, DefSQDestructorCallback<ScriptNews>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_order.hpp.sq b/src/script/api/template/template_order.hpp.sq
index d11fafa14..39a16e00e 100644
--- a/src/script/api/template/template_order.hpp.sq
+++ b/src/script/api/template/template_order.hpp.sq
@@ -31,5 +31,5 @@ namespace SQConvert {
template <> inline ScriptOrder &GetParam(ForceType<ScriptOrder &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptOrder *)instance; }
template <> inline const ScriptOrder *GetParam(ForceType<const ScriptOrder *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptOrder *)instance; }
template <> inline const ScriptOrder &GetParam(ForceType<const ScriptOrder &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptOrder *)instance; }
- template <> inline int Return<ScriptOrder *>(HSQUIRRELVM vm, ScriptOrder *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Order", res, NULL, DefSQDestructorCallback<ScriptOrder>, true); return 1; }
+ template <> inline int Return<ScriptOrder *>(HSQUIRRELVM vm, ScriptOrder *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Order", res, nullptr, DefSQDestructorCallback<ScriptOrder>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_rail.hpp.sq b/src/script/api/template/template_rail.hpp.sq
index f92f96d58..3b9c9ce6a 100644
--- a/src/script/api/template/template_rail.hpp.sq
+++ b/src/script/api/template/template_rail.hpp.sq
@@ -29,5 +29,5 @@ namespace SQConvert {
template <> inline ScriptRail &GetParam(ForceType<ScriptRail &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptRail *)instance; }
template <> inline const ScriptRail *GetParam(ForceType<const ScriptRail *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptRail *)instance; }
template <> inline const ScriptRail &GetParam(ForceType<const ScriptRail &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptRail *)instance; }
- template <> inline int Return<ScriptRail *>(HSQUIRRELVM vm, ScriptRail *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Rail", res, NULL, DefSQDestructorCallback<ScriptRail>, true); return 1; }
+ template <> inline int Return<ScriptRail *>(HSQUIRRELVM vm, ScriptRail *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Rail", res, nullptr, DefSQDestructorCallback<ScriptRail>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_railtypelist.hpp.sq b/src/script/api/template/template_railtypelist.hpp.sq
index 9a768e1d5..87f9f0e2c 100644
--- a/src/script/api/template/template_railtypelist.hpp.sq
+++ b/src/script/api/template/template_railtypelist.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptRailTypeList &GetParam(ForceType<ScriptRailTypeList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptRailTypeList *)instance; }
template <> inline const ScriptRailTypeList *GetParam(ForceType<const ScriptRailTypeList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptRailTypeList *)instance; }
template <> inline const ScriptRailTypeList &GetParam(ForceType<const ScriptRailTypeList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptRailTypeList *)instance; }
- template <> inline int Return<ScriptRailTypeList *>(HSQUIRRELVM vm, ScriptRailTypeList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "RailTypeList", res, NULL, DefSQDestructorCallback<ScriptRailTypeList>, true); return 1; }
+ template <> inline int Return<ScriptRailTypeList *>(HSQUIRRELVM vm, ScriptRailTypeList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "RailTypeList", res, nullptr, DefSQDestructorCallback<ScriptRailTypeList>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_road.hpp.sq b/src/script/api/template/template_road.hpp.sq
index d50bda573..bf9a32082 100644
--- a/src/script/api/template/template_road.hpp.sq
+++ b/src/script/api/template/template_road.hpp.sq
@@ -27,5 +27,5 @@ namespace SQConvert {
template <> inline ScriptRoad &GetParam(ForceType<ScriptRoad &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptRoad *)instance; }
template <> inline const ScriptRoad *GetParam(ForceType<const ScriptRoad *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptRoad *)instance; }
template <> inline const ScriptRoad &GetParam(ForceType<const ScriptRoad &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptRoad *)instance; }
- template <> inline int Return<ScriptRoad *>(HSQUIRRELVM vm, ScriptRoad *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Road", res, NULL, DefSQDestructorCallback<ScriptRoad>, true); return 1; }
+ template <> inline int Return<ScriptRoad *>(HSQUIRRELVM vm, ScriptRoad *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Road", res, nullptr, DefSQDestructorCallback<ScriptRoad>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_sign.hpp.sq b/src/script/api/template/template_sign.hpp.sq
index db926fed3..244171189 100644
--- a/src/script/api/template/template_sign.hpp.sq
+++ b/src/script/api/template/template_sign.hpp.sq
@@ -21,5 +21,5 @@ namespace SQConvert {
template <> inline ScriptSign &GetParam(ForceType<ScriptSign &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptSign *)instance; }
template <> inline const ScriptSign *GetParam(ForceType<const ScriptSign *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptSign *)instance; }
template <> inline const ScriptSign &GetParam(ForceType<const ScriptSign &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptSign *)instance; }
- template <> inline int Return<ScriptSign *>(HSQUIRRELVM vm, ScriptSign *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Sign", res, NULL, DefSQDestructorCallback<ScriptSign>, true); return 1; }
+ template <> inline int Return<ScriptSign *>(HSQUIRRELVM vm, ScriptSign *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Sign", res, nullptr, DefSQDestructorCallback<ScriptSign>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_signlist.hpp.sq b/src/script/api/template/template_signlist.hpp.sq
index e5bd67ae5..a7c53a6c8 100644
--- a/src/script/api/template/template_signlist.hpp.sq
+++ b/src/script/api/template/template_signlist.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptSignList &GetParam(ForceType<ScriptSignList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptSignList *)instance; }
template <> inline const ScriptSignList *GetParam(ForceType<const ScriptSignList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptSignList *)instance; }
template <> inline const ScriptSignList &GetParam(ForceType<const ScriptSignList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptSignList *)instance; }
- template <> inline int Return<ScriptSignList *>(HSQUIRRELVM vm, ScriptSignList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "SignList", res, NULL, DefSQDestructorCallback<ScriptSignList>, true); return 1; }
+ template <> inline int Return<ScriptSignList *>(HSQUIRRELVM vm, ScriptSignList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "SignList", res, nullptr, DefSQDestructorCallback<ScriptSignList>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_station.hpp.sq b/src/script/api/template/template_station.hpp.sq
index 729ae68a6..3bbd4220e 100644
--- a/src/script/api/template/template_station.hpp.sq
+++ b/src/script/api/template/template_station.hpp.sq
@@ -23,5 +23,5 @@ namespace SQConvert {
template <> inline ScriptStation &GetParam(ForceType<ScriptStation &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStation *)instance; }
template <> inline const ScriptStation *GetParam(ForceType<const ScriptStation *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStation *)instance; }
template <> inline const ScriptStation &GetParam(ForceType<const ScriptStation &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStation *)instance; }
- template <> inline int Return<ScriptStation *>(HSQUIRRELVM vm, ScriptStation *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Station", res, NULL, DefSQDestructorCallback<ScriptStation>, true); return 1; }
+ template <> inline int Return<ScriptStation *>(HSQUIRRELVM vm, ScriptStation *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Station", res, nullptr, DefSQDestructorCallback<ScriptStation>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_stationlist.hpp.sq b/src/script/api/template/template_stationlist.hpp.sq
index 5f7bd2812..e13d26b67 100644
--- a/src/script/api/template/template_stationlist.hpp.sq
+++ b/src/script/api/template/template_stationlist.hpp.sq
@@ -17,7 +17,7 @@ namespace SQConvert {
template <> inline ScriptStationList &GetParam(ForceType<ScriptStationList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList *)instance; }
template <> inline const ScriptStationList *GetParam(ForceType<const ScriptStationList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStationList *)instance; }
template <> inline const ScriptStationList &GetParam(ForceType<const ScriptStationList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList *)instance; }
- template <> inline int Return<ScriptStationList *>(HSQUIRRELVM vm, ScriptStationList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList", res, NULL, DefSQDestructorCallback<ScriptStationList>, true); return 1; }
+ template <> inline int Return<ScriptStationList *>(HSQUIRRELVM vm, ScriptStationList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList", res, nullptr, DefSQDestructorCallback<ScriptStationList>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -32,7 +32,7 @@ namespace SQConvert {
template <> inline ScriptStationList_Cargo &GetParam(ForceType<ScriptStationList_Cargo &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_Cargo *)instance; }
template <> inline const ScriptStationList_Cargo *GetParam(ForceType<const ScriptStationList_Cargo *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStationList_Cargo *)instance; }
template <> inline const ScriptStationList_Cargo &GetParam(ForceType<const ScriptStationList_Cargo &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_Cargo *)instance; }
- template <> inline int Return<ScriptStationList_Cargo *>(HSQUIRRELVM vm, ScriptStationList_Cargo *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_Cargo", res, NULL, DefSQDestructorCallback<ScriptStationList_Cargo>, true); return 1; }
+ template <> inline int Return<ScriptStationList_Cargo *>(HSQUIRRELVM vm, ScriptStationList_Cargo *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_Cargo", res, nullptr, DefSQDestructorCallback<ScriptStationList_Cargo>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -41,7 +41,7 @@ namespace SQConvert {
template <> inline ScriptStationList_CargoWaiting &GetParam(ForceType<ScriptStationList_CargoWaiting &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoWaiting *)instance; }
template <> inline const ScriptStationList_CargoWaiting *GetParam(ForceType<const ScriptStationList_CargoWaiting *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStationList_CargoWaiting *)instance; }
template <> inline const ScriptStationList_CargoWaiting &GetParam(ForceType<const ScriptStationList_CargoWaiting &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoWaiting *)instance; }
- template <> inline int Return<ScriptStationList_CargoWaiting *>(HSQUIRRELVM vm, ScriptStationList_CargoWaiting *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoWaiting", res, NULL, DefSQDestructorCallback<ScriptStationList_CargoWaiting>, true); return 1; }
+ template <> inline int Return<ScriptStationList_CargoWaiting *>(HSQUIRRELVM vm, ScriptStationList_CargoWaiting *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoWaiting", res, nullptr, DefSQDestructorCallback<ScriptStationList_CargoWaiting>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -50,7 +50,7 @@ namespace SQConvert {
template <> inline ScriptStationList_CargoPlanned &GetParam(ForceType<ScriptStationList_CargoPlanned &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoPlanned *)instance; }
template <> inline const ScriptStationList_CargoPlanned *GetParam(ForceType<const ScriptStationList_CargoPlanned *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStationList_CargoPlanned *)instance; }
template <> inline const ScriptStationList_CargoPlanned &GetParam(ForceType<const ScriptStationList_CargoPlanned &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoPlanned *)instance; }
- template <> inline int Return<ScriptStationList_CargoPlanned *>(HSQUIRRELVM vm, ScriptStationList_CargoPlanned *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoPlanned", res, NULL, DefSQDestructorCallback<ScriptStationList_CargoPlanned>, true); return 1; }
+ template <> inline int Return<ScriptStationList_CargoPlanned *>(HSQUIRRELVM vm, ScriptStationList_CargoPlanned *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoPlanned", res, nullptr, DefSQDestructorCallback<ScriptStationList_CargoPlanned>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -59,7 +59,7 @@ namespace SQConvert {
template <> inline ScriptStationList_CargoWaitingByFrom &GetParam(ForceType<ScriptStationList_CargoWaitingByFrom &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoWaitingByFrom *)instance; }
template <> inline const ScriptStationList_CargoWaitingByFrom *GetParam(ForceType<const ScriptStationList_CargoWaitingByFrom *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStationList_CargoWaitingByFrom *)instance; }
template <> inline const ScriptStationList_CargoWaitingByFrom &GetParam(ForceType<const ScriptStationList_CargoWaitingByFrom &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoWaitingByFrom *)instance; }
- template <> inline int Return<ScriptStationList_CargoWaitingByFrom *>(HSQUIRRELVM vm, ScriptStationList_CargoWaitingByFrom *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoWaitingByFrom", res, NULL, DefSQDestructorCallback<ScriptStationList_CargoWaitingByFrom>, true); return 1; }
+ template <> inline int Return<ScriptStationList_CargoWaitingByFrom *>(HSQUIRRELVM vm, ScriptStationList_CargoWaitingByFrom *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoWaitingByFrom", res, nullptr, DefSQDestructorCallback<ScriptStationList_CargoWaitingByFrom>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -68,7 +68,7 @@ namespace SQConvert {
template <> inline ScriptStationList_CargoWaitingViaByFrom &GetParam(ForceType<ScriptStationList_CargoWaitingViaByFrom &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoWaitingViaByFrom *)instance; }
template <> inline const ScriptStationList_CargoWaitingViaByFrom *GetParam(ForceType<const ScriptStationList_CargoWaitingViaByFrom *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStationList_CargoWaitingViaByFrom *)instance; }
template <> inline const ScriptStationList_CargoWaitingViaByFrom &GetParam(ForceType<const ScriptStationList_CargoWaitingViaByFrom &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoWaitingViaByFrom *)instance; }
- template <> inline int Return<ScriptStationList_CargoWaitingViaByFrom *>(HSQUIRRELVM vm, ScriptStationList_CargoWaitingViaByFrom *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoWaitingViaByFrom", res, NULL, DefSQDestructorCallback<ScriptStationList_CargoWaitingViaByFrom>, true); return 1; }
+ template <> inline int Return<ScriptStationList_CargoWaitingViaByFrom *>(HSQUIRRELVM vm, ScriptStationList_CargoWaitingViaByFrom *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoWaitingViaByFrom", res, nullptr, DefSQDestructorCallback<ScriptStationList_CargoWaitingViaByFrom>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -77,7 +77,7 @@ namespace SQConvert {
template <> inline ScriptStationList_CargoWaitingByVia &GetParam(ForceType<ScriptStationList_CargoWaitingByVia &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoWaitingByVia *)instance; }
template <> inline const ScriptStationList_CargoWaitingByVia *GetParam(ForceType<const ScriptStationList_CargoWaitingByVia *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStationList_CargoWaitingByVia *)instance; }
template <> inline const ScriptStationList_CargoWaitingByVia &GetParam(ForceType<const ScriptStationList_CargoWaitingByVia &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoWaitingByVia *)instance; }
- template <> inline int Return<ScriptStationList_CargoWaitingByVia *>(HSQUIRRELVM vm, ScriptStationList_CargoWaitingByVia *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoWaitingByVia", res, NULL, DefSQDestructorCallback<ScriptStationList_CargoWaitingByVia>, true); return 1; }
+ template <> inline int Return<ScriptStationList_CargoWaitingByVia *>(HSQUIRRELVM vm, ScriptStationList_CargoWaitingByVia *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoWaitingByVia", res, nullptr, DefSQDestructorCallback<ScriptStationList_CargoWaitingByVia>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -86,7 +86,7 @@ namespace SQConvert {
template <> inline ScriptStationList_CargoWaitingFromByVia &GetParam(ForceType<ScriptStationList_CargoWaitingFromByVia &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoWaitingFromByVia *)instance; }
template <> inline const ScriptStationList_CargoWaitingFromByVia *GetParam(ForceType<const ScriptStationList_CargoWaitingFromByVia *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStationList_CargoWaitingFromByVia *)instance; }
template <> inline const ScriptStationList_CargoWaitingFromByVia &GetParam(ForceType<const ScriptStationList_CargoWaitingFromByVia &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoWaitingFromByVia *)instance; }
- template <> inline int Return<ScriptStationList_CargoWaitingFromByVia *>(HSQUIRRELVM vm, ScriptStationList_CargoWaitingFromByVia *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoWaitingFromByVia", res, NULL, DefSQDestructorCallback<ScriptStationList_CargoWaitingFromByVia>, true); return 1; }
+ template <> inline int Return<ScriptStationList_CargoWaitingFromByVia *>(HSQUIRRELVM vm, ScriptStationList_CargoWaitingFromByVia *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoWaitingFromByVia", res, nullptr, DefSQDestructorCallback<ScriptStationList_CargoWaitingFromByVia>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -95,7 +95,7 @@ namespace SQConvert {
template <> inline ScriptStationList_CargoPlannedByFrom &GetParam(ForceType<ScriptStationList_CargoPlannedByFrom &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoPlannedByFrom *)instance; }
template <> inline const ScriptStationList_CargoPlannedByFrom *GetParam(ForceType<const ScriptStationList_CargoPlannedByFrom *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStationList_CargoPlannedByFrom *)instance; }
template <> inline const ScriptStationList_CargoPlannedByFrom &GetParam(ForceType<const ScriptStationList_CargoPlannedByFrom &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoPlannedByFrom *)instance; }
- template <> inline int Return<ScriptStationList_CargoPlannedByFrom *>(HSQUIRRELVM vm, ScriptStationList_CargoPlannedByFrom *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoPlannedByFrom", res, NULL, DefSQDestructorCallback<ScriptStationList_CargoPlannedByFrom>, true); return 1; }
+ template <> inline int Return<ScriptStationList_CargoPlannedByFrom *>(HSQUIRRELVM vm, ScriptStationList_CargoPlannedByFrom *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoPlannedByFrom", res, nullptr, DefSQDestructorCallback<ScriptStationList_CargoPlannedByFrom>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -104,7 +104,7 @@ namespace SQConvert {
template <> inline ScriptStationList_CargoPlannedViaByFrom &GetParam(ForceType<ScriptStationList_CargoPlannedViaByFrom &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoPlannedViaByFrom *)instance; }
template <> inline const ScriptStationList_CargoPlannedViaByFrom *GetParam(ForceType<const ScriptStationList_CargoPlannedViaByFrom *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStationList_CargoPlannedViaByFrom *)instance; }
template <> inline const ScriptStationList_CargoPlannedViaByFrom &GetParam(ForceType<const ScriptStationList_CargoPlannedViaByFrom &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoPlannedViaByFrom *)instance; }
- template <> inline int Return<ScriptStationList_CargoPlannedViaByFrom *>(HSQUIRRELVM vm, ScriptStationList_CargoPlannedViaByFrom *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoPlannedViaByFrom", res, NULL, DefSQDestructorCallback<ScriptStationList_CargoPlannedViaByFrom>, true); return 1; }
+ template <> inline int Return<ScriptStationList_CargoPlannedViaByFrom *>(HSQUIRRELVM vm, ScriptStationList_CargoPlannedViaByFrom *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoPlannedViaByFrom", res, nullptr, DefSQDestructorCallback<ScriptStationList_CargoPlannedViaByFrom>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -113,7 +113,7 @@ namespace SQConvert {
template <> inline ScriptStationList_CargoPlannedByVia &GetParam(ForceType<ScriptStationList_CargoPlannedByVia &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoPlannedByVia *)instance; }
template <> inline const ScriptStationList_CargoPlannedByVia *GetParam(ForceType<const ScriptStationList_CargoPlannedByVia *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStationList_CargoPlannedByVia *)instance; }
template <> inline const ScriptStationList_CargoPlannedByVia &GetParam(ForceType<const ScriptStationList_CargoPlannedByVia &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoPlannedByVia *)instance; }
- template <> inline int Return<ScriptStationList_CargoPlannedByVia *>(HSQUIRRELVM vm, ScriptStationList_CargoPlannedByVia *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoPlannedByVia", res, NULL, DefSQDestructorCallback<ScriptStationList_CargoPlannedByVia>, true); return 1; }
+ template <> inline int Return<ScriptStationList_CargoPlannedByVia *>(HSQUIRRELVM vm, ScriptStationList_CargoPlannedByVia *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoPlannedByVia", res, nullptr, DefSQDestructorCallback<ScriptStationList_CargoPlannedByVia>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -122,7 +122,7 @@ namespace SQConvert {
template <> inline ScriptStationList_CargoPlannedFromByVia &GetParam(ForceType<ScriptStationList_CargoPlannedFromByVia &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoPlannedFromByVia *)instance; }
template <> inline const ScriptStationList_CargoPlannedFromByVia *GetParam(ForceType<const ScriptStationList_CargoPlannedFromByVia *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStationList_CargoPlannedFromByVia *)instance; }
template <> inline const ScriptStationList_CargoPlannedFromByVia &GetParam(ForceType<const ScriptStationList_CargoPlannedFromByVia &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_CargoPlannedFromByVia *)instance; }
- template <> inline int Return<ScriptStationList_CargoPlannedFromByVia *>(HSQUIRRELVM vm, ScriptStationList_CargoPlannedFromByVia *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoPlannedFromByVia", res, NULL, DefSQDestructorCallback<ScriptStationList_CargoPlannedFromByVia>, true); return 1; }
+ template <> inline int Return<ScriptStationList_CargoPlannedFromByVia *>(HSQUIRRELVM vm, ScriptStationList_CargoPlannedFromByVia *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_CargoPlannedFromByVia", res, nullptr, DefSQDestructorCallback<ScriptStationList_CargoPlannedFromByVia>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -131,5 +131,5 @@ namespace SQConvert {
template <> inline ScriptStationList_Vehicle &GetParam(ForceType<ScriptStationList_Vehicle &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_Vehicle *)instance; }
template <> inline const ScriptStationList_Vehicle *GetParam(ForceType<const ScriptStationList_Vehicle *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStationList_Vehicle *)instance; }
template <> inline const ScriptStationList_Vehicle &GetParam(ForceType<const ScriptStationList_Vehicle &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStationList_Vehicle *)instance; }
- template <> inline int Return<ScriptStationList_Vehicle *>(HSQUIRRELVM vm, ScriptStationList_Vehicle *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_Vehicle", res, NULL, DefSQDestructorCallback<ScriptStationList_Vehicle>, true); return 1; }
+ template <> inline int Return<ScriptStationList_Vehicle *>(HSQUIRRELVM vm, ScriptStationList_Vehicle *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StationList_Vehicle", res, nullptr, DefSQDestructorCallback<ScriptStationList_Vehicle>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_story_page.hpp.sq b/src/script/api/template/template_story_page.hpp.sq
index 4c322a3ac..add3a30e7 100644
--- a/src/script/api/template/template_story_page.hpp.sq
+++ b/src/script/api/template/template_story_page.hpp.sq
@@ -25,5 +25,5 @@ namespace SQConvert {
template <> inline ScriptStoryPage &GetParam(ForceType<ScriptStoryPage &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStoryPage *)instance; }
template <> inline const ScriptStoryPage *GetParam(ForceType<const ScriptStoryPage *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStoryPage *)instance; }
template <> inline const ScriptStoryPage &GetParam(ForceType<const ScriptStoryPage &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStoryPage *)instance; }
- template <> inline int Return<ScriptStoryPage *>(HSQUIRRELVM vm, ScriptStoryPage *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StoryPage", res, NULL, DefSQDestructorCallback<ScriptStoryPage>, true); return 1; }
+ template <> inline int Return<ScriptStoryPage *>(HSQUIRRELVM vm, ScriptStoryPage *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StoryPage", res, nullptr, DefSQDestructorCallback<ScriptStoryPage>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_storypageelementlist.hpp.sq b/src/script/api/template/template_storypageelementlist.hpp.sq
index 34d940f92..df7ae6e68 100644
--- a/src/script/api/template/template_storypageelementlist.hpp.sq
+++ b/src/script/api/template/template_storypageelementlist.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptStoryPageElementList &GetParam(ForceType<ScriptStoryPageElementList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStoryPageElementList *)instance; }
template <> inline const ScriptStoryPageElementList *GetParam(ForceType<const ScriptStoryPageElementList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStoryPageElementList *)instance; }
template <> inline const ScriptStoryPageElementList &GetParam(ForceType<const ScriptStoryPageElementList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStoryPageElementList *)instance; }
- template <> inline int Return<ScriptStoryPageElementList *>(HSQUIRRELVM vm, ScriptStoryPageElementList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StoryPageElementList", res, NULL, DefSQDestructorCallback<ScriptStoryPageElementList>, true); return 1; }
+ template <> inline int Return<ScriptStoryPageElementList *>(HSQUIRRELVM vm, ScriptStoryPageElementList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StoryPageElementList", res, nullptr, DefSQDestructorCallback<ScriptStoryPageElementList>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_storypagelist.hpp.sq b/src/script/api/template/template_storypagelist.hpp.sq
index 7325969fd..bb21f83a9 100644
--- a/src/script/api/template/template_storypagelist.hpp.sq
+++ b/src/script/api/template/template_storypagelist.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptStoryPageList &GetParam(ForceType<ScriptStoryPageList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStoryPageList *)instance; }
template <> inline const ScriptStoryPageList *GetParam(ForceType<const ScriptStoryPageList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptStoryPageList *)instance; }
template <> inline const ScriptStoryPageList &GetParam(ForceType<const ScriptStoryPageList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptStoryPageList *)instance; }
- template <> inline int Return<ScriptStoryPageList *>(HSQUIRRELVM vm, ScriptStoryPageList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StoryPageList", res, NULL, DefSQDestructorCallback<ScriptStoryPageList>, true); return 1; }
+ template <> inline int Return<ScriptStoryPageList *>(HSQUIRRELVM vm, ScriptStoryPageList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "StoryPageList", res, nullptr, DefSQDestructorCallback<ScriptStoryPageList>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_subsidy.hpp.sq b/src/script/api/template/template_subsidy.hpp.sq
index 61303a645..501a2f23f 100644
--- a/src/script/api/template/template_subsidy.hpp.sq
+++ b/src/script/api/template/template_subsidy.hpp.sq
@@ -21,5 +21,5 @@ namespace SQConvert {
template <> inline ScriptSubsidy &GetParam(ForceType<ScriptSubsidy &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptSubsidy *)instance; }
template <> inline const ScriptSubsidy *GetParam(ForceType<const ScriptSubsidy *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptSubsidy *)instance; }
template <> inline const ScriptSubsidy &GetParam(ForceType<const ScriptSubsidy &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptSubsidy *)instance; }
- template <> inline int Return<ScriptSubsidy *>(HSQUIRRELVM vm, ScriptSubsidy *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Subsidy", res, NULL, DefSQDestructorCallback<ScriptSubsidy>, true); return 1; }
+ template <> inline int Return<ScriptSubsidy *>(HSQUIRRELVM vm, ScriptSubsidy *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Subsidy", res, nullptr, DefSQDestructorCallback<ScriptSubsidy>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_subsidylist.hpp.sq b/src/script/api/template/template_subsidylist.hpp.sq
index 4e6284f4e..1f3f7b3a1 100644
--- a/src/script/api/template/template_subsidylist.hpp.sq
+++ b/src/script/api/template/template_subsidylist.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptSubsidyList &GetParam(ForceType<ScriptSubsidyList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptSubsidyList *)instance; }
template <> inline const ScriptSubsidyList *GetParam(ForceType<const ScriptSubsidyList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptSubsidyList *)instance; }
template <> inline const ScriptSubsidyList &GetParam(ForceType<const ScriptSubsidyList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptSubsidyList *)instance; }
- template <> inline int Return<ScriptSubsidyList *>(HSQUIRRELVM vm, ScriptSubsidyList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "SubsidyList", res, NULL, DefSQDestructorCallback<ScriptSubsidyList>, true); return 1; }
+ template <> inline int Return<ScriptSubsidyList *>(HSQUIRRELVM vm, ScriptSubsidyList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "SubsidyList", res, nullptr, DefSQDestructorCallback<ScriptSubsidyList>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_testmode.hpp.sq b/src/script/api/template/template_testmode.hpp.sq
index bacafa16e..5404e8023 100644
--- a/src/script/api/template/template_testmode.hpp.sq
+++ b/src/script/api/template/template_testmode.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptTestMode &GetParam(ForceType<ScriptTestMode &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTestMode *)instance; }
template <> inline const ScriptTestMode *GetParam(ForceType<const ScriptTestMode *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptTestMode *)instance; }
template <> inline const ScriptTestMode &GetParam(ForceType<const ScriptTestMode &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTestMode *)instance; }
- template <> inline int Return<ScriptTestMode *>(HSQUIRRELVM vm, ScriptTestMode *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "TestMode", res, NULL, DefSQDestructorCallback<ScriptTestMode>, true); return 1; }
+ template <> inline int Return<ScriptTestMode *>(HSQUIRRELVM vm, ScriptTestMode *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "TestMode", res, nullptr, DefSQDestructorCallback<ScriptTestMode>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_text.hpp.sq b/src/script/api/template/template_text.hpp.sq
index 7a44daf16..93654c84a 100644
--- a/src/script/api/template/template_text.hpp.sq
+++ b/src/script/api/template/template_text.hpp.sq
@@ -25,6 +25,6 @@ namespace SQConvert {
if (sq_gettype(vm, index) == OT_STRING) {
return new RawText(GetParam(ForceType<const char *>(), vm, index, ptr));
}
- return NULL;
+ return nullptr;
}
} // namespace SQConvert
diff --git a/src/script/api/template/template_tile.hpp.sq b/src/script/api/template/template_tile.hpp.sq
index e78aaa6ac..9271b5ba4 100644
--- a/src/script/api/template/template_tile.hpp.sq
+++ b/src/script/api/template/template_tile.hpp.sq
@@ -31,5 +31,5 @@ namespace SQConvert {
template <> inline ScriptTile &GetParam(ForceType<ScriptTile &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTile *)instance; }
template <> inline const ScriptTile *GetParam(ForceType<const ScriptTile *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptTile *)instance; }
template <> inline const ScriptTile &GetParam(ForceType<const ScriptTile &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTile *)instance; }
- template <> inline int Return<ScriptTile *>(HSQUIRRELVM vm, ScriptTile *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Tile", res, NULL, DefSQDestructorCallback<ScriptTile>, true); return 1; }
+ template <> inline int Return<ScriptTile *>(HSQUIRRELVM vm, ScriptTile *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Tile", res, nullptr, DefSQDestructorCallback<ScriptTile>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_tilelist.hpp.sq b/src/script/api/template/template_tilelist.hpp.sq
index e3d73a7c8..989e6749e 100644
--- a/src/script/api/template/template_tilelist.hpp.sq
+++ b/src/script/api/template/template_tilelist.hpp.sq
@@ -17,7 +17,7 @@ namespace SQConvert {
template <> inline ScriptTileList &GetParam(ForceType<ScriptTileList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTileList *)instance; }
template <> inline const ScriptTileList *GetParam(ForceType<const ScriptTileList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptTileList *)instance; }
template <> inline const ScriptTileList &GetParam(ForceType<const ScriptTileList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTileList *)instance; }
- template <> inline int Return<ScriptTileList *>(HSQUIRRELVM vm, ScriptTileList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "TileList", res, NULL, DefSQDestructorCallback<ScriptTileList>, true); return 1; }
+ template <> inline int Return<ScriptTileList *>(HSQUIRRELVM vm, ScriptTileList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "TileList", res, nullptr, DefSQDestructorCallback<ScriptTileList>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -26,7 +26,7 @@ namespace SQConvert {
template <> inline ScriptTileList_IndustryAccepting &GetParam(ForceType<ScriptTileList_IndustryAccepting &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTileList_IndustryAccepting *)instance; }
template <> inline const ScriptTileList_IndustryAccepting *GetParam(ForceType<const ScriptTileList_IndustryAccepting *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptTileList_IndustryAccepting *)instance; }
template <> inline const ScriptTileList_IndustryAccepting &GetParam(ForceType<const ScriptTileList_IndustryAccepting &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTileList_IndustryAccepting *)instance; }
- template <> inline int Return<ScriptTileList_IndustryAccepting *>(HSQUIRRELVM vm, ScriptTileList_IndustryAccepting *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "TileList_IndustryAccepting", res, NULL, DefSQDestructorCallback<ScriptTileList_IndustryAccepting>, true); return 1; }
+ template <> inline int Return<ScriptTileList_IndustryAccepting *>(HSQUIRRELVM vm, ScriptTileList_IndustryAccepting *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "TileList_IndustryAccepting", res, nullptr, DefSQDestructorCallback<ScriptTileList_IndustryAccepting>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -35,7 +35,7 @@ namespace SQConvert {
template <> inline ScriptTileList_IndustryProducing &GetParam(ForceType<ScriptTileList_IndustryProducing &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTileList_IndustryProducing *)instance; }
template <> inline const ScriptTileList_IndustryProducing *GetParam(ForceType<const ScriptTileList_IndustryProducing *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptTileList_IndustryProducing *)instance; }
template <> inline const ScriptTileList_IndustryProducing &GetParam(ForceType<const ScriptTileList_IndustryProducing &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTileList_IndustryProducing *)instance; }
- template <> inline int Return<ScriptTileList_IndustryProducing *>(HSQUIRRELVM vm, ScriptTileList_IndustryProducing *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "TileList_IndustryProducing", res, NULL, DefSQDestructorCallback<ScriptTileList_IndustryProducing>, true); return 1; }
+ template <> inline int Return<ScriptTileList_IndustryProducing *>(HSQUIRRELVM vm, ScriptTileList_IndustryProducing *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "TileList_IndustryProducing", res, nullptr, DefSQDestructorCallback<ScriptTileList_IndustryProducing>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -44,5 +44,5 @@ namespace SQConvert {
template <> inline ScriptTileList_StationType &GetParam(ForceType<ScriptTileList_StationType &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTileList_StationType *)instance; }
template <> inline const ScriptTileList_StationType *GetParam(ForceType<const ScriptTileList_StationType *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptTileList_StationType *)instance; }
template <> inline const ScriptTileList_StationType &GetParam(ForceType<const ScriptTileList_StationType &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTileList_StationType *)instance; }
- template <> inline int Return<ScriptTileList_StationType *>(HSQUIRRELVM vm, ScriptTileList_StationType *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "TileList_StationType", res, NULL, DefSQDestructorCallback<ScriptTileList_StationType>, true); return 1; }
+ template <> inline int Return<ScriptTileList_StationType *>(HSQUIRRELVM vm, ScriptTileList_StationType *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "TileList_StationType", res, nullptr, DefSQDestructorCallback<ScriptTileList_StationType>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_town.hpp.sq b/src/script/api/template/template_town.hpp.sq
index 0ec1c285d..30534fa8a 100644
--- a/src/script/api/template/template_town.hpp.sq
+++ b/src/script/api/template/template_town.hpp.sq
@@ -29,5 +29,5 @@ namespace SQConvert {
template <> inline ScriptTown &GetParam(ForceType<ScriptTown &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTown *)instance; }
template <> inline const ScriptTown *GetParam(ForceType<const ScriptTown *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptTown *)instance; }
template <> inline const ScriptTown &GetParam(ForceType<const ScriptTown &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTown *)instance; }
- template <> inline int Return<ScriptTown *>(HSQUIRRELVM vm, ScriptTown *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Town", res, NULL, DefSQDestructorCallback<ScriptTown>, true); return 1; }
+ template <> inline int Return<ScriptTown *>(HSQUIRRELVM vm, ScriptTown *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Town", res, nullptr, DefSQDestructorCallback<ScriptTown>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_townlist.hpp.sq b/src/script/api/template/template_townlist.hpp.sq
index 5bbd2e203..e3709b5b5 100644
--- a/src/script/api/template/template_townlist.hpp.sq
+++ b/src/script/api/template/template_townlist.hpp.sq
@@ -17,7 +17,7 @@ namespace SQConvert {
template <> inline ScriptTownList &GetParam(ForceType<ScriptTownList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTownList *)instance; }
template <> inline const ScriptTownList *GetParam(ForceType<const ScriptTownList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptTownList *)instance; }
template <> inline const ScriptTownList &GetParam(ForceType<const ScriptTownList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTownList *)instance; }
- template <> inline int Return<ScriptTownList *>(HSQUIRRELVM vm, ScriptTownList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "TownList", res, NULL, DefSQDestructorCallback<ScriptTownList>, true); return 1; }
+ template <> inline int Return<ScriptTownList *>(HSQUIRRELVM vm, ScriptTownList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "TownList", res, nullptr, DefSQDestructorCallback<ScriptTownList>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -26,5 +26,5 @@ namespace SQConvert {
template <> inline ScriptTownEffectList &GetParam(ForceType<ScriptTownEffectList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTownEffectList *)instance; }
template <> inline const ScriptTownEffectList *GetParam(ForceType<const ScriptTownEffectList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptTownEffectList *)instance; }
template <> inline const ScriptTownEffectList &GetParam(ForceType<const ScriptTownEffectList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTownEffectList *)instance; }
- template <> inline int Return<ScriptTownEffectList *>(HSQUIRRELVM vm, ScriptTownEffectList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "TownEffectList", res, NULL, DefSQDestructorCallback<ScriptTownEffectList>, true); return 1; }
+ template <> inline int Return<ScriptTownEffectList *>(HSQUIRRELVM vm, ScriptTownEffectList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "TownEffectList", res, nullptr, DefSQDestructorCallback<ScriptTownEffectList>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_tunnel.hpp.sq b/src/script/api/template/template_tunnel.hpp.sq
index 2d7eed91e..b003eae13 100644
--- a/src/script/api/template/template_tunnel.hpp.sq
+++ b/src/script/api/template/template_tunnel.hpp.sq
@@ -21,5 +21,5 @@ namespace SQConvert {
template <> inline ScriptTunnel &GetParam(ForceType<ScriptTunnel &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTunnel *)instance; }
template <> inline const ScriptTunnel *GetParam(ForceType<const ScriptTunnel *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptTunnel *)instance; }
template <> inline const ScriptTunnel &GetParam(ForceType<const ScriptTunnel &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptTunnel *)instance; }
- template <> inline int Return<ScriptTunnel *>(HSQUIRRELVM vm, ScriptTunnel *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Tunnel", res, NULL, DefSQDestructorCallback<ScriptTunnel>, true); return 1; }
+ template <> inline int Return<ScriptTunnel *>(HSQUIRRELVM vm, ScriptTunnel *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Tunnel", res, nullptr, DefSQDestructorCallback<ScriptTunnel>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_vehicle.hpp.sq b/src/script/api/template/template_vehicle.hpp.sq
index 999a9c507..d0e2f52b1 100644
--- a/src/script/api/template/template_vehicle.hpp.sq
+++ b/src/script/api/template/template_vehicle.hpp.sq
@@ -25,5 +25,5 @@ namespace SQConvert {
template <> inline ScriptVehicle &GetParam(ForceType<ScriptVehicle &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptVehicle *)instance; }
template <> inline const ScriptVehicle *GetParam(ForceType<const ScriptVehicle *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptVehicle *)instance; }
template <> inline const ScriptVehicle &GetParam(ForceType<const ScriptVehicle &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptVehicle *)instance; }
- template <> inline int Return<ScriptVehicle *>(HSQUIRRELVM vm, ScriptVehicle *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Vehicle", res, NULL, DefSQDestructorCallback<ScriptVehicle>, true); return 1; }
+ template <> inline int Return<ScriptVehicle *>(HSQUIRRELVM vm, ScriptVehicle *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Vehicle", res, nullptr, DefSQDestructorCallback<ScriptVehicle>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_vehiclelist.hpp.sq b/src/script/api/template/template_vehiclelist.hpp.sq
index dd1d17682..11dac4bc3 100644
--- a/src/script/api/template/template_vehiclelist.hpp.sq
+++ b/src/script/api/template/template_vehiclelist.hpp.sq
@@ -17,7 +17,7 @@ namespace SQConvert {
template <> inline ScriptVehicleList &GetParam(ForceType<ScriptVehicleList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptVehicleList *)instance; }
template <> inline const ScriptVehicleList *GetParam(ForceType<const ScriptVehicleList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptVehicleList *)instance; }
template <> inline const ScriptVehicleList &GetParam(ForceType<const ScriptVehicleList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptVehicleList *)instance; }
- template <> inline int Return<ScriptVehicleList *>(HSQUIRRELVM vm, ScriptVehicleList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "VehicleList", res, NULL, DefSQDestructorCallback<ScriptVehicleList>, true); return 1; }
+ template <> inline int Return<ScriptVehicleList *>(HSQUIRRELVM vm, ScriptVehicleList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "VehicleList", res, nullptr, DefSQDestructorCallback<ScriptVehicleList>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -26,7 +26,7 @@ namespace SQConvert {
template <> inline ScriptVehicleList_Station &GetParam(ForceType<ScriptVehicleList_Station &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptVehicleList_Station *)instance; }
template <> inline const ScriptVehicleList_Station *GetParam(ForceType<const ScriptVehicleList_Station *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptVehicleList_Station *)instance; }
template <> inline const ScriptVehicleList_Station &GetParam(ForceType<const ScriptVehicleList_Station &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptVehicleList_Station *)instance; }
- template <> inline int Return<ScriptVehicleList_Station *>(HSQUIRRELVM vm, ScriptVehicleList_Station *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "VehicleList_Station", res, NULL, DefSQDestructorCallback<ScriptVehicleList_Station>, true); return 1; }
+ template <> inline int Return<ScriptVehicleList_Station *>(HSQUIRRELVM vm, ScriptVehicleList_Station *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "VehicleList_Station", res, nullptr, DefSQDestructorCallback<ScriptVehicleList_Station>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -35,7 +35,7 @@ namespace SQConvert {
template <> inline ScriptVehicleList_Depot &GetParam(ForceType<ScriptVehicleList_Depot &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptVehicleList_Depot *)instance; }
template <> inline const ScriptVehicleList_Depot *GetParam(ForceType<const ScriptVehicleList_Depot *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptVehicleList_Depot *)instance; }
template <> inline const ScriptVehicleList_Depot &GetParam(ForceType<const ScriptVehicleList_Depot &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptVehicleList_Depot *)instance; }
- template <> inline int Return<ScriptVehicleList_Depot *>(HSQUIRRELVM vm, ScriptVehicleList_Depot *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "VehicleList_Depot", res, NULL, DefSQDestructorCallback<ScriptVehicleList_Depot>, true); return 1; }
+ template <> inline int Return<ScriptVehicleList_Depot *>(HSQUIRRELVM vm, ScriptVehicleList_Depot *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "VehicleList_Depot", res, nullptr, DefSQDestructorCallback<ScriptVehicleList_Depot>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -44,7 +44,7 @@ namespace SQConvert {
template <> inline ScriptVehicleList_SharedOrders &GetParam(ForceType<ScriptVehicleList_SharedOrders &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptVehicleList_SharedOrders *)instance; }
template <> inline const ScriptVehicleList_SharedOrders *GetParam(ForceType<const ScriptVehicleList_SharedOrders *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptVehicleList_SharedOrders *)instance; }
template <> inline const ScriptVehicleList_SharedOrders &GetParam(ForceType<const ScriptVehicleList_SharedOrders &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptVehicleList_SharedOrders *)instance; }
- template <> inline int Return<ScriptVehicleList_SharedOrders *>(HSQUIRRELVM vm, ScriptVehicleList_SharedOrders *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "VehicleList_SharedOrders", res, NULL, DefSQDestructorCallback<ScriptVehicleList_SharedOrders>, true); return 1; }
+ template <> inline int Return<ScriptVehicleList_SharedOrders *>(HSQUIRRELVM vm, ScriptVehicleList_SharedOrders *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "VehicleList_SharedOrders", res, nullptr, DefSQDestructorCallback<ScriptVehicleList_SharedOrders>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -53,7 +53,7 @@ namespace SQConvert {
template <> inline ScriptVehicleList_Group &GetParam(ForceType<ScriptVehicleList_Group &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptVehicleList_Group *)instance; }
template <> inline const ScriptVehicleList_Group *GetParam(ForceType<const ScriptVehicleList_Group *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptVehicleList_Group *)instance; }
template <> inline const ScriptVehicleList_Group &GetParam(ForceType<const ScriptVehicleList_Group &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptVehicleList_Group *)instance; }
- template <> inline int Return<ScriptVehicleList_Group *>(HSQUIRRELVM vm, ScriptVehicleList_Group *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "VehicleList_Group", res, NULL, DefSQDestructorCallback<ScriptVehicleList_Group>, true); return 1; }
+ template <> inline int Return<ScriptVehicleList_Group *>(HSQUIRRELVM vm, ScriptVehicleList_Group *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "VehicleList_Group", res, nullptr, DefSQDestructorCallback<ScriptVehicleList_Group>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -62,5 +62,5 @@ namespace SQConvert {
template <> inline ScriptVehicleList_DefaultGroup &GetParam(ForceType<ScriptVehicleList_DefaultGroup &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptVehicleList_DefaultGroup *)instance; }
template <> inline const ScriptVehicleList_DefaultGroup *GetParam(ForceType<const ScriptVehicleList_DefaultGroup *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptVehicleList_DefaultGroup *)instance; }
template <> inline const ScriptVehicleList_DefaultGroup &GetParam(ForceType<const ScriptVehicleList_DefaultGroup &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptVehicleList_DefaultGroup *)instance; }
- template <> inline int Return<ScriptVehicleList_DefaultGroup *>(HSQUIRRELVM vm, ScriptVehicleList_DefaultGroup *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "VehicleList_DefaultGroup", res, NULL, DefSQDestructorCallback<ScriptVehicleList_DefaultGroup>, true); return 1; }
+ template <> inline int Return<ScriptVehicleList_DefaultGroup *>(HSQUIRRELVM vm, ScriptVehicleList_DefaultGroup *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "VehicleList_DefaultGroup", res, nullptr, DefSQDestructorCallback<ScriptVehicleList_DefaultGroup>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_viewport.hpp.sq b/src/script/api/template/template_viewport.hpp.sq
index 8a187ae81..e5b44943b 100644
--- a/src/script/api/template/template_viewport.hpp.sq
+++ b/src/script/api/template/template_viewport.hpp.sq
@@ -17,5 +17,5 @@ namespace SQConvert {
template <> inline ScriptViewport &GetParam(ForceType<ScriptViewport &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptViewport *)instance; }
template <> inline const ScriptViewport *GetParam(ForceType<const ScriptViewport *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptViewport *)instance; }
template <> inline const ScriptViewport &GetParam(ForceType<const ScriptViewport &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptViewport *)instance; }
- template <> inline int Return<ScriptViewport *>(HSQUIRRELVM vm, ScriptViewport *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Viewport", res, NULL, DefSQDestructorCallback<ScriptViewport>, true); return 1; }
+ template <> inline int Return<ScriptViewport *>(HSQUIRRELVM vm, ScriptViewport *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Viewport", res, nullptr, DefSQDestructorCallback<ScriptViewport>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_waypoint.hpp.sq b/src/script/api/template/template_waypoint.hpp.sq
index 88cc495c9..613c3cbcc 100644
--- a/src/script/api/template/template_waypoint.hpp.sq
+++ b/src/script/api/template/template_waypoint.hpp.sq
@@ -23,5 +23,5 @@ namespace SQConvert {
template <> inline ScriptWaypoint &GetParam(ForceType<ScriptWaypoint &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptWaypoint *)instance; }
template <> inline const ScriptWaypoint *GetParam(ForceType<const ScriptWaypoint *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptWaypoint *)instance; }
template <> inline const ScriptWaypoint &GetParam(ForceType<const ScriptWaypoint &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptWaypoint *)instance; }
- template <> inline int Return<ScriptWaypoint *>(HSQUIRRELVM vm, ScriptWaypoint *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Waypoint", res, NULL, DefSQDestructorCallback<ScriptWaypoint>, true); return 1; }
+ template <> inline int Return<ScriptWaypoint *>(HSQUIRRELVM vm, ScriptWaypoint *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Waypoint", res, nullptr, DefSQDestructorCallback<ScriptWaypoint>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_waypointlist.hpp.sq b/src/script/api/template/template_waypointlist.hpp.sq
index 2e23bba14..7c2330964 100644
--- a/src/script/api/template/template_waypointlist.hpp.sq
+++ b/src/script/api/template/template_waypointlist.hpp.sq
@@ -17,7 +17,7 @@ namespace SQConvert {
template <> inline ScriptWaypointList &GetParam(ForceType<ScriptWaypointList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptWaypointList *)instance; }
template <> inline const ScriptWaypointList *GetParam(ForceType<const ScriptWaypointList *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptWaypointList *)instance; }
template <> inline const ScriptWaypointList &GetParam(ForceType<const ScriptWaypointList &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptWaypointList *)instance; }
- template <> inline int Return<ScriptWaypointList *>(HSQUIRRELVM vm, ScriptWaypointList *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "WaypointList", res, NULL, DefSQDestructorCallback<ScriptWaypointList>, true); return 1; }
+ template <> inline int Return<ScriptWaypointList *>(HSQUIRRELVM vm, ScriptWaypointList *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "WaypointList", res, nullptr, DefSQDestructorCallback<ScriptWaypointList>, true); return 1; }
} // namespace SQConvert
namespace SQConvert {
@@ -26,5 +26,5 @@ namespace SQConvert {
template <> inline ScriptWaypointList_Vehicle &GetParam(ForceType<ScriptWaypointList_Vehicle &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptWaypointList_Vehicle *)instance; }
template <> inline const ScriptWaypointList_Vehicle *GetParam(ForceType<const ScriptWaypointList_Vehicle *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptWaypointList_Vehicle *)instance; }
template <> inline const ScriptWaypointList_Vehicle &GetParam(ForceType<const ScriptWaypointList_Vehicle &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptWaypointList_Vehicle *)instance; }
- template <> inline int Return<ScriptWaypointList_Vehicle *>(HSQUIRRELVM vm, ScriptWaypointList_Vehicle *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "WaypointList_Vehicle", res, NULL, DefSQDestructorCallback<ScriptWaypointList_Vehicle>, true); return 1; }
+ template <> inline int Return<ScriptWaypointList_Vehicle *>(HSQUIRRELVM vm, ScriptWaypointList_Vehicle *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "WaypointList_Vehicle", res, nullptr, DefSQDestructorCallback<ScriptWaypointList_Vehicle>, true); return 1; }
} // namespace SQConvert
diff --git a/src/script/api/template/template_window.hpp.sq b/src/script/api/template/template_window.hpp.sq
index 3077215ec..c0d3f59de 100644
--- a/src/script/api/template/template_window.hpp.sq
+++ b/src/script/api/template/template_window.hpp.sq
@@ -259,5 +259,5 @@ namespace SQConvert {
template <> inline ScriptWindow &GetParam(ForceType<ScriptWindow &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptWindow *)instance; }
template <> inline const ScriptWindow *GetParam(ForceType<const ScriptWindow *>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return (ScriptWindow *)instance; }
template <> inline const ScriptWindow &GetParam(ForceType<const ScriptWindow &>, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer instance; sq_getinstanceup(vm, index, &instance, 0); return *(ScriptWindow *)instance; }
- template <> inline int Return<ScriptWindow *>(HSQUIRRELVM vm, ScriptWindow *res) { if (res == NULL) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Window", res, NULL, DefSQDestructorCallback<ScriptWindow>, true); return 1; }
+ template <> inline int Return<ScriptWindow *>(HSQUIRRELVM vm, ScriptWindow *res) { if (res == nullptr) { sq_pushnull(vm); return 1; } res->AddRef(); Squirrel::CreateClassInstanceVM(vm, "Window", res, nullptr, DefSQDestructorCallback<ScriptWindow>, true); return 1; }
} // namespace SQConvert