Need an idea to exclude NPCs
CrevsDaak
Member Posts: 7,155
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
1
Comments
READ_ASCII 0x280 script_name (32) NULL PATCH_IF !FILE_CONTAINS_EVALUATED (pdialog.2da ~%script_name%~) BEGIN