From c2689cbe6debe697fe3b7b72b4de5cce70c7f7d1 Mon Sep 17 00:00:00 2001 From: Teabone <35990109+Teabone3@users.noreply.github.com> Date: Mon, 9 Mar 2026 17:57:26 -0400 Subject: [PATCH] Create storyinzone_noskip.lua New optional script for story zone that prevents player from being able to skip the video. --- .../scriptbank/storyinzone_noskip.lua | 36 +++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 GameGuru Core/GameGuru/Shaders and Scripts/scriptbank/storyinzone_noskip.lua diff --git a/GameGuru Core/GameGuru/Shaders and Scripts/scriptbank/storyinzone_noskip.lua b/GameGuru Core/GameGuru/Shaders and Scripts/scriptbank/storyinzone_noskip.lua new file mode 100644 index 00000000..5f62f39f --- /dev/null +++ b/GameGuru Core/GameGuru/Shaders and Scripts/scriptbank/storyinzone_noskip.lua @@ -0,0 +1,36 @@ +-- LUA Script - precede every function and global member with lowercase name of script + '_main' +-- Player Enters Story Zone +-- Play Video without the ability to skip the video + +g_storyinzone_mode = {} + +function storyinzone_noskip_init(e) + g_storyinzone_mode[e] = 0 +end + +function storyinzone_noskip_main(e) + if g_Entity[e]['plrinzone']==1 then + if g_storyinzone_mode[e] ~= nil then + if g_storyinzone_mode[e] == 0 then + g_storyinzone_mode[e] = 1 + HideHuds() + if radar_hideallsprites ~= nil then radar_hideallsprites() end + else + if g_storyinzone_mode[e] == 1 then + PlaySound(e,0) + PlayVideoNoSkip(e,1) + StopSound(e,0) + g_storyinzone_mode[e] = 2 + else + if g_storyinzone_mode[e] == 2 then + if radar_showallsprites ~= nil then radar_showallsprites() end + ShowHuds() + Destroy(e) + ActivateIfUsed(e) + g_storyinzone_mode[e] = 3 + end + end + end + end + end +end