Skip to content

Need an idea to exclude NPCs

CrevsDaakCrevsDaak Member Posts: 7,155
edited May 2014 in General Modding
I coded a (very easy) weidu today that gives all the mages/sorcerers 4 levels more, but I'm not very creative today so I can't think of any way of how to exclude NPCs of being edited by weidu too.
BEGIN ~Add 4 levels to all mages/sorcerers in the games~
COPY_EXISTING_REGEXP ~.*\.cre~ ~override~
PATCH_IF (SOURCE_SIZE > 0x2d3) BEGIN
READ_BYTE 0x273 class

PATCH_IF (class = 1) OR (class = 19) BEGIN
READ_BYTE 0x234 level1
WRITE_BYTE 0x234 ("level1" + 4)
END
END
BUT_ONLY_IF_IT_CHANGES

Comments

  • WispWisp Member Posts: 1,102
    READ_ASCII 0x280 script_name (32) NULL PATCH_IF !FILE_CONTAINS_EVALUATED (pdialog.2da ~%script_name%~) BEGIN
  • CrevsDaakCrevsDaak Member Posts: 7,155
    @Wisp‌ thank you! Now to finish the mod for all the classes and multi-classes in the game :D
Sign In or Register to comment.