MikeRobe Posted December 22, 2014 Share Posted December 22, 2014 Hi everyone, I made a couple of character mods that work wonderfully with regular Don't Starve, but I cannot seem to get them working with DST. What changes need to be made to the DS mods to make them compatible with DST? One thing I've noticed is this error:[string "../mods/micah/scripts/prefabs/mic.lua"]:48: attempt to index field 'combat' (a nil value)LUA ERROR stack traceback:scripts/prefabs/player_common.lua:1015 in (field) fn (Lua) <949-1214> inst = 116376 - (valid:true)scripts/mainfunctions.lua:133 in () ? (Lua) <122-153> name = mic prefab = Prefab mic - =[C]:-1 in (method) SendSpawnRequestToServer (C) <-1--1>scripts/mainfunctions.lua:1114 in (local) cb (Lua) <1112-1118>scripts/frontend.lua:427 in (method) DoFadingUpdate (Lua) <391-431> self = tracking_mouse = true fade_title_out = false ignoreups = table: 09AE90B8 overlayroot = overlayroot screenroot = screenroot save_indicator_fade_time = 0 page_repeat_time = 0.25 helptextbg = Image - images/global.xml:square.tex helptext = HelpText subtitle = Text - updating_widgets_alt = table: 0A8DD068 title = Text - topFadeHidden = false gameinterface = 100012 - (valid:true) updating_widgets = table: 09ADB1C0 lastx = 1402 fade_time = 1.0166288278997 lasty = 117 autosave_enabled = true repeat_time = 0 blackoverlay = Image - images/global.xml:square.tex screenstack = table: 09AE88E8 displayingerror = false fade_title_time = 0 saving_indicator = UIAnim topblackoverlay = Image - images/global.xml:square.tex alpha = 1.0000045981689 focus_locked = false consoletext = Text - CONSOLE TEXT fade_title_in = false forceProcessText = false save_indicator_time_left = 0 total_fade_time = 1 num_pending_saves = 0 helptexttext = Text - dt = 0.016666611656547 alpha = 1.0000045981689 cb = function - scripts/mainfunctions.lua:1112scripts/frontend.lua:482 in (method) Update (Lua) <439-579> self = tracking_mouse = true fade_title_out = false ignoreups = table: 09AE90B8 overlayroot = overlayroot screenroot = screenroot save_indicator_fade_time = 0 page_repeat_time = 0.25 helptextbg = Image - images/global.xml:square.tex helptext = HelpText subtitle = Text - updating_widgets_alt = table: 0A8DD068 title = Text - topFadeHidden = false gameinterface = 100012 - (valid:true) updating_widgets = table: 09ADB1C0 lastx = 1402 fade_time = 1.0166288278997 lasty = 117 autosave_enabled = true repeat_time = 0 blackoverlay = Image - images/global.xml:square.tex screenstack = table: 09AE88E8 displayingerror = false fade_title_time = 0 saving_indicator = UIAnim topblackoverlay = Image - images/global.xml:square.tex alpha = 1.0000045981689 focus_locked = false consoletext = Text - CONSOLE TEXT fade_title_in = false forceProcessText = false save_indicator_time_left = 0 total_fade_time = 1 num_pending_saves = 0 helptexttext = Text - dt = 0.016666611656547scripts/update.lua:91 in () ? (Lua) <39-95> dt = 0.016666611656547SCRIPT ERROR! Showing error screen QueryServerComplete no callbackQueryServerComplete no callbackCould not unload undefined prefab 0x20e21d7a (puppet_wes)Could not unload undefined prefab 0x20e21d7a (puppet_wes)Could not unload undefined prefab 0x20e21d7a (puppet_wes)unloading prefabs for mod MOD_micah Left room 109775241696864720Collecting garbage...lua_gc took 0.11 seconds~NetworkLuaProxy()~SimLuaProxy()lua_close took 0.21 secondsHttpClient::ClientThread::Main() completeHttpClient::ClientThread::Main() completeCould not unload undefined prefab 0x20e21d7a (puppet_wes)Could not unload undefined prefab 0x20e21d7a (puppet_wes)Orphaned unnamed resource. This resource must have used Add( resource ) to insert itself into the manager. Orphaned unnamed resource. This resource must have used Add( resource ) to insert itself into the manager. Orphaned unnamed resource. This resource must have used Add( resource ) to insert itself into the manager. Orphaned unnamed resource. This resource must have used Add( resource ) to insert itself into the manager. Orphaned unnamed resource. This resource must have used Add( resource ) to insert itself into the manager. Orphaned unnamed resource. This resource must have used Add( resource ) to insert itself into the manager. Orphaned unnamed resource. This resource must have used Add( resource ) to insert itself into the manager. HttpClient::ClientThread::Main() completeShutting down Link to comment Share on other sites More sharing options...
rezecib Posted December 22, 2014 Share Posted December 22, 2014 @MikeRobe, You should take a look at how the game's built-in character prefabs have changed between DS and DST. I'm guessing the problem you're running into here is that you haven't split the fn() function into common_postinit and master_postinit, so it's running stuff that needs to be in the master_postinit in the common_postinit. I talked a bit more about these two functions here: http://forums.kleientertainment.com/topic/45515-help-attempting-to-update-wisteria/?p=579914 Link to comment Share on other sites More sharing options...
MikeRobe Posted December 22, 2014 Author Share Posted December 22, 2014 Hey, thanks. Looks like that got it working. I had a look at another mod, simply putting my modifiers insidelocal master_postinit = function(inst)was enough. Awesome, thanks! Link to comment 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