Wisteria Posted January 20, 2014 Share Posted January 20, 2014 Hi, everyone! I'm looking to increase the gathering speed of plant-related items (berries, saplings, etc) for my custom character. Problem is, I have no idea where to start searching in terms of the code. I've dug around here on the forums and on google to no avail.If possible, I'd like to just make it an increase to gathering speed and not instant.If not, is there a way to perhaps double what can be collected from these plants?I'd greatly appreciate the help! ♥ Link to comment https://forums.kleientertainment.com/forums/topic/31040-help-increase-to-gathering-speed/ Share on other sites More sharing options...
NikMik Posted January 20, 2014 Share Posted January 20, 2014 I'm not too good at explaining, but here goes... I use stategraphs. What I did was copy the "SGwilson" file from the Stategraphs folder, put it in my own Stategraphs folder in my mod's folder (in scripts). then I just renamed it SGwilliam. Inside the stategraphs you find all the animations, sound-ques, all neatly packed into their own actionhandlers and eventhandlers and what-not. I'm sure you can figure it out on your own. If not, I kind of know how to work them...after about 30 tries before finally realizing I forgot to add an "end". I may be able to help. Link to comment https://forums.kleientertainment.com/forums/topic/31040-help-increase-to-gathering-speed/#findComment-406504 Share on other sites More sharing options...
GalloViking Posted January 20, 2014 Share Posted January 20, 2014 If this is too hard, you can still double what your characters gather. It's virtualy the same thing, and I guess it's easier code? Link to comment https://forums.kleientertainment.com/forums/topic/31040-help-increase-to-gathering-speed/#findComment-406509 Share on other sites More sharing options...
NikMik Posted January 20, 2014 Share Posted January 20, 2014 (edited) All you'd have to do is change: ActionHandler(ACTIONS.PICK, function(inst, action) if action.target.components.pickable then if action.target.components.pickable.quickpick then return "doshortaction" else return "dolongaction" end end end), to: ActionHandler(ACTIONS.PICK, "doshortaction")in the Stategraph. Unless you just want the animation to play really fast. Don't know how to do that. Edited January 20, 2014 by Mr. Tiddles Link to comment https://forums.kleientertainment.com/forums/topic/31040-help-increase-to-gathering-speed/#findComment-406522 Share on other sites More sharing options...
Wisteria Posted January 20, 2014 Author Share Posted January 20, 2014 (edited) @Mr. Tiddles Alright, cool! Thank you so much! I'm going to give this a shot!@GalloViking I considered that, but for some reason I feel getting two of the same material at one may make it a bit OP. I'll have to play around with it some more. EDIT:I tried changing that bit of code and I placed the file in a stategraphs folder in the mod folder, like you said to. Is there something I need to change in another file to link the mod to the SG file? And I keep that final 'end,' right? Edited January 20, 2014 by Wisteria Link to comment https://forums.kleientertainment.com/forums/topic/31040-help-increase-to-gathering-speed/#findComment-406529 Share on other sites More sharing options...
no_signal Posted January 20, 2014 Share Posted January 20, 2014 you can just put this in your character's fn function local handle = inst.sg.sg.actionhandlers[ACTIONS.PICK]handle.deststate = function(inst) return "doshortaction" end this way you don't have to change SGwilson.lua Link to comment https://forums.kleientertainment.com/forums/topic/31040-help-increase-to-gathering-speed/#findComment-406533 Share on other sites More sharing options...
NikMik Posted January 20, 2014 Share Posted January 20, 2014 you can just put this in your character's fn function local handle = inst.sg.sg.actionhandlers[ACTIONS.PICK]handle.deststate = function(inst) return "doshortaction" end this way you don't have to change SGwilson.luaThat would probably work better for this, yeah. Link to comment https://forums.kleientertainment.com/forums/topic/31040-help-increase-to-gathering-speed/#findComment-406534 Share on other sites More sharing options...
Wisteria Posted January 20, 2014 Author Share Posted January 20, 2014 you can just put this in your character's fn function local handle = inst.sg.sg.actionhandlers[ACTIONS.PICK]handle.deststate = function(inst) return "doshortaction" end this way you don't have to change SGwilson.luaAmazing! That did the trick! Thank you so much for the help, guys! Link to comment https://forums.kleientertainment.com/forums/topic/31040-help-increase-to-gathering-speed/#findComment-406540 Share on other sites More sharing options...
no_signal Posted January 20, 2014 Share Posted January 20, 2014 Amazing! That did the trick! Thank you so much for the help, guys! You're welcome. Link to comment https://forums.kleientertainment.com/forums/topic/31040-help-increase-to-gathering-speed/#findComment-406547 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