temnix Posted October 7, 2019 Share Posted October 7, 2019 I have a spell which is not supposed to work on creatures with any amount of resistance to cold. On top of those effects sits Protection from spell, opcode 318, but I need to add a custom line for protection from cold (stat 15) > 0. I try this code but get wrong results: COPY_EXISTING ~SPLPROT.2DA~ override COUNT_2DA_ROWS 4 newrow BUT_ONLY APPEND ~SPLPROT.2DA~ ~%newrow% 15 0 3~ OUTER_SET newrow = newrow + 1 Weidu is not my specialty. Either I'm doing something wrong here or a bit of code higher up in the tp2 is to blame. It is used for another spell and reads: COPY_EXISTING ~SPLPROT.2DA~ override COUNT_2DA_ROWS 4 row BUT_ONLY APPEND ~SPLPROT.2DA~ ~%row% 15 50 2~ OUTER_SET one = row + 1 APPEND ~SPLPROT.2DA~ ~%one% 15 127 3~ OUTER_SET two = one + 1 APPEND ~SPLPROT.2DA~ ~%two% 260 %row% %one%~ I don't know why this code would cause problems for what goes below, but the spell in question instead of a new row gets pointed to the created "cold resistance > 127." Help would be appreciated. I'll credit you in the mod this is for when it comes out. 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.