-ICEMAN- Posted June 6, 2022 Share Posted June 6, 2022 Is there any option like console command or variable in Save File or some kind of Save Editor that gives a possibility of changing Day on Clock? Link to comment Share on other sites More sharing options...
Just-guy Posted June 6, 2022 Share Posted June 6, 2022 You mean like, jumping to the next day? Making days last longer/shorter? Link to comment Share on other sites More sharing options...
Maxposting Posted June 6, 2022 Share Posted June 6, 2022 Yes, but you can't go back. Link to comment Share on other sites More sharing options...
-ICEMAN- Posted June 6, 2022 Author Share Posted June 6, 2022 I don't mean coming back to that specific day, I just want to change Day on Clock. If there's an option, so what's that option? Link to comment Share on other sites More sharing options...
Just-guy Posted June 6, 2022 Share Posted June 6, 2022 Do you mean like changing from "Day 1" to "Day 4" quickly? Link to comment Share on other sites More sharing options...
-ICEMAN- Posted June 6, 2022 Author Share Posted June 6, 2022 I mean change (only on clock) from for example day 70 to 61 Link to comment Share on other sites More sharing options...
Just-guy Posted June 6, 2022 Share Posted June 6, 2022 Rolling back to an earlier day without your world changing? I'm not sure that is possible. Link to comment Share on other sites More sharing options...
-ICEMAN- Posted June 6, 2022 Author Share Posted June 6, 2022 I just want to change number on a clock, In save files I'm pretty sure that there is a file with variable which holds current day Link to comment Share on other sites More sharing options...
deemo_ Posted June 6, 2022 Share Posted June 6, 2022 OP means changing the day value on the clock without actually rolling back or moving forward to that day. Basically having a fake day on your clock. I have no idea how to do this I thought I should just clarify for those who don’t know what OP means. Link to comment Share on other sites More sharing options...
Maxposting Posted June 6, 2022 Share Posted June 6, 2022 5 hours ago, -ICEMAN- said: I mean change (only on clock) from for example day 70 to 61 12 hours ago, __IvoCZE__ said: Yes, but you can't go back. you can't change them downwards. Link to comment Share on other sites More sharing options...
maradyne Posted June 6, 2022 Share Posted June 6, 2022 So... you're just wanting to change the number displayed on the clock, not anything else. If you can find the relevant file, it ought to be doable by adjusting the bit of code where the number is fetched, having it subtract 7 or whatever from the number displayed (not the actual value of course, unless you want blood raining fron the sky). Or just have it used a predefined number rather than fetching one. Don't know where that is exactly and can't look atm, but there's the basic idea. Link to comment Share on other sites More sharing options...
Bumber64 Posted June 7, 2022 Share Posted June 7, 2022 Might be worth looking at these files: scripts\widgets\uiclock.lua scripts\components\clock.lua scripts\components\shard_clock.lua scripts\components\worldstate.lua Look for mentions of cycles and _cycles. The solution could be as simple as entering a command like "TheWorld.components.worldstate.data.cycles = 60". However, I suspect you'll need to do everything that the function "SetVariable" does in worldstate.lua to prevent it from reverting to the previous value. Moderate to severe risk of the game exploding spectacularly. 10 hours ago, maradyne said: If you can find the relevant file, it ought to be doable by adjusting the bit of code where the number is fetched, having it subtract 7 or whatever from the number displayed That would be in widgets/uiclock.lua: function UIClock:UpdateWorldString() if self._cycles ~= nil then local day_text = subfmt(STRINGS.UI.HUD.WORLD_CLOCKDAY_V2,{day_count = self._cycles + 1}) self._text:SetString(day_text) end self._showingcycles = true end Link to comment Share on other sites More sharing options...
-ICEMAN- Posted June 7, 2022 Author Share Posted June 7, 2022 Where are those files? Link to comment Share on other sites More sharing options...
hhh2 Posted June 7, 2022 Share Posted June 7, 2022 4 hours ago, -ICEMAN- said: Where are those files? In DST the game's scripts are stored in data/databundles/scripts.zip as a .zip archive. You will need a program that can read .zip files to view or unzip the archive. Link to comment Share on other sites More sharing options...
-ICEMAN- Posted June 8, 2022 Author Share Posted June 8, 2022 On 6/7/2022 at 7:38 AM, Bumber64 said: Might be worth looking at these files: scripts\widgets\uiclock.lua scripts\components\clock.lua scripts\components\shard_clock.lua scripts\components\worldstate.lua Look for mentions of cycles and _cycles. The solution could be as simple as entering a command like "TheWorld.components.worldstate.data.cycles = 60". However, I suspect you'll need to do everything that the function "SetVariable" does in worldstate.lua to prevent it from reverting to the previous value. Moderate to severe risk of the game exploding spectacularly. That would be in widgets/uiclock.lua: function UIClock:UpdateWorldString() if self._cycles ~= nil then local day_text = subfmt(STRINGS.UI.HUD.WORLD_CLOCKDAY_V2,{day_count = self._cycles + 1}) self._text:SetString(day_text) end self._showingcycles = true end Okay I found this function. What should I do next? Link to comment Share on other sites More sharing options...
Bumber64 Posted June 9, 2022 Share Posted June 9, 2022 Create a mod that replaces the function with something like: function UIClock:UpdateWorldString() if self._cycles ~= nil then local day_text = subfmt(STRINGS.UI.HUD.WORLD_CLOCKDAY_V2,{day_count = math.max(1, self._cycles - 9)}) self._text:SetString(day_text) end self._showingcycles = true end That would make the day look like 10 days earlier (for any day past day 10.) Link to comment Share on other sites More sharing options...
-ICEMAN- Posted June 11, 2022 Author Share Posted June 11, 2022 How can I replace this function? Link to comment Share on other sites More sharing options...
Bumber64 Posted June 13, 2022 Share Posted June 13, 2022 On 6/11/2022 at 2:08 PM, -ICEMAN- said: How can I replace this function? Create a copy of uiclock.lua, change the function in the copy using a text editor. Create a mod (see modding section of forums) and put your copy in folders scripts\widgets\ of your mod. Link to comment Share on other sites More sharing options...
Friendly Grass Posted June 13, 2022 Share Posted June 13, 2022 Here you are! STRINGS.UI.HUD.WORLD_CLOCKDAY_V2 = "Day 61" You want to run this on Local (not Remote) (press control in console to toggle) This text will stay constant in your game session (the day number will not increment). Put whatever text you want to be displayed within the quotes. Link to comment Share on other sites More sharing options...
-ICEMAN- Posted June 14, 2022 Author Share Posted June 14, 2022 On 6/13/2022 at 3:24 AM, Bumber64 said: Create a copy of uiclock.lua, change the function in the copy using a text editor. Create a mod (see modding section of forums) and put your copy in folders scripts\widgets\ of your mod. Okay I tried and It doesn't work or I'm doing something wrong. I tried client mod and server mod. Both zipped and unzipped folder Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.
Please be aware that the content of this thread may be outdated and no longer applicable.