NexusComa Posted February 22, 2018 Share Posted February 22, 2018 (edited) I'm just putting this out there. GetFormFromFile works just fine with the hex ID#. It does not need to be converted to decimal. All that is required is that the load order digits (first two) remain zero as the function looks inside the targeted ESP/ESM file rather than scanning the entire load order. Example line of code pulled from a fully functional script: (Game.GetFormFromFile(0x0016638D,ModName) as FormList).HasForm(TheItem) And yes, you can get the Editor ID from the in-game console. You can also get it by looking up the object in the Creation Kit and / or TES5Edit. True. The reason I used an int is so in the Function Clear it can later be removed. Using o1 as a type of holder. In my code o1 is actually a huge array.This is kinda chopped up snip from a much larger code that needed to pull many object. The object were random picked so this was a generic way tohold them after they were randomly pick so I could remove them later. Just though with a few tweaks it may work here too.Your comments are always welcome IsharaMeradin :smile: Edited February 22, 2018 by NexusComa Link to comment Share on other sites More sharing options...
YellowJacketXV Posted February 22, 2018 Author Share Posted February 22, 2018 (edited) So what is the best option then? Is what I'm after a custom function or something? Honestly, I didn't think spawning a piece of furniture from an item in the inventory would be this difficult what with having the in-game console command "player.placeatme" work for literally everything. Apparently on the Wiki https://www.creationkit.com/index.php?title=PlaceAtMe_-_ObjectReference "Note: the akFormToPlace can be things such as MiscItem, Actor, ActorBase, etcetera, but it cannot be an ObjectReference" Is there something in particular that deals with ObjectReference? ObjectReference is anything static, or furniture-based I assume? Edited February 22, 2018 by YellowJacketXV Link to comment Share on other sites More sharing options...
NexusComa Posted February 22, 2018 Share Posted February 22, 2018 Explain where you are with the mod and exactly what you're trying to get done now.Also here are a few mod that do what you're trying to do, I think. https://www.nexusmods.com/skyrim/mods/45831https://www.nexusmods.com/skyrim/mods/9881 Link to comment Share on other sites More sharing options...
YellowJacketXV Posted February 22, 2018 Author Share Posted February 22, 2018 Where I am at:I have completed both the Whetstone and Armorer's Hammer. Both of which are simple misc items crafted that allow an in-inventory use of a crafting menu (best example would be your first link. What I need done:Create a form of "spawnable" system for a custom smelter and a simple mesh-existing forge anvil. Best example would be the second link you had. Now I would have simply just gone into other mods and reverse-engineered the scripts attached but when I tried that I learned that because I don't have the script "source" file I can't check any of the added mod's scripts. The same form of activation is also very desirable as it's quick with no unnecessary menus. Problem is I can't figure out for the life of me how to actually spawn a piece of furniture using a script. I've tried placeAtMe() and moveTo() only to have nothing happen (which I learned apparently can't happen). So I assumed that the dropped mesh/object is quite literally being replaced or "swapped out" with the new mesh/object. But I can't find a function concept that allows a literal swap like that. As I said before, maybe I should have chosen a different second mod to make but darn it, other folk have had 7 years to implement a form of carry-along smithing so I have to pick up the slack. Link to comment Share on other sites More sharing options...
NexusComa Posted February 22, 2018 Share Posted February 22, 2018 (edited) https://www.nexusmods.com/skyrim/mods/59553/ ObjectReference myactivator = game.GetPlayer().PlaceAtMe(myfurniture as form, 1, true, true)myactivator.moveto(self as ObjectReference, 0 as Float, 0 as Float, 0 as Float, true)myactivator.SetPosition(self.x, self.y, self.z) ? Edited February 22, 2018 by NexusComa Link to comment Share on other sites More sharing options...
YellowJacketXV Posted February 22, 2018 Author Share Posted February 22, 2018 (edited) *edit* Nevermind my brain when to hell for a few. *double edit* 11:09 pm 02.21-18 I'm literally "quietly screaming at my computer" that I already did what the script said. But of course -NOW- it works... Looks like it was misbehaving because I used just ONE WORD wrong of syntax essentially. Things should be moving along swimmingly now. *final edit* 12:34 am 02.22.18I will place the finishing touches on soon, including a visual guide.So far everything works!I'll most definitely leave a shout out on the eventual mod page for NexusComa and IsharaMeradin for their sage-level of patience in helping me decipher things and set things up. Edited February 22, 2018 by YellowJacketXV Link to comment Share on other sites More sharing options...
YellowJacketXV Posted February 22, 2018 Author Share Posted February 22, 2018 https://www.nexusmods.com/skyrim/mods/89774/ :thumbsup: Link to comment Share on other sites More sharing options...
NexusComa Posted February 23, 2018 Share Posted February 23, 2018 Nice, and thank you, you would be shocked how many never say a word for help.Considering the time you put into trying to help out it's very disappointing. Link to comment Share on other sites More sharing options...
Evangela Posted February 23, 2018 Share Posted February 23, 2018 I minimize how much I 'help' around here, since I'm quite convinced I don't actually help anyone when I do. Link to comment Share on other sites More sharing options...
Recommended Posts