YouDoNotKnowMyName Posted May 30, 2020 Share Posted May 30, 2020 Good evening everybody! What I want to do is this: Make a mod that makes the "craftable" plants at settlements take a few in-game months to "grow", so it would be a bit more realistic. Obviously that would also have some issues with cell-reset (cells reset after a few in-game weeks / days / whatever). So, how would one do this? And would there be any impact on things like performance or "savegame-size"? If anybody knows anything about this, let me know here ... (I fear that this could be another one of those "great ideas" that get cut off by stupid limitations of the FO4 game system ...) Link to comment Share on other sites More sharing options...
SKKmods Posted May 30, 2020 Share Posted May 30, 2020 Did something like that for workshop plantable wild plants. Attach a script like this to your base flora forms and set the global variable to the number of game hours or days to grow; Scriptname SKK_MWFloraScript extends ObjectReference Const ActorValue Property pSKK_MWTimeStamp Auto Const Mandatory GlobalVariable Property pSKK_MWFloraRegrowthGameHours Auto Const Mandatory ;GameDaysPassed Hours: (1/24) = .04167 ;Default regrowth is 24 game hours from harvest, the plant does not update unless the player ;leaves and returns so it can unload/load to refresh. ;********************************************************************************************** Event OnInit() Self.SetHarvested(TRUE) Self.SetValue(pSKK_MWTimeStamp, Utility.GetCurrentGameTime()) EndEvent ;********************************************************************************************** Event OnLoad() UpdateHarvested() EndEvent ;********************************************************************************************** Event OnActivate(ObjectReference akActionObject) Self.SetHarvested(TRUE) Self.SetValue(pSKK_MWTimeStamp, Utility.GetCurrentGameTime()) EndEvent ;********************************************************************************************** Function UpdateHarvested() ; cf "SKK_MWFloraScript.UpdateHarvested" If (GameHoursToGo() <= 0) Self.SetHarvested(FALSE) EndIf EndFunction ;********************************************************************************************** Float Function GameHoursToGo() Float fReturnValue = (((Self.GetValue(pSKK_MWTimeStamp) + (pSKK_MWFloraRegrowthGameHours.GetValue() * 0.04167)) - Utility.GetCurrentGameTime()) / 0.04167) Return fReturnValue EndFunction ;********************************************************************************************** Link to comment Share on other sites More sharing options...
YouDoNotKnowMyName Posted May 31, 2020 Author Share Posted May 31, 2020 Thanks you!I will try that ... Link to comment Share on other sites More sharing options...
Recommended Posts