Aminados Posted May 7 Share Posted May 7 (edited) So I'm trying to make a simple script for UE4SS where it does a console command depending on if i'm indoors or outdoors. I have it working but... Right now it's doing X if indoors and Y if outdoors, my problem is that inside an oblivion gate is considered outdoors and instead i want it to do X as if I was indoors The code is the following NotifyOnNewObject("/Script/Altar.AltarCommonGameViewportClient", function(viewPort) RegisterHook("/Script/Altar.VLevelChangeData:OnFadeToBlackBeginEventReceived", function(context) ksl:ExecuteConsoleCommand(engine, "X", nil) end) RegisterHook("/Script/Altar.VLevelChangeData:OnFadeToGameBeginEventReceived", function(context) local world = viewPort.World:GetFullName() if world:find("World/") then ksl:ExecuteConsoleCommand(engine, "Y", nil) end end) end) How would i differentiate if outdoors in world or outdoors inside an oblivion gate? Edited May 7 by Aminados Link to comment Share on other sites More sharing options...
Noobatron22 Posted May 8 Share Posted May 8 While I have absolutely no experience writing script for UE4SS, I believe I see the problem: your script is doing Y for all world spaces and an oblivion gate is technically a world space itself as it has weather (even if it is just a red sky), so you'll have to adjust your script to exclude the oblivion gate world space via keyword and use a "not equal to" command to exclude oblivion gates specifically. Link to comment Share on other sites More sharing options...
Recommended Posts