XirmiX Posted May 25, 2014 Share Posted May 25, 2014 So I follower a Set piece tutorial and it was real great until one point. My question is: If the Set piece data is not supposed to be in modmain.lua but in a specific folder of your mod, then what do you write in the modmain?! And can someone explain how this works and where to write it (I know what it does, just don't know how it works and where it's from): local Layouts = GLOBAL.require("map/layouts").Layoutslocal StaticLayout = GLOBAL.require("map/static_layout") Layouts["ResearchLab"] = StaticLayout.Get("map/static_layouts/rl") AddRoomPreInit("Forest", function(room) if not room.contents.countstaticlayouts then room.contents.countstaticlayouts = {} end room.contents.countstaticlayouts["ResearchLab"] = 1end) Link to comment https://forums.kleientertainment.com/forums/topic/36833-63-wat-i-understand-set-piece-making-stuff-up-until-a-certain-extent/ Share on other sites More sharing options...
JackSlender Posted May 26, 2014 Share Posted May 26, 2014 (edited) You put that function in your modmain. The files that you store in your map folder are the files containing the actual code, but you define you levels and such in your modmain.That's how I do it, anyway. Edited May 26, 2014 by JackSlender Link to comment https://forums.kleientertainment.com/forums/topic/36833-63-wat-i-understand-set-piece-making-stuff-up-until-a-certain-extent/#findComment-489029 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