WORLDSBIGGEST Posted June 28, 2016 Share Posted June 28, 2016 Hey! I've been working on reskinning/tweaking @afro1967's cabin mod as a way of practicing code, but after a couple weeks of struggling with a couple concepts I might as well ask for help The two main functions I would like to add: Making the hunger meter go up while sleeping. The code seems solid in original DS, but nothing I've tried in DST has had the same effect. I'm not sure if it's possible with the way sleeping works in DST? I'm probably wrong. Working as both a place to sleep and a container at the same time. I'm thinking a good way to do this would be to have it so you could hold down ctrl while mousing over, but I'm not sure how to make that work while holding a hammer or torch or something. I have a couple other ideas, but they kind of hang on these two concepts working. In the meantime hey look at the new cabin I drew Link to comment https://forums.kleientertainment.com/forums/topic/68527-need-help-tweaking-mod/ Share on other sites More sharing options...
DarkXero Posted June 29, 2016 Share Posted June 29, 2016 19 hours ago, WORLDSBIGGEST said: The code seems solid in original DS, but nothing I've tried in DST has had the same effect. I'm not sure if it's possible with the way sleeping works in DST? The DS tent code is obsolete for DST. You have to pretty much copy the new DST tent code. 19 hours ago, WORLDSBIGGEST said: these two concepts working ComboTest.zip Link to comment https://forums.kleientertainment.com/forums/topic/68527-need-help-tweaking-mod/#findComment-788529 Share on other sites More sharing options...
WORLDSBIGGEST Posted June 29, 2016 Author Share Posted June 29, 2016 it works beautifully, thank you!! also the notes you made in the lua files are incredibly helpful, so thank you for that as well <3 Link to comment https://forums.kleientertainment.com/forums/topic/68527-need-help-tweaking-mod/#findComment-788534 Share on other sites More sharing options...
WORLDSBIGGEST Posted June 29, 2016 Author Share Posted June 29, 2016 this is probably really obvious, but I tried replacing the assets: The cabin showed up alright and worked as a proper container, but once I tried to sleep it vanished and I got this error message. What did I do cabin.rar Link to comment https://forums.kleientertainment.com/forums/topic/68527-need-help-tweaking-mod/#findComment-788577 Share on other sites More sharing options...
Aquaterion Posted June 29, 2016 Share Posted June 29, 2016 in line 136 ur comparing your temperature with "TUNING.SLEEP_TARGET_TEMP_CABIN" yet I don't see any of these tuning values declared anywhere. Link to comment https://forums.kleientertainment.com/forums/topic/68527-need-help-tweaking-mod/#findComment-788585 Share on other sites More sharing options...
WORLDSBIGGEST Posted June 29, 2016 Author Share Posted June 29, 2016 4 hours ago, Aquaterion said: in line 136 ur comparing your temperature with "TUNING.SLEEP_TARGET_TEMP_CABIN" yet I don't see any of these tuning values declared anywhere. Ah yep, looks like I screwed up doing a find>replace command somehow. Thanks! Link to comment https://forums.kleientertainment.com/forums/topic/68527-need-help-tweaking-mod/#findComment-788648 Share on other sites More sharing options...
WORLDSBIGGEST Posted June 29, 2016 Author Share Posted June 29, 2016 I coded a recipe, and it shows up ingame and can be crafted no problem, but now if I try to open the cabin it immediately closes again. It plays the sounds and I can still store items(if I drag the item to the cabin itself), though. https://dl.dropboxusercontent.com/u/104514748/cabin.rar (the night and sleep_loop anim files are just placeholders, eventually ill go back and animate the curtains moving) Link to comment https://forums.kleientertainment.com/forums/topic/68527-need-help-tweaking-mod/#findComment-788715 Share on other sites More sharing options...
DarkXero Posted June 30, 2016 Share Posted June 30, 2016 Changed the recipe of modmain to use AddRecipe so it sets up the RPC. But the issue was fixed in cabin.lua. When you are 3 units away from a container, it closes. But the cabin is huge so it needs the closing range upped. cabin.zip Link to comment https://forums.kleientertainment.com/forums/topic/68527-need-help-tweaking-mod/#findComment-788809 Share on other sites More sharing options...
WORLDSBIGGEST Posted June 30, 2016 Author Share Posted June 30, 2016 1 hour ago, DarkXero said: Changed the recipe of modmain to use AddRecipe so it sets up the RPC. But the issue was fixed in cabin.lua. When you are 3 units away from a container, it closes. But the cabin is huge so it needs the closing range upped. cabin.zip AAaaa thank you so much again! I really appreciate the help and hope me messing with the code wasn't annoying or insulting or anything like that ;u; If I post this should I credit you as DarkXero, or is there a different handle you prefer? Link to comment https://forums.kleientertainment.com/forums/topic/68527-need-help-tweaking-mod/#findComment-788825 Share on other sites More sharing options...
DarkXero Posted June 30, 2016 Share Posted June 30, 2016 25 minutes ago, WORLDSBIGGEST said: AAaaa thank you so much again! I really appreciate the help and hope me messing with the code wasn't annoying or insulting or anything like that ;u; If I post this should I credit you as DarkXero, or is there a different handle you prefer? You did good. The closing of containers has a hardcoded range, for stuff that is small, so it clashed with the big cabin. You don't need to give me credit. Post whatever you like. Link to comment https://forums.kleientertainment.com/forums/topic/68527-need-help-tweaking-mod/#findComment-788828 Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now