aviform Posted March 25, 2013 Share Posted March 25, 2013 For example, in camping mods where you buy the models, then go into sneak to place/take tents, furniture, etc. I'd like to add something like this. I know I have to make a model to be the "grab-able" model, since the static will stay static, but aside from that, is there a coding template to work off of? Link to comment Share on other sites More sharing options...
Jason2112 Posted March 25, 2013 Share Posted March 25, 2013 (edited) There is no CK book, however Youtube and the web are full of examples ... Also you can load up mods and break them down. Most mod makers will leave their scripts. Off the top of my head I can think of one mod maker that created a mod similar to what you're asking. Have a look at [ Kagrenacs Instant Fortress ] mod ... download [ C ] I think. Edited March 25, 2013 by Jason2112 Link to comment Share on other sites More sharing options...
aviform Posted March 25, 2013 Author Share Posted March 25, 2013 Could you find a link to such a tutorial? I've looked and looked, but youtube only showcases the placeable statics mod, not actually tells you how to achieve a similar effect. Link to comment Share on other sites More sharing options...
aviform Posted March 26, 2013 Author Share Posted March 26, 2013 Bump... Link to comment Share on other sites More sharing options...
unuroboros Posted March 26, 2013 Share Posted March 26, 2013 You probably won't be working with statics, but with furniture. Depending on what you want to set down, you may need to make your own custom furniture item, too. The mod you want to crack open and use to learn from is Frostfall. It uses the "drop and place" method and Chesko is a very experienced modder, plus all his scripts are included. There's a much simpler model you can use if you need to get the hang of Papyrus first (this is going to be a lot harder if you're learning Papyrus at the same time!), which is to "swap out" instead of "drop and place." In this method you have a Misc item in your inventory, drop it, and then it immediately becomes furniture or you sneak-activate it and it becomes furniture. This is really easy to set up, actually. I added a bedroll item in my own mod with this method and it took all of 15 minutes. :) Send me a PM if you need help with the second method. I haven't looked into the first method myself, haven't needed it yet. Link to comment Share on other sites More sharing options...
timstertimster Posted February 20, 2014 Share Posted February 20, 2014 Well.. I've been trying to figure this out for a week now and finally worked it out. And since I rely on you all out there to share your knowledge, it's only fair I add to this collective "Dovahkiin's Creation Kit Encyclopedia"... Find the object the player should have in their inventory to place, and notate the CK object ID. You will need it later to select from a CK drop down list. Click EDIT and copy the NIF file path (click inline edit to be able to copy), and close editor (no changes) In Object window, navigate to static/clutter Right click and select NEW, set an ID and paste NIF path, then save. Select newly created object and and place it where you want it in the room. That's the placeholder (it won't initially appear in the list, so go to "All" and filter for it) Edit and set this object to initially disabled do not havok settle do not respawn With the placeholder active in render window, click "T in the box icon" in toolbar to make a trigger, choose NEW from list, name it and save In Render window, edit trigger: In 3D make sure z-rotation is not 0. This is important due to a bug in game that disables triggers that are exactly 0 on grid. In Primitive, set to player activate. Otherwise you won't see a prompt in game. In Linked Reference, create new and select the placeholder. This is when you realize naming your custom stuff well is important. You can't use "select in render window" because your trigger is covering the object. In Scripts, add this script:Scriptname myCoolPlaceableObjectScript extends ObjectReference MiscObject Property ItemToPlace Auto Bool Property isPlaced = false Auto Hidden Message Property FailMessage auto Event OnActivate(ObjectReference akActivator) if(isPlaced == FALSE) if akActivator.getItemCount(ItemToPlace) >= 1 isPlaced = TRUE self.getLinkedRef().enable() (akActivator as actor).removeItem(ItemToPlace, 1) else FailMessage.show() endif else isPlaced = FALSE self.getLinkedRef().disable() (akActivator as actor).addItem(ItemToPlace, 1) endif endEvent Save the script, wait for compiler to finish and close script editor. Right click the new script and EDIT PROPERTIES: ItemToPlace: select your CK object ID from step 1. This is the required item that has to be in player inventory to place it. FailMSG: select defaultLackTheItemMSG Done! This will create a totally static object that only uses the existing model and textures from CK, and nothing else. That way you never have issues with weird behavior. The script checks if your item is in the inventory and changes the visibility of the placeholder. Link to comment Share on other sites More sharing options...
Recommended Posts