ASnowyEvening Posted September 10, 2023 Share Posted September 10, 2023 Title say is all. I know how to find uuids etc, im making a new item and I want to spawn it in game to check it out. Ive seen references to doing this but I don't actually know how. Link to comment Share on other sites More sharing options...
Emer78 Posted October 4, 2023 Share Posted October 4, 2023 I've been trying to figure this out as well. Some other Larian games used `ItemTo`, `ItemToInventory`, and `ItemTemplateAddTo`, but none of these work in BG3. Link to comment Share on other sites More sharing options...
Emer78 Posted October 4, 2023 Share Posted October 4, 2023 Okay, after spending some time looking through what little API spec exists (bg3se/Docs/API.md), I discovered that tables can be printed to the SE console with `_D()`. `_D(Osi)` reveals the existence of an `addItem` function, but I am thus far unable to ascertain its signature. Signatures that worked for similar commands in previous Larian games do not seem to work with this command: "No function named 'addItem' exists that can be called with 3 parameters.". The quest continues. Link to comment Share on other sites More sharing options...
Emer78 Posted October 4, 2023 Share Posted October 4, 2023 I've tested argument counts between 0 and 9; all result in that same error.Something's not right.The error message might not accurately reflect the real error. Link to comment Share on other sites More sharing options...
Cybergods Posted October 5, 2023 Share Posted October 5, 2023 I am 72yo and have worked professionally writing and reverse-engineering code for almost 50 years, and I am so tired of all the secrecy folks put around something simple like this. This type of harmless knowledge should be free and available to all. It's just a game folks -- it ain't your daughter. Here's what you need to do: 1. Install BG3SE with the 'Console' option set (See BG3SE docs) --or-- Install BG3SE with BG3MM and in BG3MM you can toggle the console on/off at any time -- The above should cause a console window to open whenever you start BG3 2, BG3SE Console allows commands to be entered to the console window. by default the console window is in 'log' mode, showing you what's happening in the game. --Press <enter> to enter console command mode; in this mode the normal log output is disabled to avoid log spam while typing commands. --Client/server context can be selected by typing client or server. This selects in which Lua environment the console commands will execute. --By default the console uses the server context. --The reset command reinitializes the server and client Lua VM. --In your case just hitting <enter> and accepting the default is fine 3. With your BG3 game open and running, and the console window in command mode, paste the following command into the console command window: Osi.TemplateAddTo("<insert uuid to spawn>", GetHostCharacter(), 1, 1); --Replace the uuid in the line above with the uuid of the item you wish to spawn -- so the line should look similar to the line below but contain the uuid for the item you want. Osi.TemplateAddTo("e9f34b29-99ff-46d4-8bfd-016e8ccbfd27", GetHostCharacter(), 1, 1); --hit <enter> 4. Open your game window and check in your main toon's inventory -- your item will be there. --- if you enter a uuid that BG3 doesn't know -- nothing happens - nothing is entered into inventory SO CHECK THE ENTIRE COMMAND for correctness !! 5. repeat as needed to spawn everything in the game. 6. When finished spawning ... type exit in the console window and hit <enter> to return to console 'log' mode as it was when you started. 7. use your ill-gotten gains to conquer this plane of existence * have a great day !! OH, BTW: i know it sounds obvious but some folks just don't think ..... If you're spawning items from public mods (like from Nexus here) you MUST install the mod BEFORE you can spawn the item, otherwise BG3 doesn't know it and you can't spawn it. Also you absolutely cannot install a mod, spawn one of it's items and then remove the mod as that will cause undetermined behavior to the game. Have Fun !! 8 7 Link to comment Share on other sites More sharing options...
Fieldmarshall3 Posted October 8, 2023 Share Posted October 8, 2023 Thank you for sharing your knowledge! Link to comment Share on other sites More sharing options...
DreadfulSanity Posted October 8, 2023 Share Posted October 8, 2023 The code is for the BG3SE console is: TemplateAddTo("item_UUID", GetHostCharacter(), item_quantity) Here's a raw list with most of the item UUIDs I'm currently working on compiling: https://pastebin.com/PZ4cBJPe Link to comment Share on other sites More sharing options...
Cybergods Posted October 9, 2023 Share Posted October 9, 2023 Here's a list of many of the game's items, alphabetized with uuid's. It's in a CSV format with name and uuid fields so it can go into a table or a spreadsheet easily. BTW this is DreadfulSanity's list from his entry here at Nexus ( Here ). I only alphabetized it. So give him all the credit. Uploaded by DreadfulSanityUploaded by DreadfulSanity Link to comment Share on other sites More sharing options...
halfjobjohnny Posted October 16, 2023 Share Posted October 16, 2023 I am 72yo and have worked professionally writing and reverse-engineering code for almost 50 years, and I am so tired of all the secrecy folks put around something simple like this. This type of harmless knowledge should be free and available to all. It's just a game folks -- it ain't your daughter. Here's what you need to do: 1. Install BG3SE with the 'Console' option set (See BG3SE docs) --or-- Install BG3SE with BG3MM and in BG3MM you can toggle the console on/off at any time -- The above should cause a console window to open whenever you start BG3 2, BG3SE Console allows commands to be entered to the console window. by default the console window is in 'log' mode, showing you what's happening in the game. --Press <enter> to enter console command mode; in this mode the normal log output is disabled to avoid log spam while typing commands. --Client/server context can be selected by typing client or server. This selects in which Lua environment the console commands will execute. --By default the console uses the server context. --The reset command reinitializes the server and client Lua VM. --In your case just hitting <enter> and accepting the default is fine 3. With your BG3 game open and running, and the console window in command mode, paste the following command into the console command window: Osi.TemplateAddTo("<insert uuid to spawn>", GetHostCharacter(), 1, 1); --Replace the uuid in the line above with the uuid of the item you wish to spawn -- so the line should look similar to the line below but contain the uuid for the item you want. Osi.TemplateAddTo("e9f34b29-99ff-46d4-8bfd-016e8ccbfd27", GetHostCharacter(), 1, 1); --hit <enter> 4. Open your game window and check in your main toon's inventory -- your item will be there. --- if you enter a uuid that BG3 doesn't know -- nothing happens - nothing is entered into inventory SO CHECK THE ENTIRE COMMAND for correctness !! 5. repeat as needed to spawn everything in the game. 6. When finished spawning ... type exit in the console window and hit <enter> to return to console 'log' mode as it was when you started. 7. use your ill-gotten gains to conquer this plane of existence * have a great day !! OH, BTW: i know it sounds obvious but some folks just don't think ..... If you're spawning items from public mods (like from Nexus here) you MUST install the mod BEFORE you can spawn the item, otherwise BG3 doesn't know it and you can't spawn it. Also you absolutely cannot install a mod, spawn one of it's items and then remove the mod as that will cause undetermined behavior to the game. Have Fun !! thank you! this is true legend behavior, immaculate vibes Link to comment Share on other sites More sharing options...
Stingrea51 Posted October 26, 2023 Share Posted October 26, 2023 I am 72yo and have worked professionally writing and reverse-engineering code for almost 50 years, and I am so tired of all the secrecy folks put around something simple like this. This type of harmless knowledge should be free and available to all. It's just a game folks -- it ain't your daughter. Here's what you need to do: 1. Install BG3SE with the 'Console' option set (See BG3SE docs) --or-- Install BG3SE with BG3MM and in BG3MM you can toggle the console on/off at any time -- The above should cause a console window to open whenever you start BG3 2, BG3SE Console allows commands to be entered to the console window. by default the console window is in 'log' mode, showing you what's happening in the game. --Press <enter> to enter console command mode; in this mode the normal log output is disabled to avoid log spam while typing commands. --Client/server context can be selected by typing client or server. This selects in which Lua environment the console commands will execute. --By default the console uses the server context. --The reset command reinitializes the server and client Lua VM. --In your case just hitting <enter> and accepting the default is fine 3. With your BG3 game open and running, and the console window in command mode, paste the following command into the console command window: Osi.TemplateAddTo("<insert uuid to spawn>", GetHostCharacter(), 1, 1); --Replace the uuid in the line above with the uuid of the item you wish to spawn -- so the line should look similar to the line below but contain the uuid for the item you want. Osi.TemplateAddTo("e9f34b29-99ff-46d4-8bfd-016e8ccbfd27", GetHostCharacter(), 1, 1); --hit <enter> 4. Open your game window and check in your main toon's inventory -- your item will be there. --- if you enter a uuid that BG3 doesn't know -- nothing happens - nothing is entered into inventory SO CHECK THE ENTIRE COMMAND for correctness !! 5. repeat as needed to spawn everything in the game. 6. When finished spawning ... type exit in the console window and hit <enter> to return to console 'log' mode as it was when you started. 7. use your ill-gotten gains to conquer this plane of existence * have a great day !! OH, BTW: i know it sounds obvious but some folks just don't think ..... If you're spawning items from public mods (like from Nexus here) you MUST install the mod BEFORE you can spawn the item, otherwise BG3 doesn't know it and you can't spawn it. Also you absolutely cannot install a mod, spawn one of it's items and then remove the mod as that will cause undetermined behavior to the game. Have Fun !! You are my personal hero <3 Link to comment Share on other sites More sharing options...
Recommended Posts