Daeros_Trollkiller Posted July 5, 2020 Share Posted July 5, 2020 I am having some trouble wrapping my head around modifying existing 2DA's. The specific one I am trying to modify in this case is: rndmagic.2da. I am trying to add some additional ammunition types to the "HIGH" row: 2DA V1.0 * 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 LOW RNDWEP02 RNDWEP01 BULL03*3 POTN31 RNDSCR02 RNDSCR01 SCRL06 SCRL04 POTN08 POTN43 POTN44 POTN37 POTN19 POTN28 BULL02*5 AROW02*5 BOLT02*5 RNDWEP01 RNDWEP02 HIGH RNDWEP03 RNDWEP02 RNDWEP01 SCRL08 SCRL09 RNDSCR03 SCRL16 POTN17 POTN08 POTN10 AROW04 AROW09 BOLT04 BOLT03 AROW06 RNDWEP01 RNDWEP02 RNDWEP02 RNDWEP03 I am trying to add 5 new items, essentially trying to make something like this: LOW RNDWEP02 RNDWEP01 BULL03*3 POTN31 RNDSCR02 RNDSCR01 SCRL06 SCRL04 POTN08 POTN43 POTN44 POTN37 POTN19 POTN28 BULL02*5 AROW02*5 BOLT02*5 RNDWEP01 RNDWEP02 * * * * * HIGH RNDWEP03 RNDWEP02 RNDWEP01 SCRL08 SCRL09 RNDSCR03 SCRL16 POTN17 POTN08 POTN10 AROW04 AROW09 BOLT04 BOLT03 AROW06 RNDWEP01 RNDWEP02 RNDWEP02 RNDWEP03 BULL07 BULL08 BULL09 BDBOLT01 BDBOLT02 Here is the code I've tried, and I'm sure I am missing something, hoping it's something simple: //COPY_EXISTING ~rndmagic.2da~ ~override~ //BEGIN //SET_2DA_ENTRY 3 21 3 ~bull07~ //SET_2DA_ENTRY 3 22 3 ~bull08~ //SET_2DA_ENTRY 3 23 3 ~bull09~ //SET_2DA_ENTRY 3 24 3 ~bdbolt01~ //SET_2DA_ENTRY 3 25 3 ~bdbolt02~ //END Anything that will help me to better understand how these files, and modifying them in WeiDu works is greatly appreciated! Quote Link to comment
Jarno Mikkola Posted July 5, 2020 Share Posted July 5, 2020 10 minutes ago, Daeros_Trollkiller said: nd I'm sure I am missing something, hoping it's something simple: Well, they work by a dice roll of a 20 sided die. And so there's already a 20 results. Not something this simple, you wanted, is my bet. Quote Link to comment
DavidW Posted July 6, 2020 Share Posted July 6, 2020 You can't add columns that way. SET_2DA_ENTRY edits existing entries, it doesn't add new ones. You would need to use an APPEND_COL to add new column data. Unfortunately, in this case I don't think it will help you. I'm fairly sure (as Jarno alludes to) that the range in rndmagic and the other BG2-style random-treasure files is hardcoded and won't be changed by editing the files. (I admit I haven't tested it, but that's what IESDP says.) Assuming you're modding an EE game, you could try using the IWDEE random-treasure system, which is a bit more flexible. Quote Link to comment
Recommended Posts
Join the conversation
You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.