

/* Backup folder */
BACKUP ~DRIZZTSAGA/backup~
/* Author */
AUTHOR ~flysoup, http://forums.blackwyrmlair.net/index.php?showforum=103~
VERSION ~v2.0~

/*
 WeiDU conversion and Tutu/BGT tp2 code by:

	Badgert
	pro5
	
	Thanks to erebusant for helping with WM6 support
*/	


/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

DEFINE_ACTION_MACRO ~MAP_UPDATE~ BEGIN

// Adding our 4 new areas into worldmap.wmp...
// (Slightly adapted) code borrowed from BP-BGT-Worldmap.tp2

OUTER_SPRINT "#_translations" ""      //table declaration
COPY - ~DRIZZTSAGA/Worldmap/TRA/%LANGUAGE%/worldmap.tra~ ~override~
 COUNT_2DA_ROWS 3 string_entries
 READ_2DA_ENTRIES_NOW ~#_translations~ 3

// Worldmap
COPY_EXISTING ~WORLDMAP.WMP~ ~override~
 READ_LONG  0x0c              map_offset
 READ_LONG (map_offset+0x20)  entries_num
 READ_LONG (map_offset+0x24)  entries_offset
 READ_LONG (map_offset+0x28)  links_offset
 READ_LONG (map_offset+0x2c)  links_num
//*****************************************************************************
// adding new areas
//*****************************************************************************
 FOR( cnt=1; cnt<new_areas_num; cnt=cnt+1 ) BEGIN
  READ_2DA_ENTRY_FORMER ~#_areas~ cnt 0 "short_name"
  READ_2DA_ENTRY_FORMER ~#_areas~ cnt 1 "content"
  READ_2DA_ENTRY_FORMER ~#_areas~ cnt 2 "long_name"
  READ_2DA_ENTRY_FORMER ~#_areas~ cnt 3 "flags"
  READ_2DA_ENTRY_FORMER ~#_areas~ cnt 4 "bam_anim"
  READ_2DA_ENTRY_FORMER ~#_areas~ cnt 5 "x_pos"
  READ_2DA_ENTRY_FORMER ~#_areas~ cnt 6 "y_pos"
  READ_2DA_ENTRY_FORMER ~#_areas~ cnt 7 "name"
  READ_2DA_ENTRY_FORMER ~#_areas~ cnt 8 "tooltip"
  READ_2DA_ENTRY_FORMER ~#_areas~ cnt 9 "load_im"

  PATCH_IF (("%short_name%" STRING_COMPARE_CASE "SHORT_NAME")!=0) BEGIN //to skip header lines

   PATCH_IF (("%name%"    STRING_COMPARE_CASE "N")=0)  BEGIN SPRINT name_2 "N" END
   PATCH_IF (("%tooltip%" STRING_COMPARE_CASE "N")=0)  BEGIN SPRINT tip_2  "N" END

   //*****************************************************************
   //2. we need to read the area name from a tra file - because SAY_EVALUATED
   //   could not use a @string inside a variable
   //*****************************************************************
   FOR (str=0; str<string_entries; str=str+1) BEGIN
       READ_2DA_ENTRY_FORMER ~#_translations~ str 0 "string_number"
       PATCH_IF (("%name%"    STRING_COMPARE_CASE "%string_number%")=0) BEGIN
          READ_2DA_ENTRY_FORMER ~#_translations~ str 2 "name_2"
       END
       PATCH_IF (("%tooltip%" STRING_COMPARE_CASE "%string_number%")=0) BEGIN
          READ_2DA_ENTRY_FORMER ~#_translations~ str 2 "tip_2"
       END
   END

   INNER_PATCH_SAVE name_3 "%name_2%" BEGIN REPLACE_TEXTUALLY ~###~ ~ ~  REPLACE_TEXTUALLY ~"~ ~~ END
   INNER_PATCH_SAVE tip_3  "%tip_2%"  BEGIN REPLACE_TEXTUALLY ~###~ ~ ~  REPLACE_TEXTUALLY ~"~ ~~ END

   PATCH_IF (("%load_im%" STRING_COMPARE_CASE "N")=0) BEGIN SPRINT load_im "" END

     SET new_entry_offset = entries_offset + entries_num*0xf0

     INSERT_BYTES          new_entry_offset         0xf0
     WRITE_EVALUATED_ASCII (new_entry_offset+0)     "%short_name%" #8
     WRITE_EVALUATED_ASCII (new_entry_offset+0x08)  "%content%"    #8
     WRITE_EVALUATED_ASCII (new_entry_offset+0x10)  "%long_name%"  #32
     WRITE_LONG            (new_entry_offset+0x30)  "%flags%"
     WRITE_LONG            (new_entry_offset+0x34)  "%bam_anim%"
     WRITE_LONG            (new_entry_offset+0x38)  "%x_pos%"
     WRITE_LONG            (new_entry_offset+0x3c)  "%y_pos%"
     PATCH_IF (("%name_3%"  STRING_COMPARE_CASE "N")=0) BEGIN
       WRITE_LONG  (new_entry_offset+0x40)  0xffffffff
     END ELSE BEGIN
       SAY_EVALUATED       (new_entry_offset+0x40)  "%name_3%"
     END
     PATCH_IF (("%tip_3%"  STRING_COMPARE_CASE "N")=0) BEGIN
       WRITE_LONG  (new_entry_offset+0x44)  0xffffffff
     END ELSE BEGIN
       SAY_EVALUATED       (new_entry_offset+0x44)  "%tip_3%"
     END
     WRITE_EVALUATED_ASCII (new_entry_offset+0x48)  "%load_im%"    #8

     SET entries_num = entries_num + 1
     WRITE_LONG (map_offset+0x20)  entries_num
     PATCH_IF( links_offset>=entries_offset ) THEN BEGIN
       SET links_offset = links_offset+0xf0
       WRITE_LONG (map_offset+0x28)  links_offset
     END
  END   //headers skipping
 END    //for all new areas
 
//*****************************************************************************
// adding new links
//*****************************************************************************
 FOR( cnt=1; cnt<new_links_num; cnt=cnt+1 ) BEGIN
  READ_2DA_ENTRY_FORMER ~#_links~ cnt 0  "src_area"
  READ_2DA_ENTRY_FORMER ~#_links~ cnt 1  "src_nwse"
  READ_2DA_ENTRY_FORMER ~#_links~ cnt 2  "target_are"
  READ_2DA_ENTRY_FORMER ~#_links~ cnt 3  "entry_name"
  READ_2DA_ENTRY_FORMER ~#_links~ cnt 4  "trv_time"
  READ_2DA_ENTRY_FORMER ~#_links~ cnt 5  "def_entry"
  READ_2DA_ENTRY_FORMER ~#_links~ cnt 6  "enc1"
  READ_2DA_ENTRY_FORMER ~#_links~ cnt 7  "enc2"
  READ_2DA_ENTRY_FORMER ~#_links~ cnt 8  "enc3"
  READ_2DA_ENTRY_FORMER ~#_links~ cnt 9  "enc4"
  READ_2DA_ENTRY_FORMER ~#_links~ cnt 10 "enc5"
  READ_2DA_ENTRY_FORMER ~#_links~ cnt 11 "enc_prob"

  PATCH_IF (("%src_area%" STRING_COMPARE_CASE "SRC_AREA")!=0) BEGIN //to skip header lines

   //*****************************************************************
   //1. we need to find a record for the source area
   //*****************************************************************
   SET source_area_offset=0
   SET source_area_index = 0xffffffff
   SPRINT area_name ""
   WHILE(("%area_name%" STRING_COMPARE_CASE "%src_area%") AND source_area_index<entries_offset) BEGIN
     SET source_area_index = source_area_index + 1
     READ_ASCII (entries_offset + source_area_index*0xf0 + 0x08) area_name
   END
   PATCH_IF( source_area_index<entries_num ) BEGIN
     SET source_area_offset = entries_offset + source_area_index*0xf0
   END
   //*****************************************************************
   //2. we need to find a record for the destination area
   //*****************************************************************
   SET dest_area_index = 0xffffffff
   SPRINT area_name ""
   WHILE(("%area_name%" STRING_COMPARE_CASE "%target_are%") AND dest_area_index<entries_offset) BEGIN
     SET dest_area_index = dest_area_index + 1
     READ_ASCII (entries_offset + dest_area_index*0xf0 + 0x08) area_name
   END
   //*****************************************************************
   // source_area_offset=-1 or contains offset of the source area entry
   // dest_area_index=-1 or contains index of the destination area entry
   //*****************************************************************
   //*****************************************************************
   //3. determining what direction in source area's entry we will patch
   //*****************************************************************
   PATCH_IF( source_area_offset>0 AND dest_area_index<entries_offset ) BEGIN
     SET links_header_offset=0
     PATCH_IF( ("%src_nwse%" STRING_COMPARE_CASE "N")=0 ) BEGIN
       SET links_header_offset = source_area_offset + 0x50
     END
     PATCH_IF( ("%src_nwse%" STRING_COMPARE_CASE "W")=0 ) BEGIN
       SET links_header_offset = source_area_offset + 0x58
     END
     PATCH_IF( ("%src_nwse%" STRING_COMPARE_CASE "S")=0 ) BEGIN
       SET links_header_offset = source_area_offset + 0x60
     END
     PATCH_IF( ("%src_nwse%" STRING_COMPARE_CASE "E")=0 ) BEGIN
       SET links_header_offset = source_area_offset + 0x68
     END

     PATCH_IF( links_header_offset>0 ) BEGIN
       PATCH_IF (("%enc1%" STRING_COMPARE_CASE "N")=0) BEGIN SPRINT enc1 "" END
       PATCH_IF (("%enc2%" STRING_COMPARE_CASE "N")=0) BEGIN SPRINT enc2 "" END
       PATCH_IF (("%enc3%" STRING_COMPARE_CASE "N")=0) BEGIN SPRINT enc3 "" END
       PATCH_IF (("%enc4%" STRING_COMPARE_CASE "N")=0) BEGIN SPRINT enc4 "" END
       PATCH_IF (("%enc5%" STRING_COMPARE_CASE "N")=0) BEGIN SPRINT enc5 "" END
       PATCH_IF (("%entry_name%" STRING_COMPARE_CASE "N")=0) BEGIN SPRINT entry_name "" END

       READ_LONG (links_header_offset+0)  src_area_links_index
       READ_LONG (links_header_offset+4)  src_area_links_cnt

       PATCH_IF( src_area_links_index=0 ) BEGIN
         SET src_area_links_index = links_num    //point at the very end of links list if it's a new area
         WRITE_LONG (links_header_offset+0)  src_area_links_index
       END

       SET working_links_offset = links_offset + src_area_links_index*0xd8

       INSERT_BYTES          working_links_offset         0xd8
       WRITE_LONG            (working_links_offset+0)     dest_area_index
       WRITE_EVALUATED_ASCII (working_links_offset+0x04)  "%entry_name%"  #32
       WRITE_LONG            (working_links_offset+0x24)  trv_time
       WRITE_LONG            (working_links_offset+0x28)  def_entry
       WRITE_EVALUATED_ASCII (working_links_offset+0x2c)  "%enc1%"        #8
       WRITE_EVALUATED_ASCII (working_links_offset+0x34)  "%enc2%"        #8
       WRITE_EVALUATED_ASCII (working_links_offset+0x3c)  "%enc3%"        #8
       WRITE_EVALUATED_ASCII (working_links_offset+0x44)  "%enc4%"        #8
       WRITE_EVALUATED_ASCII (working_links_offset+0x4c)  "%enc5%"        #8
       WRITE_LONG            (working_links_offset+0x54)  enc_prob

       WRITE_LONG (links_header_offset+4)  src_area_links_cnt+1    //adjusting local links counter
       SET links_num = links_num + 1
       WRITE_LONG (map_offset+0x2c)        links_num               //adjusting global links counter

      //*****************************************************************
      //4. we need to check all other area entries to adjust their links indexes
      //*****************************************************************
       FOR(link=0; link<entries_num; link=link+1) BEGIN
         READ_LONG (entries_offset + link*0xf0 + 0x50) idxN
         READ_LONG (entries_offset + link*0xf0 + 0x58) idxW
         READ_LONG (entries_offset + link*0xf0 + 0x60) idxS
         READ_LONG (entries_offset + link*0xf0 + 0x68) idxE
         PATCH_IF( idxN>src_area_links_index ) BEGIN
           WRITE_LONG (entries_offset + link*0xf0 + 0x50) idxN+1
         END
         PATCH_IF( idxW>src_area_links_index ) BEGIN
           WRITE_LONG (entries_offset + link*0xf0 + 0x58) idxW+1
         END
         PATCH_IF( idxS>src_area_links_index ) BEGIN
           WRITE_LONG (entries_offset + link*0xf0 + 0x60) idxS+1
         END
         PATCH_IF( idxE>src_area_links_index ) BEGIN
           WRITE_LONG (entries_offset + link*0xf0 + 0x68) idxE+1
         END
       END
     END
   END
  END   //headers skipping
 END    //for all new links
BUT_ONLY_IF_IT_CHANGES

END // MACRO

/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

AUTO_TRA ~DRIZZTSAGA/Language/%s~

LANGUAGE	~English~
		~english~
		~DRIZZTSAGA/Language/English/setup.tra~

LANGUAGE	~Italian~
		~italian~
		~DRIZZTSAGA/Language/Italian/setup.tra~

LANGUAGE	~Russian by Fess. Updated by Prowler~
		~russian~
		~DRIZZTSAGA/Language/Russian/setup.tra~


BEGIN @0	// The Drizzt Saga for Tutu/BGT
REQUIRE_PREDICATE FILE_EXISTS_IN_GAME ~SARADUSH.MVE~ AND (FILE_EXISTS_IN_GAME ~FW1500.ARE~ OR FILE_EXISTS ~DATA/BG1ARE.bif~) @356


MKDIR ~DZTS-ARE~

COPY + ~Setup-DRIZZTSAGA.exe~ ~WeiDU.exe~
COPY + ~chitin.key~ ~DRIZZTSAGA/chitin.dzt~
COPY_LARGE + ~dialog.tlk~ ~DRIZZTSAGA/dialog.dzt~
MKDIR ~DRIZZTSAGA/over.bak~
COPY_LARGE + ~override~ ~DRIZZTSAGA/over.bak~

AT_UNINSTALL ~DRIZZTSAGA/Uninstall.bat~

/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

ACTION_IF FILE_EXISTS_IN_GAME ~FW0100.are~ THEN BEGIN	// Tutu

AT_INTERACTIVE_EXIT ~VIEW DRIZZTSAGA\DrizztSaga-ReadMe.html~

PRINT @353

COPY - ~DRIZZTSAGA/misc/F_PATCH.2DA~ ~override~
	REPLACE_TEXTUALLY "AR4200" "FW4200"
	COUNT_2DA_ROWS 5 GAM_count
	READ_2DA_ENTRIES_NOW ~#GAM_patch_table~ 5

		
COPY_EXISTING ~XPCAP.2da~ ~override~
  COUNT_2DA_ROWS 2 "cnt_row"
  FOR ( cnt=0; cnt<"%cnt_row%"; cnt=cnt+1 ) BEGIN
    READ_2DA_ENTRY "%cnt%" 0 2 "class"
    PATCH_IF (("%class%" STRING_COMPARE_CASE "MAGE")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "3750000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "FIGHTER")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "3000000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "CLERIC")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "2700000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "THIEF")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "2200000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "BARD")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "2200000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "PALADIN")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "3600000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "DRUID")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "2000000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "RANGER")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "3600000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "FIGHTER_MAGE")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "601000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "FIGHTER_CLERIC")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "601000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "FIGHTER_THIEF")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "601000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "FIGHTER_MAGE_THIEF")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "601000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "MAGE_THIEF")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "601000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "CLERIC_MAGE")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "601000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "CLERIC_THIEF")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "601000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "FIGHTER_DRUID")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "601000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "FIGHTER_MAGE_CLERIC")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "601000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "CLERIC_RANGER")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "601000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "MONK")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "3000000"
    END
    ELSE PATCH_IF (("%class%" STRING_COMPARE_CASE "SORCERER")=0) BEGIN
     SET_2DA_ENTRY "%cnt%" 1 2 "3750000"
    END
  END
BUT_ONLY_IF_IT_CHANGES

// Worldmap

PRINT @359

OUTER_SPRINT "#_areas" ""            //table declaration
COPY - ~DRIZZTSAGA/Worldmap/Tutu/areas.tbl~ ~override~
 COUNT_2DA_ROWS 10 new_areas_num
 READ_2DA_ENTRIES_NOW ~#_areas~ 10

OUTER_SPRINT "#_links" ""            //table declaration
COPY - ~DRIZZTSAGA/Worldmap/Tutu/links.tbl~ ~override~
 COUNT_2DA_ROWS 12 new_links_num
 READ_2DA_ENTRIES_NOW ~#_links~ 12
 
LAUNCH_ACTION_MACRO ~MAP_UPDATE~

// CRE Animations:

PRINT @358

COPY ~DRIZZTSAGA/Anim/MNO2~ ~override~         //FROST GIANT

COPY_EXISTING ~ORC06.cre~          ~override~
              ~HLOLAF.cre~         ~override~
              ~CHAK.cre~           ~override~
              ~AR18FIG.cre~        ~override~
   WRITE_LONG 0x28  0xE700   //IC_OROG1 instead of IC_OROG2
BUT_ONLY_IF_IT_CHANGES

COPY ~DRIZZTSAGA/Anim/MUMB~ ~override~         //Belhifet

COPY ~DRIZZTSAGA/Anim/MCYC~ ~override~         //Cyclop

COPY ~DRIZZTSAGA/Anim/MTAN~ ~override~         //Merilith

COPY ~DRIZZTSAGA/Anim/MTIC~ ~override~         //Harpy

AT_EXIT ~DRIZZTSAGA/Sounds.bat~

// Areas:

PRINT @362

COPY ~DRIZZTSAGA/ARE/F_0111.are~ ~OVERRIDE~
	WRITE_ASCII 0x13ec ~_POTN09~ #8	
	WRITE_ASCII 0x1400 ~_RING03~ #8	
	WRITE_ASCII 0x1414 ~_POTN34~ #8	
	WRITE_ASCII 0x150c ~_MB_E06C~ #8	
	WRITE_ASCII 0x15d8 ~_MB_E01A~ #8
	WRITE_ASCII 0x15e0 ~_MB_E01A~ #8
	WRITE_ASCII 0x15ec ~_MB_E01A~ #8
	WRITE_ASCII 0x15f4 ~_MB_E01A~ #8	

COPY ~DRIZZTSAGA/ARE/F_0112.are~ ~OVERRIDE~
	WRITE_ASCII 0x7fc ~_WOLFWI~ #8
	WRITE_ASCII 0x90c ~_WOLFWI~ #8
	WRITE_ASCII 0xa1c ~_WOLFWI~ #8
	WRITE_ASCII 0xb2c ~_WOLFWI~ #8
	WRITE_ASCII 0xc3c ~_WOLFWI~ #8
	WRITE_ASCII 0xd4c ~_WOLFWI~ #8
	WRITE_ASCII 0x1338 ~_MB_E06B~ #8
	WRITE_ASCII 0x14b4 ~_MB_E02A~ #8
	WRITE_ASCII 0x14bc ~_MB_E02A~ #8
	WRITE_ASCII 0x14c8 ~_MB_E02A~ #8
	WRITE_ASCII 0x14d0 ~_MB_E02A~ #8
	
COPY ~DRIZZTSAGA/ARE/F_0113.ARE~ ~OVERRIDE~
	
COPY ~DRIZZTSAGA/ARE/F_0114.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_0115.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x5dc ~_WOLFWI~ #8	
	WRITE_ASCII 0x6ec ~_WOLFWI~ #8	
	WRITE_ASCII 0x7fc ~_WOLFWI~ #8	
	WRITE_ASCII 0x90c ~_WOLFWI~ #8	
	WRITE_ASCII 0xa1c ~_WOLFWI~ #8	
	WRITE_ASCII 0xb2c ~_WOLFWI~ #8
	WRITE_ASCII 0xf1c ~_MB_E02A~ #8
	WRITE_ASCII 0xf24 ~_MB_E02A~ #8
	WRITE_ASCII 0xf30 ~_MB_E02A~ #8
	WRITE_ASCII 0xf38 ~_MB_E02A~ #8

COPY ~DRIZZTSAGA/ARE/F_0222.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x1a00 ~_POTN17~ #8	
	WRITE_ASCII 0x1a44 ~_MB_E06B~ #8	
	WRITE_ASCII 0x1bc0 ~_MB_E01A~ #8
	WRITE_ASCII 0x1bc8 ~_MB_E01A~ #8
	WRITE_ASCII 0x1bd4 ~_MB_E01A~ #8
	WRITE_ASCII 0x1bdc ~_MB_E01A~ #8

COPY ~DRIZZTSAGA/ARE/F_0223.ARE~ ~OVERRIDE~
	SAY 0x794 @365

COPY_EXISTING ~FW4200.ARE~ ~OVERRIDE~
	READ_LONG 0x54 ~actoroffset~
	READ_SHORT 0x58 ~actornum~
	SET ~numsofar~=0
	WHILE (~%numsofar%~<~%actornum%~) BEGIN
		READ_ASCII (~%numsofar%~*0x110 + ~%actoroffset%~+0x80) ~crename~
		PATCH_IF !(~%crename%~ STRING_COMPARE_CASE ~_DRIZZT~) THEN BEGIN
			WRITE_ASCII (~%numsofar%~*0x110 + ~%actoroffset%~+0x80) ~F_DRIZZT~ #8
			WRITE_SHORT (~%numsofar%~*0x110 + ~%actoroffset%~+0x20) 2737
			WRITE_SHORT (~%numsofar%~*0x110 + ~%actoroffset%~+0x22) 1998
			WRITE_SHORT (~%numsofar%~*0x110 + ~%actoroffset%~+0x24) 2737
			WRITE_SHORT (~%numsofar%~*0x110 + ~%actoroffset%~+0x26) 1998
		END
		SET ~numsofar~=~%numsofar%~+1
	END	
BUT_ONLY_IF_IT_CHANGES

COPY ~DRIZZTSAGA/ARE/F_6661.ARE~ ~OVERRIDE~
	SAY 0x234 @101
	SAY 0x238 @101
	WRITE_ASCII 0xaa0 ~_POTN08~ #8
	WRITE_ASCII 0xac8 ~_POTN08~ #8
	WRITE_ASCII 0xc41 ~_MB_E03B~ #8
	WRITE_ASCII 0xc49 ~_MB_E03B~ #8
	WRITE_ASCII 0xc55 ~_MB_E03B~ #8
	WRITE_ASCII 0xc5d ~_MB_E03B~ #8
	
COPY ~DRIZZTSAGA/ARE/F_6664.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_6666.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x144 ~_MB_E03B~ #8
	WRITE_ASCII 0x14c ~_MB_E03B~ #8
	WRITE_ASCII 0x158 ~_MB_E03B~ #8
	WRITE_ASCII 0x160 ~_MB_E03B~ #8
	// Embedded CREs:
	// Actor 1
	SAY 0x922 @43
	SAY 0x926 @43
	SAY 0x9be @371
	SAY 0x9e2 @372
	SAY 0xa06 @373
	SAY 0xa0a @374
	SAY 0xa26 @375
	SAY 0xad2 @375
	WRITE_ASCII 0xb6a ~_TASIGHT~ #8
	WRITE_ASCIIT 0xb9a ~F_DEATHK~
	WRITE_ASCII 0xd72 ~_HELM08~ #8
	WRITE_ASCII 0xd86 ~_PLAT04~ #8
	WRITE_ASCII 0xd9a ~F_SW2H08~ #8
	// Actor 2
	SAY 0xdb6 @46
	SAY 0xdba @46
	SAY 0xe76 @419
	SAY 0xe7a @420
	SAY 0xe7e @421
	SAY 0xe82 @422
	SAY 0xe9a @420
	SAY 0xe9e @423
	SAY 0xeba @419
	SAY 0xebe @420
	SAY 0xec2 @421
	SAY 0xec6 @422
	WRITE_ASCII 0x1016 ~_TASIGHT~ #8
	WRITE_ASCII 0x11e2 ~_HELM08~ #8
	WRITE_ASCII 0x11f6 ~_PLAT04~ #8
	WRITE_ASCII 0x120a ~_RING95~ #8
	WRITE_ASCII 0x121e ~_SW1H11~ #8
	// Actor 3
	SAY 0x123a @46
	SAY 0x123e @46
	SAY 0x12fa @419
	SAY 0x12fe @420
	SAY 0x1302 @421
	SAY 0x1306 @422
	SAY 0x131e @420
	SAY 0x1322 @423
	SAY 0x133e @419
	SAY 0x1342 @420
	SAY 0x1346 @421
	SAY 0x134a @422
	WRITE_ASCII 0x149a ~_TASIGHT~ #8
	WRITE_ASCII 0x1666 ~_HELM08~ #8
	WRITE_ASCII 0x167a ~_PLAT04~ #8
	WRITE_ASCII 0x168e ~_RING95~ #8
	WRITE_ASCII 0x16a2 ~_SW1H11~ #8
	// Actor 4
	SAY 0x16be @42
	SAY 0x16c2 @42
	SAY 0x175a @371
	SAY 0x177e @372
	SAY 0x17a2 @373
	SAY 0x17a6 @374
	SAY 0x17c2 @375
	SAY 0x186e @375
	WRITE_LONG 0x16de 0x2300	// DEATH_KNIGHT
	WRITE_ASCII 0x1906 ~_TASIGHT~ #8
	WRITE_ASCII 0x1b0e ~_HELM08~ #8
	WRITE_ASCII 0x1b22 ~_PLAT05~ #8
	WRITE_ASCII 0x1b4a ~_SW2H07~ #8
	// Actor 5
	SAY 0x1b66 @44
	SAY 0x1b6a @44
	SAY 0x1c02 @400
	SAY 0x1c06 @401
	SAY 0x1c26 @402
	SAY 0x1c3a @403
	SAY 0x1c3e @404
	SAY 0x1c4a @405
	SAY 0x1c4e @406
	SAY 0x1c6a @407
	SAY 0x1c6e @408
	SAY 0x1c72 @409
	WRITE_ASCII 0x1da6 ~_TANARI~ #8
	WRITE_ASCII 0x1dbe ~_TASIGHT~ #8
	// Actor 6
	SAY 0x2006 @43
	SAY 0x200a @43	
	SAY 0x20a2 @371	
	SAY 0x20c6 @372	
	SAY 0x20ea @373
	SAY 0x20ee @374	
	SAY 0x210a @375	
	SAY 0x21b6 @375	
	WRITE_ASCII 0x224e ~_TASIGHT~ #8
	WRITE_ASCIIT 0x227e ~F_DEATHK~
	WRITE_ASCII 0x2456 ~_HELM08~ #8
	WRITE_ASCII 0x246a ~_PLAT04~ #8
	WRITE_ASCII 0x247e ~F_SW2H08~ #8
	// Actor 7
	SAY 0x249a @43
	SAY 0x249e @43	
	SAY 0x2536 @371
	SAY 0x255a @372	
	SAY 0x257e @373	
	SAY 0x2582 @374		
	SAY 0x259e @375		
	SAY 0x264a @375		
	WRITE_ASCII 0x26e2 ~_TASIGHT~ #8
	WRITE_ASCIIT 0x2712 ~F_DEATHK~
	WRITE_ASCII 0x28ea ~_HELM08~ #8
	WRITE_ASCII 0x28fe ~_PLAT04~ #8
	WRITE_ASCII 0x2912 ~F_SW2H08~ #8
	// Actor 8
	SAY 0x292e @16
	SAY 0x2932 @16
    SAY 0x29ca ~~ [F_BEL01]
    SAY 0x29ee ~~ [F_BEL01]
    SAY 0x2a02 ~~ [F_BEL03]
    SAY 0x2a06 ~~ [F_BEL04]
    SAY 0x2a12 ~~ [F_BEL08]
    SAY 0x2a16 ~~ [F_BEL09]
    WRITE_LONG 0x294e 0xE0D0		// IC_UMBERHULK
    WRITE_ASCII 0x2b86 ~_TASIGHT~ #8
    // Actor 9
    SAY 0x2dce @43
    SAY 0x2dd2 @43
	SAY 0x2e6a @371	
	SAY 0x2e8e @372	
	SAY 0x2eb2 @373
	SAY 0x2eb6 @374	
	SAY 0x2ed2 @375	
	SAY 0x2f7e @375	
	WRITE_ASCII 0x3016 ~_TASIGHT~ #8
	WRITE_ASCIIT 0x3046 ~F_DEATHK~
	WRITE_ASCII 0x321e ~_HELM08~ #8
	WRITE_ASCII 0x3232 ~_PLAT04~ #8
	WRITE_ASCII 0x3246 ~F_SW2H08~ #8
	// Actor 10
    SAY 0x3262 @43
    SAY 0x3266 @43    
	SAY 0x32fe @371	
	SAY 0x3322 @372	
	SAY 0x3346 @373
	SAY 0x334a @374	
	SAY 0x3366 @375	
	SAY 0x3412 @375	
	WRITE_ASCII 0x34aa ~_TASIGHT~ #8
	WRITE_ASCIIT 0x34da ~F_DEATHK~
	WRITE_ASCII 0x36b2 ~_HELM08~ #8
	WRITE_ASCII 0x36c6 ~_PLAT04~ #8
	WRITE_ASCII 0x36da ~F_SW2H08~ #8
	// Actor 11
	SAY 0x36f6 @42
	SAY 0x36fa @42	
	SAY 0x3792 @371
	SAY 0x37b6 @372
	SAY 0x37da @373
	SAY 0x37de @374
	SAY 0x37fa @375
	SAY 0x38a6 @375
	WRITE_LONG 0x3716 0x2300	// DEATH_KNIGHT
	WRITE_ASCII 0x393e ~_TASIGHT~ #8
	WRITE_ASCII 0x3b46 ~_HELM08~ #8
	WRITE_ASCII 0x3b5a ~_PLAT05~ #8
	WRITE_ASCII 0x3b82 ~_SW2H07~ #8
	// Actor 12
	SAY 0x3b9e @99
	SAY 0x3ba2 @99
    SAY 0x3c3a @446
    SAY 0x3c3e @447
    SAY 0x3c5e @448
    SAY 0x3c62 @449
    SAY 0x3c66 @446
    SAY 0x3c82 @450
    SAY 0x3c86 @451
    SAY 0x3ca2 @449
    SAY 0x3d4e @448
	WRITE_ASCII 0x3de6 ~_TASIGHT~ #8
	// Actor 13
	SAY 0x405a @99
	SAY 0x405e @99	
    SAY 0x40f6 @446
    SAY 0x40fa @447    
    SAY 0x411a @448
    SAY 0x411e @449    
    SAY 0x4122 @446    
    SAY 0x413e @450    
    SAY 0x4142 @451    
    SAY 0x415e @449    
    SAY 0x420a @448
	WRITE_ASCII 0x42a2 ~_TASIGHT~ #8
	// Actor 14
    SAY 0x4516 @43
    SAY 0x451a @43    
	SAY 0x45b2 @371	
	SAY 0x45d6 @372		
	SAY 0x45fa @373
	SAY 0x45fe @374	
	SAY 0x461a @375	
	SAY 0x46c6 @375	
	WRITE_ASCII 0x475e ~_TASIGHT~ #8
	WRITE_ASCIIT 0x478e ~F_DEATHK~
	// Containers:
	WRITE_ASCII 0x5ae6 ~_PLAT04~ #8
	WRITE_ASCII 0x5afa ~_HELM08~ #8
	WRITE_ASCII 0x5b22 ~_POTN08~ #8
	WRITE_ASCII 0x5b5e ~_POTN08~ #8
	WRITE_ASCII 0x5b9a ~_POTN08~ #8
	WRITE_ASCII 0x5bc2 ~_POTN12~ #8

COPY ~DRIZZTSAGA/ARE/F_6667.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x2cfc ~_POTN14~ #8
	WRITE_ASCII 0x2fc4 ~_MB_E40B~ #8
	
COPY ~DRIZZTSAGA/ARE/F_6668.ARE~ ~OVERRIDE~
	WRITE_ASCII 0xb2c ~_HOULLOR~ #8
	WRITE_ASCII 0xc3c ~_HOULLOR~ #8
	WRITE_ASCII 0x19e8 ~_HELM06~ #8
	WRITE_ASCII 0x1a90 ~_MB_E40A~ #8
	
COPY ~DRIZZTSAGA/ARE/F_7777.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x4cc ~_OGREMA~ #8
	WRITE_ASCII 0x5dc ~_WOLFWI~ #8
	WRITE_ASCII 0x6ec ~_WOLFWI~ #8
	WRITE_ASCII 0x7fc ~_WOLFWI~ #8
	WRITE_ASCII 0x90c ~_WOLFWI~ #8
	WRITE_ASCII 0xa1c ~_GREBERZ~ #8
	WRITE_ASCII 0xb2c ~_GREBERZ~ #8
	WRITE_ASCII 0xd4c ~_OGREMA~ #8	
	WRITE_ASCII 0x13c8 ~_WOLFWI~ #8
	WRITE_ASCII 0x13d0 ~_WOLFWI~ #8
	WRITE_ASCII 0x13d8 ~_WOLFWI~ #8	
	WRITE_ASCII 0x1604 ~_MB_E06C~ #8	
	WRITE_ASCII 0x16d0 ~_MB_E01A~ #8
	WRITE_ASCII 0x16d8 ~_MB_E01A~ #8	
	WRITE_ASCII 0x16e4 ~_MB_E01A~ #8
	WRITE_ASCII 0x16ec ~_MB_E01A~ #8

COPY ~DRIZZTSAGA/ARE/F_7778.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x308 ~_POTN02~ #8
	WRITE_ASCII 0x358 ~_POTN08~ #8

COPY ~DRIZZTSAGA/ARE/F_7779.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x19c ~_WEREWO~ #8
	WRITE_ASCII 0x2ac ~_WEREWO~ #8
	WRITE_ASCII 0x3bc ~_WEREWO~ #8
	WRITE_ASCII 0x4cc ~_WEREWO~ #8
	WRITE_ASCII 0x5dc ~_WEREWO~ #8
	WRITE_ASCII 0x6ec ~_WEREWO~ #8
//	WRITE_ASCII 0x7fc ~_EREWOGR~ #8
	WRITE_ASCII 0xa1c ~_WORG~ #8
	WRITE_ASCII 0xb2c ~_WORG~ #8
	WRITE_ASCII 0xc3c ~_WORG~ #8
	WRITE_ASCII 0x129c ~_WEREWO~ #8
	WRITE_ASCII 0x13ac ~_WEREWO~ #8
	WRITE_ASCII 0x14bc ~_WEREWO~ #8
//	WRITE_ASCII 0x15cc ~_EREWOGR~ #8
	WRITE_ASCII 0x1f5c ~_WORG~ #8
	WRITE_ASCII 0x206c ~_WORG~ #8
	WRITE_ASCII 0x26cc ~_WEREWO~ #8
	WRITE_ASCII 0x27dc ~_WEREWO~ #8
	WRITE_ASCII 0x28ec ~_WEREWO~ #8
	WRITE_ASCII 0x2c1c ~_WORG~ #8
	WRITE_ASCII 0x3430 ~_WORG~ #8
	WRITE_ASCII 0x34e8 ~_WEREWO~ #8
//	WRITE_ASCII 0x34f0 ~_EREWOGR~ #8
	WRITE_ASCII 0x35c0 ~_WORG~ #8
	WRITE_ASCII 0x35e8 ~_WORG~ #8
	WRITE_ASCII 0x35f0 ~_WORG~ #8
	WRITE_ASCII 0x35f8 ~_WORG~ #8
	WRITE_ASCII 0x3678 ~_WEREWO~ #8
//	WRITE_ASCII 0x3680 ~_EREWOGR~ #8
	WRITE_ASCII 0x3978 ~_MB_E06B~ #8
	WRITE_ASCII 0x3980 ~_WEREW03~ #8
	WRITE_ASCII 0x3af4 ~_WEREWO~ #8
	WRITE_ASCII 0x3afc ~_WEREWO~ #8
	WRITE_ASCII 0x3b04 ~_WEREWO~ #8
	WRITE_ASCII 0x3b0c ~_WEREWO~ #8
	WRITE_ASCII 0x3b14 ~_WEREWO~ #8
	WRITE_ASCII 0x3b1c ~_WEREWO~ #8
	WRITE_ASCII 0x3b24 ~_WEREWO~ #8

COPY ~DRIZZTSAGA/ARE/F_8888.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x4f4 ~_MB_E02B~ #8
	WRITE_ASCII 0x4fc ~_MB_E02B~ #8
	WRITE_ASCII 0x508 ~_MB_E02B~ #8
	WRITE_ASCII 0x510 ~_MB_E02B~ #8
	
COPY ~DRIZZTSAGA/ARE/F_8889.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x102c ~_MB_E02A~ #8
	WRITE_ASCII 0x1034 ~_MB_E02A~ #8
	WRITE_ASCII 0x1040 ~_MB_E02A~ #8
	WRITE_ASCII 0x1048 ~_MB_E02A~ #8
	
COPY ~DRIZZTSAGA/ARE/F_9191.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x9c8 ~_MB_S01A~ #8
	WRITE_ASCII 0xb04 ~_AMB_N02~ #8
	WRITE_ASCII 0xb0c ~_AMB_N02~ #8
	WRITE_ASCII 0xb18 ~_AMB_N02~ #8
	WRITE_ASCII 0xb20 ~_AMB_N02~ #8

COPY ~DRIZZTSAGA/ARE/F_9292.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x19c ~_HOULLOR~ #8
	WRITE_ASCII 0x2ac ~_HOULLOR~ #8
	WRITE_ASCII 0x4cc ~_SKELWA~ #8
	WRITE_ASCII 0x5dc ~_SKELWA~ #8
	WRITE_ASCII 0x6ec ~_SKELWA~ #8
	WRITE_ASCII 0xc1c ~_AMUL17~ #8
	WRITE_ASCII 0xc30 ~_POTN08~ #8
	WRITE_ASCII 0xc44 ~_POTN08~ #8
	WRITE_ASCII 0xc58 ~_POTN08~ #8
	WRITE_ASCII 0xc6c ~_POTN42~ #8
	WRITE_ASCII 0xd34 ~_AMB_N02~ #8
	WRITE_ASCII 0xd3c ~_AMB_N02~ #8
	WRITE_ASCII 0xd48 ~_AMB_N02~ #8
	WRITE_ASCII 0xd50 ~_AMB_N02~ #8
	WRITE_ASCII 0xdf4 ~_HOULLOR~ #8

COPY ~DRIZZTSAGA/ARE/F_9393.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x33c ~_MB_E40A~ #8
	
COPY ~DRIZZTSAGA/ARE/F_9494.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x520 ~_AMB_N02~ #8
	WRITE_ASCII 0x528 ~_AMB_N02~ #8
	WRITE_ASCII 0x534 ~_AMB_N02~ #8
	WRITE_ASCII 0x53c ~_AMB_N02~ #8
	WRITE_ASCII 0x5d0 ~_WEREWO~ #8
	WRITE_ASCII 0x5d8 ~_WEREWO~ #8
	WRITE_ASCII 0x5e0 ~_WEREWO~ #8
	WRITE_ASCII 0x5e8 ~_WEREWO~ #8
	WRITE_ASCII 0x5f0 ~_WEREWO~ #8
	WRITE_ASCII 0x5f8 ~_WEREWO~ #8
	WRITE_ASCII 0x600 ~_WEREWO~ #8

COPY ~DRIZZTSAGA/ARE/F_9595.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_9696.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_9797.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_9898.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x19c ~_SKELWA~ #8
	WRITE_ASCII 0x2ac ~_SKELWA~ #8
	WRITE_ASCII 0x3bc ~_SKELWA~ #8
	WRITE_ASCII 0x4cc ~_SKELWA~ #8
	WRITE_ASCII 0x5dc ~_SKELWA~ #8
	WRITE_ASCII 0x6ec ~_SKELWA~ #8
	WRITE_ASCII 0x7fc ~_SKELWA~ #8
	WRITE_ASCII 0x90c ~_SKELWA~ #8	
	WRITE_ASCII 0x107c ~_MB_E02B~ #8
	WRITE_ASCII 0x1084 ~_MB_E02B~ #8	
	WRITE_ASCII 0x1090 ~_MB_E02B~ #8
	WRITE_ASCII 0x1098 ~_MB_E02B~ #8	
	WRITE_ASCII 0x112c ~_SKELWA~ #8
	WRITE_ASCII 0x1134 ~_SKELWA~ #8	
	WRITE_ASCII 0x113c ~_SKELWA~ #8	
	WRITE_ASCII 0x1144 ~_SKELWA~ #8	
	WRITE_ASCII 0x114c ~_SKELWA~ #8
	
COPY ~DRIZZTSAGA/ARE/F_9999.ARE~ ~OVERRIDE~
	WRITE_ASCII 0xb58 ~_MB_E02A~ #8
	WRITE_ASCII 0xb60 ~_MB_E02A~ #8
	WRITE_ASCII 0xb6c ~_MB_E02A~ #8
	WRITE_ASCII 0xb74 ~_MB_E02A~ #8

// Add Medusas into the game, part 1
COPY_EXISTING ~FW5506.ARE~ ~OVERRIDE~
	READ_LONG 0x54 ~actoroffset~
	READ_SHORT 0x58 ~actornum~
	SET ~numsofar~=0
	WHILE (~%numsofar%~<~%actornum%~) BEGIN
		READ_ASCII (~%numsofar%~*0x110 + ~%actoroffset%~+0x80) ~crename~
		PATCH_IF !(~%crename%~ STRING_COMPARE_CASE ~_BASILG~) THEN BEGIN
			WRITE_ASCII (~%numsofar%~*0x110 + ~%actoroffset%~+0x80) ~F_MEDUSA~ #8
		END
		SET ~numsofar~=~%numsofar%~+1
	END	
BUT_ONLY_IF_IT_CHANGES
	
// Scripts:	

PRINT @366
	
COMPILE	~DRIZZTSAGA/BAF/Tutu~

ACTION_IF FILE_EXISTS_IN_GAME ~macinit.bcs~ THEN BEGIN	// EasyTutu
  COPY_EXISTING ~_TANARI.BCS~ ~override~
	REPLACE_BCS_BLOCK ~DRIZZTSAGA/SNIP/oTANARI.BAF~ ~DRIZZTSAGA/SNIP/nTANARI.BAF~
  BUT_ONLY_IF_IT_CHANGES
END ELSE BEGIN	// normal Tutu
  COPY_EXISTING ~_TANARI.BCS~ ~override~
	REPLACE_BCS_BLOCK ~DRIZZTSAGA/SNIP/Tutu/oTANARI.BAF~ ~DRIZZTSAGA/SNIP/nTANARI.BAF~
  BUT_ONLY_IF_IT_CHANGES
END

EXTEND_TOP ~_AR0123.BCS~ ~DRIZZTSAGA/SNIP/eAR0123.BAF~
EXTEND_TOP ~_AR1000.BCS~ ~DRIZZTSAGA/SNIP/eARU000.BAF~
EXTEND_TOP ~_AR1001.BCS~ ~DRIZZTSAGA/SNIP/eARU001.BAF~
EXTEND_TOP ~_AR0500.BCS~ ~DRIZZTSAGA/SNIP/eARD000.BAF~


// Add Medusas into the game, part 2
EXTEND_TOP ~_AR3500.BCS~ ~DRIZZTSAGA/SNIP/eAR9400.BAF~

// Update gnolls script to use new drizzt DV:
COPY_EXISTING ~_GNOLLDR.BCS~ ~override~
  DECOMPILE_BCS_TO_BAF
	REPLACE_TEXTUALLY ~"Drizzt"~ ~"F_DRIZZT"~
  COMPILE_BAF_TO_BCS
BUT_ONLY_IF_IT_CHANGES

// Dialogues:

COMPILE ~DRIZZTSAGA/DLG/Tutu~

//Misc:
COPY ~DRIZZTSAGA/misc/F_NIBSHP.sto~         ~override~
  SAY 0x0c @1
  WRITE_ASCII 0x200 ~_POTN17~ #8

// Creatures:

PRINT @360

COPY ~DRIZZTSAGA/Creatures/F_ARTEMI.CRE~ ~override~
  SAY NAME1 @2
  SAY NAME2 @2
  SAY INITIAL_MEETING @3
  SAY MORALE @4
  SAY LEADER @3
  SAY TIRED @5
  SAY BORED @6
  SAY BATTLE_CRY1 @3
  SAY BATTLE_CRY2 @5
  SAY BATTLE_CRY3 @7
  SAY BATTLE_CRY4 @8
  SAY DAMAGE @9
  SAY DYING @10
  SAY SELECT_COMMON1 @3
  SAY SELECT_COMMON2 @5
  SAY SELECT_COMMON3 @6
  SAY BIO @11
  WRITE_ASCII 0x260 ~_TASIGHT~ #8
  WRITE_ASCII 0x268 ~_DPLAYER~ #8
  WRITE_ASCII 0x4e8 ~_RING05~ #8
  WRITE_ASCII 0x4fc ~_RING07~ #8

COPY ~DRIZZTSAGA/Creatures/F_BEARFM.cre~ ~override~
  SAY NAME1 @12
  SAY NAME2 @12
  SAY INITIAL_MEETING @377
  SAY DAMAGE @378
  SAY DYING @379
  SAY SELECT_COMMON1 @380
  WRITE_ASCII 0x3b4 ~_AX1H01~ #8
  WRITE_ASCII 0x268 ~_TASIGHT~ #8

COPY ~DRIZZTSAGA/Creatures/F_BEAROL.cre~ ~override~
  SAY NAME1 @13
  SAY NAME2 @13
  SAY INITIAL_MEETING @381
  SAY DAMAGE @382
  SAY DYING @383
  SAY SELECT_COMMON1 @384
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~_LEAT02~ #8
  WRITE_ASCII 0x3f8 ~_BLUN11~ #8
  WRITE_ASCII 0x40c ~_BLUN03~ #8
  WRITE_ASCII 0x420 ~_MISC53~ #8

COPY ~DRIZZTSAGA/Creatures/F_BEARSU.CRE~ ~override~
  SAY NAME1 @14
  SAY NAME2 @14
  SAY BATTLE_CRY1 @385
  SAY 0xcc @386
  SAY 0xdc @387
  SAY 0xe0 @388
  SAY 0xec @389
  SAY 0xf0 @390
  SAY 0x10c @391
  SAY 0x110 @392
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x414 ~_RING99~ #8
  WRITE_ASCII 0x428 ~_IMMUNE1~ #8
  
COPY ~DRIZZTSAGA/Creatures/F_BEARW2.cre~ ~override~
	 ~DRIZZTSAGA/Creatures/F_BEARW1.cre~ ~override~
  SAY NAME1 @15
  SAY NAME2 @15
  SAY INITIAL_MEETING @393
  SAY BATTLE_CRY1 @393
  SAY 0xec @394
  SAY 0xf0 @395
  SAY 0x1a0 @393
  SAY 0x1a4 @396
  SAY 0x1a8 @397
  SAY 0x1ac @398
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x3c8 ~_LEAT04~ #8
  WRITE_ASCII 0x3dc ~_SHLD08~ #8
  WRITE_ASCII 0x3f0 ~_AX1H01~ #8
    
COPY ~DRIZZTSAGA/Creatures/F_BRUENO.CRE~ ~override~
  SAY NAME1 @22
  SAY NAME2 @22
  SAY INITIAL_MEETING @23
  SAY TIRED @23
  SAY BORED @23
  SAY BATTLE_CRY1 @24
  SAY DAMAGE @25
  SAY DYING @26
  SAY SELECT_COMMON1 @23
  SAY SELECT_COMMON2 @24
  SAY BIO @27
  WRITE_ASCII 0x260 ~_TASIGHT~ #8
  WRITE_ASCII 0x268 ~_DPLAYER~ #8
  WRITE_ASCII 0x4fc ~_SHLD02~ #8
  WRITE_ASCII 0x510 ~_BRAC10~ #8
  WRITE_ASCII 0x538 ~_BOLT06~ #8
  WRITE_ASCII 0x54c ~_POTN08~ #8
  
COPY ~DRIZZTSAGA/Creatures/F_CATTIB.CRE~ ~override~
  SAY NAME1 @28
  SAY NAME2 @28
  SAY INITIAL_MEETING @29
  SAY BATTLE_CRY1 @30
  SAY DAMAGE @31
  SAY DYING @32
  SAY SELECT_COMMON1 @33
  SAY SELECT_COMMON2 @29
  SAY DIALOG_HOSTILE @34
  SAY BIO @35
  WRITE_ASCII 0x260 ~_TASIGHT~ #8
  WRITE_ASCII 0x268 ~_DPLAYER~ #8
  WRITE_ASCII 0x4a4 ~_CHAN07~ #8
  WRITE_ASCII 0x4b8 ~_BRAC04~ #8
  WRITE_ASCII 0x508 ~_POTN08~ #8

COPY ~DRIZZTSAGA/Creatures/F_DEADM2.CRE~ ~override~
  SAY NAME1 @40
  SAY NAME2 @40
  SAY INITIAL_MEETING @376
  SAY DYING @399
  WRITE_ASCII 0x3b4 ~_LEAT04~ #8
  WRITE_ASCII 0x3c8 ~_RING14~ #8
  WRITE_ASCII 0x3dc ~_AX1H01~ #8
  WRITE_ASCII 0x3f0 ~_BOW03~ #8

COPY ~DRIZZTSAGA/Creatures/F_deathl.CRE~ ~override~
  SAY NAME1 @43
  SAY NAME2 @43
  SAY INITIAL_MEETING @371
  SAY BATTLE_CRY1 @372
  SAY DAMAGE @373
  SAY DYING @374
  SAY SELECT_COMMON1 @375  
  SAY PICKED_POCKET @375
  WRITE_ASCII 0x280 ~F_DEATHK~ #18
  WRITE_ASCII 0x250 ~_TASIGHT~ #8
  WRITE_ASCII 0x468 ~_HELM08~ #8
  WRITE_ASCII 0x47c ~_PLAT04~ #8

COPY ~DRIZZTSAGA/Creatures/F_DEMDRG.CRE~ ~override~
  SAY NAME1 @44
  SAY NAME2 @44
  SAY INITIAL_MEETING @400
  SAY 0xa8 @401
  SAY 0xc8 @402
  SAY 0xdc @403
  SAY 0xe0 @404
  SAY 0xec @405
  SAY 0xf0 @406
  SAY 0x10c @407
  SAY 0x110 @408
  SAY 0x114 @409
  SAY 0x1b8 @407
  WRITE_ASCII 0x248 ~_TANARI~ #8
  WRITE_ASCII 0x260 ~_TASIGHT~ #8
  WRITE_ASCII 0x414 ~_INGDEMN~ #8
  WRITE_ASCII 0x428 ~_S1-10~ #8
  WRITE_ASCII 0x43c ~_WYVERN2~ #8
  
COPY ~DRIZZTSAGA/Creatures/F_DEMSPI.CRE~ ~override~
  SAY NAME1 @45
  SAY NAME2 @45
  SAY BATTLE_CRY1 @410
  SAY 0xcc @411
  SAY 0xdc @412
  SAY 0xe0 @413
  SAY 0xec @414
  SAY 0xf0 @415
  SAY 0x10c @416
  SAY 0x110 @417
  SAY 0x1b8 @418
  WRITE_ASCII 0x248 ~_PSPIDER~ #8
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~_MAGE06~ #8
  WRITE_ASCII 0x3f8 ~_ANTIWEB~ #8

COPY ~DRIZZTSAGA/Creatures/F_DEMWAR.CRE~ ~override~
  SAY NAME1 @46
  SAY NAME2 @46
  SAY 0xc8 @419
  SAY 0xcc @420
  SAY 0xd0 @421
  SAY 0xd4 @422
  SAY 0xec @420
  SAY 0xf0 @423
  SAY 0x10c @419
  SAY 0x110 @420
  SAY 0x114 @421
  SAY 0x118 @422
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~_HELM08~ #8
  WRITE_ASCII 0x3f8 ~_PLAT04~ #8
  WRITE_ASCII 0x40c ~_RING95~ #8
  WRITE_ASCII 0x420 ~_SW1H11~ #8

COPY ~DRIZZTSAGA/Creatures/F_DIPNOS.cre~ ~override~
  SAY NAME1 @47
  SAY NAME2 @47
  SAY INITIAL_MEETING @95
  SAY DAMAGE @91
  SAY DYING @92
  SAY 0x10c @95
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~_LEAT02~ #8
  WRITE_ASCII 0x3f8 ~_SW1H08~ #8

COPY ~DRIZZTSAGA/Creatures/F_DRAGON.CRE~ ~override~
  SAY NAME1 @48
  SAY NAME2 @48
  SAY 0xc8 @427
  SAY 0xcc @428
  SAY 0xdc @429
  SAY 0xe0 @430
  SAY 0xe4 @431
  SAY 0xec @432
  SAY 0xf0 @433
  SAY 0x10c @434
  SAY 0x110 @435
  SAY 0x1b8 @436
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~_RING97~ #8

COPY ~DRIZZTSAGA/Creatures/F_DRIZZT.CRE~ ~override~
  SAY NAME1 @49
  SAY NAME2 @49
  SAY INITIAL_MEETING @50
  SAY UNHAPPY_BREAKING_POINT  @51
  SAY BORED @50
  SAY BATTLE_CRY1 @52
  SAY BATTLE_CRY2 @53
  SAY BATTLE_CRY3 @54
  SAY DAMAGE @55
  SAY DYING @56
  SAY SELECT_COMMON1 @57
  SAY SELECT_COMMON2 @58
  SAY SELECT_COMMON3 @53
  SAY SELECT_COMMON4 @54
  SAY DIALOG_HOSTILE @59
  SAY BIO @60
  WRITE_ASCII 0x260 ~_TASIGHT~ #8
  WRITE_ASCII 0x268 ~_DPLAYER~ #8
  WRITE_ASCII 0x2cc ~_DRIZZT~ #8
  WRITE_ASCII 0x5b8 ~_CHAN06~ #8
  WRITE_ASCII 0x5cc ~_AMUL17~ #8
  WRITE_ASCII 0x5e0 ~_BOOT01~ #8

COPY ~DRIZZTSAGA/Creatures/F_DROMAG.CRE~ ~override~
  SAY NAME1 @61
  SAY NAME2 @61
  SAY INITIAL_MEETING @76
  SAY TIRED @77
  SAY BORED @77
  SAY BATTLE_CRY1 @78
  SAY AREA_CITY @77
  SAY DAMAGE ~~ [F_DRSL16]
  SAY DYING ~~ [F_DRSL15]
  SAY SELECT_COMMON3 @77 
  SAY SELECT_COMMON2 @82 
  SAY SELECT_COMMON1 @17
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~_CLCK10~ #8
  WRITE_ASCII 0x420 ~_POTN03~ #8

COPY ~DRIZZTSAGA/Creatures/F_DROWAR.CRE~ ~override~
  SAY NAME1 @62
  SAY NAME2 @62
  SAY BATTLE_CRY1 @78
  SAY DAMAGE ~~ [F_DRSL16]
  SAY DYING ~~ [F_DRSL15]
  SAY TIRED @77 
  SAY BORED @77 
  SAY AREA_CITY @77 
  SAY SELECT_COMMON3 @77 
  SAY SELECT_COMMON2 @82 
  SAY SELECT_COMMON1 @17 
  SAY INITIAL_MEETING @18 
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~_PLAT01~ #8
  WRITE_ASCII 0x40c ~_POTN08~ #8

COPY ~DRIZZTSAGA/Creatures/F_DROWPR.CRE~ ~override~
  SAY NAME1 @63
  SAY NAME2 @63
  SAY BATTLE_CRY1 @19 
  SAY DAMAGE @424
  SAY DYING @425
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~_PLAT01~ #8
  WRITE_ASCII 0x3f8 ~_HAMM03~ #8
  WRITE_ASCII 0x40c ~_POTN08~ #8
  
COPY ~DRIZZTSAGA/Creatures/F_DRSCUL.CRE~ ~override~
  SAY NAME1 @64
  SAY NAME2 @64
  SAY 0xc8 @402
  SAY 0xec @405
  SAY 0xf0 @406
  WRITE_ASCII 0x3e4 ~_IMMUNE1~ #8

COPY ~DRIZZTSAGA/Creatures/F_DWSMIT.CRE~ ~override~
  SAY NAME1 @65
  SAY NAME2 @65
  SAY INITIAL_MEETING @23
  SAY TIRED @23
  SAY BORED @23
  SAY BATTLE_CRY1 @24
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~_HELM01~ #8
  WRITE_ASCII 0x3f8 ~_CHAN02~ #8
  WRITE_ASCII 0x40c ~_HAMM02~ #8

COPY ~DRIZZTSAGA/Creatures/F_ELMINS.CRE~ ~override~
  SAY NAME1 @66
  SAY NAME2 @66
  SAY INITIAL_MEETING @341
  SAY UNHAPPY_BREAKING_POINT @342
  SAY BATTLE_CRY1 @343
  SAY DAMAGE @344
  SAY DYING @345
  SAY SELECT_COMMON1 @346
  SAY SELECT_COMMON2 @347
  SAY SELECT_COMMON3 @348
  SAY SELECT_ACTION4 @349
  WRITE_ASCII 0x3e4 ~_STAF01~ #8

COPY ~DRIZZTSAGA/Creatures/F_ERRTU.CRE~ ~override~
  SAY NAME1 @67
  SAY NAME2 @67
  SAY INITIAL_MEETING @400
  SAY 0xa8 @401
  SAY 0xc8 @402
  SAY 0xdc @403
  SAY 0xe0 @404
  SAY 0xec @405
  SAY 0xf0 @406
  SAY 0x10c @407
  SAY 0x110 @408
  SAY 0x114 @409
  SAY 0x1b8 @407
  WRITE_ASCII 0x260 ~_TASIGHT~ #8
  WRITE_ASCII 0x414 ~_INGDEMN~ #8
  WRITE_ASCII 0x428 ~_S1-10~ #8
  WRITE_ASCII 0x43c ~_WYVERN2~ #8

COPY ~DRIZZTSAGA/Creatures/F_GHOST.CRE~ ~override~
  SAY NAME1 @69
  SAY NAME2 @69
  SAY 0xc8 @437
  SAY 0xcc @438
  SAY 0xdc @437
  SAY 0xec @439
  SAY 0xf0 @440
  SAY 0x10c @441
  SAY 0x110 @437
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x414 ~_RING99~ #8
  WRITE_ASCII 0x428 ~_IMMUNE1~ #8

COPY ~DRIZZTSAGA/Creatures/F_JARLAX.cre~ ~override~
  SAY NAME1 @75
  SAY NAME2 @75
  SAY INITIAL_MEETING @76
  SAY TIRED @77
  SAY BORED @77
  SAY BATTLE_CRY1 @78
  SAY DAMAGE @79
  SAY DYING @80
  SAY AREA_CITY @77
  SAY SELECT_COMMON1 @81
  SAY SELECT_COMMON2 @82
  SAY SELECT_COMMON3 @77
  SAY BIO @83
  WRITE_ASCII 0x260 ~_TASIGHT~ #8
  WRITE_ASCII 0x268 ~_DPLAYER~ #8
  WRITE_ASCII 0x4b8 ~_BRAC10~ #8
  WRITE_ASCII 0x4cc ~_BOOT01~ #8
  WRITE_ASCII 0x508 ~_POTN06~ #8  
  
COPY ~DRIZZTSAGA/Creatures/F_REGIS2.CRE~ ~override~
	 ~DRIZZTSAGA/Creatures/F_REGIS.CRE~ ~override~
  SAY NAME1 @89
  SAY NAME2 @89
  SAY INITIAL_MEETING @90
  SAY DAMAGE @91
  SAY DYING @92
  SAY SELECT_COMMON1 @93
  SAY SELECT_COMMON2 @94
  SAY SELECT_COMMON3 @95
  SAY BIO @96  
  PATCH_IF ("%SOURCE_RES%" STRING_EQUAL_CASE "F_REGIS2") BEGIN
    WRITE_ASCII 0x3dc ~_LEAT07~ #8
    WRITE_ASCII 0x3f0 ~_SW1H10~ #8
    WRITE_ASCII 0x404 ~_POTN08~ #8
    WRITE_ASCII 0x268 ~_TASIGHT~ #8
  END ELSE BEGIN
    WRITE_ASCII 0x2d4 ~_LEAT07~ #8
    WRITE_ASCII 0x2e8 ~_BOOT01~ #8
    WRITE_ASCII 0x2fc ~_SW1H09~ #8    
  END

COPY ~DRIZZTSAGA/Creatures/F_ROBED2.CRE~ ~override~
  SAY NAME1 @97
  SAY NAME2 @97
  SAY INITIAL_MEETING @351
  SAY BATTLE_CRY1 @352
  SAY DAMAGE ~~ [F_IREN05]
  SAY DYING ~~ [F_IREN06]
  WRITE_ASCII 0x268 ~_TASIGHT~ #8

COPY ~DRIZZTSAGA/Creatures/F_ROBED.CRE~ ~override~
  SAY NAME1 @97
  SAY NAME2 @97
  SAY INITIAL_MEETING @443
  SAY 0xec @444
  SAY 0xf0 @445
  SAY 0x10c @443
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x420 ~_INGLOUP~ #8

COPY ~DRIZZTSAGA/Creatures/F_SLAYSH.cre~ ~override~
  SAY NAME1 @99
  SAY NAME2 @99
  SAY INITIAL_MEETING @446
  SAY 0xa8 @447
  SAY 0xc8 @448
  SAY 0xcc @449
  SAY 0xd0 @446
  SAY 0xec @450
  SAY 0xf0 @451
  SAY 0x10c @449
  SAY 0x1bc @448
  WRITE_ASCII 0x250 ~_TASIGHT~ #8
  WRITE_ASCII 0x444 ~_IMMUNE1~ #8

COPY ~DRIZZTSAGA/Creatures/F_SPIBEA.CRE~ ~override~
  SAY NAME1 @14
  SAY NAME2 @14
  SAY 0xc8 @385
  SAY 0xcc @386
  SAY 0xdc @387
  SAY 0xe0 @388
  SAY 0xec @389
  SAY 0xf0 @390
  SAY 0x10c @391
  SAY 0x110 @392
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x414 ~_RING99~ #8
  WRITE_ASCII 0x428 ~_IMMUNE1~ #8

COPY ~DRIZZTSAGA/Creatures/F_SPIDQU.CRE~ ~override~
  SAY NAME1 @100
  SAY NAME2 @100
  SAY INITIAL_MEETING @452
  SAY 0xc8 @453
  SAY 0xec @454
  SAY 0xf0 @455
  SAY 0x10c @453
  SAY 0x110 @452
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~_RING95~ #8
  WRITE_ASCII 0x3f8 ~_IMMUNE1~ #8
  WRITE_ASCII 0x40c ~_ANTIWEB~ #8  

COPY ~DRIZZTSAGA/Creatures/F_SUMSPI.CRE~ ~override~
  SAY NAME1 @102
  SAY NAME2 @102
  SAY 0xc8 @410
  SAY 0xcc @411
  SAY 0xdc @412
  SAY 0xe0 @413
  SAY 0xec @414
  SAY 0xf0 @415
  SAY 0x10c @416
  SAY 0x110 @417
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~_ANTIWEB~ #8
  WRITE_ASCII 0x3f8 ~_SPIDPH1~ #8

COPY ~DRIZZTSAGA/Creatures/F_TANARI.CRE~ ~override~
	 ~DRIZZTSAGA/Creatures/F_TANSUM.CRE~ ~override~
  SAY NAME1 @103
  SAY NAME2 @103
  SAY INITIAL_MEETING @400
  SAY 0xa8 @401
  SAY 0xc8 @402
  SAY 0xdc @403
  SAY 0xe0 @404
  SAY 0xec @405
  SAY 0xf0 @406
  SAY 0x10c @407
  SAY 0x110 @408
  SAY 0x114 @409
  SAY 0x1b8 @407
  WRITE_ASCII 0x260 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~_INGDEMN~ #8
  WRITE_ASCII 0x3f8 ~_S1-10~ #8

COPY ~DRIZZTSAGA/Creatures/F_WERECH.CRE~ ~override~
  SAY NAME1 @107
  SAY NAME2 @107
  SAY INITIAL_MEETING @456
  SAY 0xc8 @457
  SAY 0xcc @458
  SAY 0xec @459
  SAY 0xf0 @460
  SAY 0x10c @458
  SAY 0x1b8 @458
  WRITE_ASCII 0x250 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~IMMUNE2~ #8

COPY ~DRIZZTSAGA/Creatures/F_WLFSPR.cre~ ~override~
  SAY NAME1 @108
  SAY NAME2 @108
  SAY 0xc8 @461
  SAY 0xcc @462
  SAY 0xdc @463
  SAY 0xe0 @464
  SAY 0xec @465
  SAY 0xf0 @466
  SAY 0x10c @467
  SAY 0x110 @468
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x444 ~_RING99~ #8
  WRITE_ASCII 0x458 ~_IMMUNE1~ #8
  
COPY ~DRIZZTSAGA/Creatures/F_WULFGA.CRE~ ~override~
  SAY NAME1 @109
  SAY NAME2 @109
  SAY INITIAL_MEETING @110
  SAY UNHAPPY_BREAKING_POINT @111
  SAY BATTLE_CRY1 @112
  SAY BATTLE_CRY2 @113
  SAY BATTLE_CRY3 @114
  SAY DAMAGE @115
  SAY DYING @116
  SAY SELECT_COMMON1 @110
  SAY SELECT_COMMON2 @117
  SAY SELECT_COMMON3 @114
  SAY SELECT_COMMON4 @113
  SAY DIALOG_HOSTILE @118
  SAY BIO @119
  WRITE_ASCII 0x268 ~_DPLAYER~ #8
  WRITE_ASCII 0x4cc ~_SHLD02~ #8
  WRITE_ASCII 0x508 ~_POTN08~ #8
  WRITE_ASCII 0x51c ~_POTN20~ #8

COPY ~DRIZZTSAGA/Creatures/F_DEATHK.CRE~ ~override~	
  SAY NAME1 @42
  SAY NAME2 @42
  SAY INITIAL_MEETING @371
  SAY BATTLE_CRY1 @372
  SAY DAMAGE @373
  SAY DYING @374
  SAY SELECT_COMMON1 @375  
  SAY PICKED_POCKET @375
  WRITE_LONG 0x28 0x2300	// DEATH_KNIGHT
  WRITE_ASCII 0x260 ~_TASIGHT~ #8
  WRITE_ASCII 0x408 ~_HELM08~ #8
  WRITE_ASCII 0x41c ~_PLAT05~ #8
  WRITE_ASCII 0x444 ~_SW2H07~ #8

COPY ~DRIZZTSAGA/Creatures/F_ETTIN.cre~ ~override~
  SAY NAME1 @68
  SAY NAME2 @68
  SAY INITIAL_MEETING ~~ [ETTIN01]
  SAY BATTLE_CRY1 ~~ [ETTIN03A]
  SAY ATTACK1 ~~ [ETTIN04A]
  SAY DAMAGE ~~ [ETTIN08]
  SAY DYING ~~ [ETTIN09A]
  WRITE_LONG 0x28 0xE010		// IC_ETTIN
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
	
COPY ~DRIZZTSAGA/Creatures/F_GIANTF.cre~ ~override~
  SAY NAME1 @70
  SAY NAME2 @70
  SAY INITIAL_MEETING ~~ [F_GIANT1]
  SAY BATTLE_CRY1 ~~ [F_GIANT1]
  SAY DAMAGE ~~ [F_GIANT4]
  SAY DYING ~~ [F_GIANT5]
  WRITE_LONG 0x28 0xE710		// IC_OROG2
  WRITE_ASCII 0x258 ~_TASIGHT~ #8
  WRITE_ASCII 0x40c ~_POTN11~ #8
	
COPY ~DRIZZTSAGA/Creatures/F_CORN.CRE~ ~override~
	 ~DRIZZTSAGA/Creatures/F_CORN02.CRE~ ~override~
  SAY NAME1 @36
  SAY NAME2 @36
  SAY INITIAL_MEETING ~~ [F_CORN01]
  SAY BATTLE_CRY1 ~~ [F_CORN02]
  SAY ATTACK1 ~~ [F_CORN03]
  SAY ATTACK2 ~~ [F_CORN04]
  SAY DAMAGE ~~ [F_CORN08]
  SAY DYING ~~ [F_CORN09]
  SAY SELECT_COMMON1 ~~ [F_CORN01]
  WRITE_LONG 0x28 0xE0E0		// IC_CORNUGONSKI
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~_INGDEMN~ #8

COPY ~DRIZZTSAGA/Creatures/F_orc.cre~ ~override~
  SAY NAME1 @88
  SAY NAME2 @88
  SAY INITIAL_MEETING ~~ [F_ORC01]
  SAY BATTLE_CRY1 ~~ [F_ORC02]
  SAY ATTACK1 ~~ [F_ORC03]
  SAY ATTACK2 ~~ [F_ORC04]
  SAY DAMAGE ~~ [F_ORC08]
  SAY DYING ~~ [F_ORC09]
  WRITE_LONG 0x28 0xE800		// IC_ORC_MELEE1
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~_HELM01~ #8
  WRITE_ASCII 0x3f8 ~_AX1H01~ #8
	
COPY ~DRIZZTSAGA/Creatures/F_BEL.CRE~ ~override~
  SAY NAME1 @16
  SAY NAME2 @16
  SAY INITIAL_MEETING ~~ [F_BEL01]
  SAY BATTLE_CRY1 ~~ [F_BEL01]
  SAY ATTACK1 ~~ [F_BEL03]
  SAY ATTACK2 ~~ [F_BEL04]
  SAY DAMAGE ~~ [F_BEL08]
  SAY DYING ~~ [F_BEL09]
  WRITE_LONG 0x28 0xE0D0		// IC_UMBERHULK
  WRITE_ASCII 0x260 ~_TASIGHT~ #8

COPY ~DRIZZTSAGA/Creatures/F_CYCLOP.cre~ ~override~
  SAY NAME1 @37
  SAY NAME2 @37
  SAY INITIAL_MEETING ~~ [F_CYCLO1]
  SAY BATTLE_CRY1 ~~ [F_CYCLO5]
  SAY ATTACK1 ~~ [F_CYCLO3]
  SAY ATTACK2 ~~ [F_CYCLO4]
  SAY DAMAGE ~~ [F_CYCLO8]
  SAY DYING ~~ [F_CYCLO9]
  SAY SELECT_COMMON1 ~~ [F_CYCLO1]
  WRITE_LONG 0x28 0xE000   //IC_CYCLOP
  WRITE_ASCII 0x268 ~_TASIGHT~ #8

COPY ~DRIZZTSAGA/Creatures/F_MARI.cre~ ~override~
  SAY NAME1 @85
  SAY NAME2 @85
  SAY INITIAL_MEETING ~~ [F_MARB01]
  SAY MORALE ~~ [F_MARB04]
  SAY BATTLE_CRY1 ~~ [F_MARB01]
  SAY BATTLE_CRY2 ~~ [F_MARB02]
  SAY BATTLE_CRY3 ~~ [F_MARB03]
  SAY ATTACK1 ~~ [F_MARAT1]
  SAY ATTACK2 ~~ [F_MARAT2]
  SAY ATTACK3 ~~ [F_MARAT4]
  SAY DAMAGE ~~ [F_MARAT6]
  SAY DYING ~~ [F_MARAT7]
  WRITE_LONG 0x28 0xE090   //IC_MERILITH
  WRITE_ASCII 0x268 ~_TASIGHT~ #8

COPY ~DRIZZTSAGA/Creatures/F_GUEN.CRE~ ~override~
  SAY NAME1 @73
  SAY NAME2 @73
  SAY INITIAL_MEETING ~~ [F_PANTH1]
  SAY BATTLE_CRY1 ~~ [F_PANTH1]
  SAY BATTLE_CRY2 ~~ [F_PANTH2]
  SAY ATTACK1 ~~ [F_PANTH3]
  SAY ATTACK2 ~~ [F_PANTH4]
  SAY ATTACK3 ~~ [F_PANTH5]
  SAY DAMAGE ~~ [F_PANTH6]
  SAY DYING ~~ [F_PANTH7]
  SAY SELECT_COMMON1 ~~ [F_PANTH1]
  WRITE_LONG 0x28 0x7F0A   //GREATCAT_PANTHER
  WRITE_ASCII 0x268 ~_TASIGHT~ #8

COPY ~DRIZZTSAGA/Creatures/F_HARPY.CRE~ ~override~
  SAY NAME1 @74
  SAY NAME2 @74
  SAY INITIAL_MEETING ~~ [F_HARPY1]
  SAY BATTLE_CRY1 ~~ [F_HARPY3]
  SAY BATTLE_CRY2 ~~ [F_HARPY1]
  SAY ATTACK1 ~~ [F_HARPY4]
  SAY ATTACK2 ~~ [F_HARPY6]
  SAY DAMAGE ~~ [F_HARPY8]
  SAY DYING ~~ [F_HARPY9]
  SAY SELECT_COMMON1 ~~ [F_HARPY1]
  WRITE_LONG 0x28 0xE0A0   //IC_ICE_TROLL
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x444 ~_IMMUNE1~ #8
	
COPY ~DRIZZTSAGA/Creatures/F_GOBELE.CRE~ ~override~
  SAY NAME1 @71
  SAY NAME2 @71
  SAY INITIAL_MEETING ~~ [F_GOB01]
  SAY BATTLE_CRY1 ~~ [F_GOB11]
  SAY BATTLE_CRY2 ~~ [F_GOB02]
  SAY ATTACK1 ~~ [F_GOB03]
  SAY ATTACK2 ~~ [F_GOB04]
  SAY DAMAGE ~~ [F_GOB08]
  SAY DYING ~~ [F_GOB09]
  SAY SELECT_COMMON1 ~~ [F_GOB10]
  WRITE_LONG 0x28 0xE420	// IC_GOBLINELITE_AXE
  WRITE_ASCII 0x258 ~_XVART~ #8
  WRITE_ASCII 0x268 ~_WDARSGT~ #8
  WRITE_ASCII 0x3f8 ~_SW1H08~ #8
  WRITE_ASCII 0x420 ~_LEAT04~ #8
	
COPY ~DRIZZTSAGA/Creatures/F_GOBLIN.CRE~ ~override~
  SAY NAME1 @72
  SAY NAME2 @72
  SAY INITIAL_MEETING ~~ [F_GOB01]
  SAY BATTLE_CRY1 ~~ [F_GOB11]
  SAY BATTLE_CRY2 ~~ [F_GOB02]
  SAY ATTACK1 ~~ [F_GOB03]
  SAY ATTACK2 ~~ [F_GOB04]
  SAY DAMAGE ~~ [F_GOB08]
  SAY DYING ~~ [F_GOB09]
  SAY SELECT_COMMON1 ~~ [F_GOB10]
  WRITE_LONG 0x28 0xE400	// IC_GOBLIN_AXE
  WRITE_ASCII 0x258 ~_XVART~ #8
  WRITE_ASCII 0x268 ~_WDARSGT~ #8
  WRITE_ASCII 0x3f8 ~_SW1H07~ #8

COPY ~DRIZZTSAGA/Creatures/F_LICH.cre~ ~override~
  SAY NAME1 @84
  SAY NAME2 @84
  SAY 0xc8 @438
  SAY 0xcc @470
  SAY 0xf0 @439
  WRITE_LONG 0x28 0x7F0D	// LICH
  WRITE_ASCII 0x250 ~_INITDLG~ #8
  WRITE_ASCII 0x268 ~_TASIGHT~ #8
  WRITE_ASCII 0x46c ~_GHAST1~ #8

COPY ~DRIZZTSAGA/Creatures/F_MUMMY.CRE~ ~override~
  SAY NAME1 @86
  SAY NAME2 @86
  SAY 0xc8 @471
  SAY 0xcc @472
  SAY 0xdc @473
  SAY 0xe0 @474
  SAY 0xf0 @439
  SAY 0x10c @475
  SAY 0x110 @476
  WRITE_LONG 0x28 0xE080	// IC_MUMMY
  WRITE_ASCII 0x268 ~_TASIGHT~ #8 
  WRITE_ASCII 0x3f8 ~_RING95~ #8

COPY ~DRIZZTSAGA/Creatures/F_SHFIEN.CRE~ ~override~
  SAY NAME1 @98
  SAY NAME2 @98
  SAY 0xc8 @438
  SAY 0xdc @438
  SAY 0xf0 @440
  WRITE_LONG 0x28 0x7703	// SHADOW
  WRITE_ASCII 0x268 ~_TASIGHT~ #8 
  WRITE_ASCII 0x414 ~_RING95~ #8
  WRITE_ASCII 0x428 ~_IMMUNE1~ #8
  WRITE_ASCII 0x43c ~_GHOUL1~ #8

COPY ~DRIZZTSAGA/Creatures/F_VALEN.CRE~ ~override~
  SAY NAME1 @104
  SAY NAME2 @104
  SAY BATTLE_CRY1 @20
  SAY BATTLE_CRY2 @21
  SAY DAMAGE ~~ [F_VMPFX7]
  SAY DYING ~~ [F_VMPFX8]
  WRITE_LONG 0x28 0x7F22	// VAMPIRE_FEMALE
  WRITE_ASCII 0x268 ~_TASIGHT~ #8 

COPY ~DRIZZTSAGA/Creatures/F_VAMPF.CRE~ ~override~
  SAY NAME1 @105
  SAY NAME2 @105
  SAY BATTLE_CRY1 @20
  SAY BATTLE_CRY2 @21
  SAY DAMAGE ~~ [F_VMPFX7]
  SAY DYING ~~ [F_VMPFX8]
  WRITE_LONG 0x28 0x7F22	// VAMPIRE_FEMALE
  WRITE_ASCII 0x268 ~_TASIGHT~ #8 

COPY ~DRIZZTSAGA/Creatures/WEREWOGR.cre~         ~override~
  SAY NAME1 @131
  SAY NAME2 @131
  SAY INITIAL_MEETING @456
  SAY 0xc8 @457
  SAY 0xcc @458
  SAY 0xec @459
  SAY 0xf0 @460
  SAY 0x10c @457
  SAY 0x110 @458
  WRITE_LONG 0x28 0x7E01 //WEREWOLF_GREATER
  WRITE_ASCII 0x250 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~IMMUNE2~ #8	// WRITE_ASCII 0x3e4 ~_INGLOUP~ #8	--> would make him pretty much invincible
  WRITE_ASCII 0x3f8 ~_S1-12~ #8

COPY ~DRIZZTSAGA/Creatures/WOLFWEGR.cre~         ~override~
  SAY NAME1 @132
  SAY NAME2 @132 
  SAY INITIAL_MEETING @456
  SAY 0xc8 @457
  SAY 0xcc @458
  SAY 0xec @459
  SAY 0xf0 @460
  SAY 0x10c @457
  SAY 0x110 @458
  WRITE_LONG 0x28 0x7E01 //WEREWOLF_GREATER
  WRITE_ASCII 0x250 ~_TASIGHT~ #8
  WRITE_ASCII 0x3e4 ~_IMMUNE1~ #8
  WRITE_ASCII 0x3f8 ~_INGWOLF~ #8
  WRITE_ASCII 0x40c ~_S1-12~ #8
  WRITE_ASCII 0x420 ~_MISC96~ #8
  
COPY_EXISTING ~_DEATHK1.CRE~ ~override~
			  ~_DEATHK.CRE~ ~override~
    REPLACE_CRE_ITEM ~F_DEATHS~ #0 #0 #0 ~UNDROPPABLE~ ~WEAPON1~ EQUIP
    ADD_CRE_ITEM ~_SW2H07~ #0 #0 #0 ~NONE~ ~INV~
    PATCH_IF ("%SOURCE_RES%" STRING_EQUAL_CASE "_DEATHK") BEGIN
    	REPLACE_CRE_ITEM ~_HELM08~ #0 #0 #0 ~NONE~ ~HELMET~
    	REPLACE_CRE_ITEM ~_PLAT05~ #0 #0 #0 ~NONE~ ~ARMOR~
    END
BUT_ONLY_IF_IT_CHANGES

COPY ~DRIZZTSAGA/Creatures/F_DEADBO.cre~ ~override~
  SAY NAME1 @38
  SAY NAME2 @38
  SAY INITIAL_MEETING @376
  
COPY ~DRIZZTSAGA/Creatures/F_DEADMA.cre~ ~override~
  SAY NAME1 @40
  SAY NAME2 @40
  SAY INITIAL_MEETING @376

COPY ~DRIZZTSAGA/Creatures/F_DEADWM.cre~ ~override~
  SAY NAME1 @41
  SAY NAME2 @41
  SAY INITIAL_MEETING @376
  
COPY ~DRIZZTSAGA/Creatures/F_NIB.cre~ ~override~
  SAY NAME1 @87
  SAY NAME2 @87
  SAY INITIAL_MEETING @350
  SAY SELECT_COMMON1 @350
  SAY 0xec @91
  SAY 0xf0 @92

COPY ~DRIZZTSAGA/Creatures/F_WAILIN.CRE~ ~override~
  SAY NAME1 @106
  SAY NAME2 @106
  SAY 0xc8 @469
  SAY 0xdc @469
  SAY DAMAGE ~~ [F_VMPFX7]
  SAY DYING ~~ [F_VMPFX8]

/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

END ELSE BEGIN
ACTION_IF FILE_EXISTS ~Data/BG1ARE.bif~ THEN BEGIN // BGT

AT_INTERACTIVE_EXIT ~VIEW DRIZZTSAGA\DrizztSaga-ReadMe.html~

PRINT @354

COPY - ~DRIZZTSAGA/misc/F_PATCH.2DA~ ~override~
	REPLACE_TEXTUALLY "AR4200" "AR3100"
	COUNT_2DA_ROWS 5 GAM_count
	READ_2DA_ENTRIES_NOW ~#GAM_patch_table~ 5

// XPCAP.2DA patching unnecessary
  
// Worldmap

PRINT @359

OUTER_SPRINT "#_areas" ""            //table declaration
COPY - ~DRIZZTSAGA/Worldmap/BGT/areas.tbl~ ~override~
 COUNT_2DA_ROWS 10 new_areas_num
 READ_2DA_ENTRIES_NOW ~#_areas~ 10

OUTER_SPRINT "#_links" ""            //table declaration
COPY - ~DRIZZTSAGA/Worldmap/BGT/links.tbl~ ~override~
 COUNT_2DA_ROWS 12 new_links_num
 READ_2DA_ENTRIES_NOW ~#_links~ 12
 
LAUNCH_ACTION_MACRO ~MAP_UPDATE~

// CRE Animations:

PRINT @358

OUTER_SET "SOUNDS" = 0

ACTION_IF NOT (FILE_EXISTS ~data/ROT-RULE.BIF~ OR FILE_EXISTS ~data/TDD-RULE.BIF~) THEN BEGIN
	OUTER_SET "SOUNDS" = 1
	COPY ~DRIZZTSAGA/Anim/MNO2~ ~override~         //FROST GIANT
	COPY_EXISTING ~ORC06.cre~      ~override~
              ~HLOLAF.cre~         ~override~
              ~CHAK.cre~           ~override~
              ~AR18FIG.cre~        ~override~
		WRITE_LONG 0x28  0xE700   //IC_OROG1 instead of IC_OROG2
	BUT_ONLY_IF_IT_CHANGES
END

ACTION_IF NOT (FILE_EXISTS ~data/TS-RULE.bif~ OR FILE_EXISTS ~data/ROT-RULE.BIF~) THEN BEGIN
	COPY ~DRIZZTSAGA/Anim/MUMB~ ~override~         //Belhifet
END

ACTION_IF NOT (FILE_EXISTS ~data/TDD-RULE.bif~ OR FILE_EXISTS ~data/ROT-RULE.BIF~) THEN BEGIN
	OUTER_SET "SOUNDS" = 1
	COPY ~DRIZZTSAGA/Anim/MCYC~ ~override~         //Cyclop
END

ACTION_IF NOT (FILE_EXISTS ~data/TDD-RULE.bif~ OR FILE_EXISTS ~data/ROT-RULE.BIF~) THEN BEGIN
	COPY ~DRIZZTSAGA/Anim/MTAN~ ~override~         //Merilith
END

//ACTION_IF NOT (FILE_EXISTS ~data/CTB-RULE.bif~ OR FILE_EXISTS ~data/ROT-RULE.BIF~) THEN BEGIN
	COPY ~DRIZZTSAGA/Anim/MTIC~ ~override~         //Harpy
//END

ACTION_IF ("%SOUNDS%" = 1) THEN BEGIN
	AT_EXIT ~DRIZZTSAGA/Sounds.bat~
END

// Areas:

PRINT @362

COPY ~DRIZZTSAGA/ARE/F_0111.are~ ~OVERRIDE~
	
COPY ~DRIZZTSAGA/ARE/F_0112.are~ ~OVERRIDE~
		
COPY ~DRIZZTSAGA/ARE/F_0113.ARE~ ~OVERRIDE~
	
COPY ~DRIZZTSAGA/ARE/F_0114.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_0115.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_0222.ARE~ ~OVERRIDE~
	
COPY ~DRIZZTSAGA/ARE/F_0223.ARE~ ~OVERRIDE~
	SAY 0x794 @365

COPY_EXISTING ~AR3100.ARE~ ~OVERRIDE~
	READ_LONG 0x54 ~actoroffset~
	READ_SHORT 0x58 ~actornum~
	SET ~numsofar~=0
	WHILE (~%numsofar%~<~%actornum%~) BEGIN
		READ_ASCII (~%numsofar%~*0x110 + ~%actoroffset%~+0x80) ~crename~
		PATCH_IF !(~%crename%~ STRING_COMPARE_CASE ~DRIZZT~) THEN BEGIN
			WRITE_ASCII (~%numsofar%~*0x110 + ~%actoroffset%~+0x80) ~F_DRIZZT~ #8
			WRITE_SHORT (~%numsofar%~*0x110 + ~%actoroffset%~+0x20) 2737
			WRITE_SHORT (~%numsofar%~*0x110 + ~%actoroffset%~+0x22) 1998
			WRITE_SHORT (~%numsofar%~*0x110 + ~%actoroffset%~+0x24) 2737
			WRITE_SHORT (~%numsofar%~*0x110 + ~%actoroffset%~+0x26) 1998
			SET numsofar = "%actornum%"
		END
		SET ~numsofar~=~%numsofar%~+1
	END	
BUT_ONLY_IF_IT_CHANGES

COPY ~DRIZZTSAGA/ARE/F_6661.ARE~ ~OVERRIDE~
	SAY 0x234 @101
	SAY 0x238 @101

COPY ~DRIZZTSAGA/ARE/F_6664.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_6666.ARE~ ~OVERRIDE~
	// Embedded CREs:
	// Actor 1
	SAY 0x922 @43
	SAY 0x926 @43
	SAY 0x9be @1371
	SAY 0x9e2 @1372
	SAY 0xa06 @1373
	SAY 0xa0a @1374
	SAY 0xa26 @1375
	SAY 0xad2 @1375
	WRITE_ASCIIT 0xb9a ~F_DEATHK~
	WRITE_ASCII 0xd9a ~F_SW2H08~ #8
	// Actor 2
	SAY 0xdb6 @46
	SAY 0xdba @46
	SAY 0xe76 @1419
	SAY 0xe7a @1420
	SAY 0xe7e @1421
	SAY 0xe82 @1422
	SAY 0xe9a @1420
	SAY 0xe9e @1423
	SAY 0xeba @1419
	SAY 0xebe @1420
	SAY 0xec2 @1421
	SAY 0xec6 @1422
	// Actor 3
	SAY 0x123a @46
	SAY 0x123e @46
	SAY 0x12fa @1419
	SAY 0x12fe @1420
	SAY 0x1302 @1421
	SAY 0x1306 @1422
	SAY 0x131e @1420
	SAY 0x1322 @1423
	SAY 0x133e @1419
	SAY 0x1342 @1420
	SAY 0x1346 @1421
	SAY 0x134a @1422
	// Actor 4
	SAY 0x16be @42
	SAY 0x16c2 @42
	SAY 0x175a @1371
	SAY 0x177e @1372
	SAY 0x17a2 @1373
	SAY 0x17a6 @1374
	SAY 0x17c2 @1375
	SAY 0x186e @1375
	WRITE_LONG 0x16de 0x2300	// DEATH_KNIGHT
	WRITE_ASCII 0x1b4a ~BGSW2H07~ #8
	// Actor 5
	SAY 0x1b66 @44
	SAY 0x1b6a @44
	SAY 0x1c02 @400
	SAY 0x1c06 @401
	SAY 0x1c26 @402
	SAY 0x1c3a @1403
	SAY 0x1c3e @1404
	SAY 0x1c4a @405
	SAY 0x1c4e @406
	SAY 0x1c6a @407
	SAY 0x1c6e @408
	SAY 0x1c72 @409
	// Actor 6
	SAY 0x2006 @43
	SAY 0x200a @43	
	SAY 0x20a2 @1371	
	SAY 0x20c6 @1372	
	SAY 0x20ea @1373
	SAY 0x20ee @1374	
	SAY 0x210a @1375	
	SAY 0x21b6 @1375
	WRITE_ASCIIT 0x227e ~F_DEATHK~
	WRITE_ASCII 0x247e ~F_SW2H08~ #8
	// Actor 7
	SAY 0x249a @43
	SAY 0x249e @43	
	SAY 0x2536 @1371
	SAY 0x255a @1372	
	SAY 0x257e @1373	
	SAY 0x2582 @1374		
	SAY 0x259e @1375		
	SAY 0x264a @1375		
	WRITE_ASCIIT 0x2712 ~F_DEATHK~
	WRITE_ASCII 0x2912 ~F_SW2H08~ #8
	// Actor 8
	SAY 0x292e @16
	SAY 0x2932 @16
    SAY 0x29ca ~~ [F_BEL01]
    SAY 0x29ee ~~ [F_BEL01]
    SAY 0x2a02 ~~ [F_BEL03]
    SAY 0x2a06 ~~ [F_BEL04]
    SAY 0x2a12 ~~ [F_BEL08]
    SAY 0x2a16 ~~ [F_BEL09]
    WRITE_LONG 0x294e 0xE0D0		// IC_UMBERHULK
    // Actor 9
    SAY 0x2dce @43
    SAY 0x2dd2 @43
	SAY 0x2e6a @1371	
	SAY 0x2e8e @1372	
	SAY 0x2eb2 @1373
	SAY 0x2eb6 @1374	
	SAY 0x2ed2 @1375	
	SAY 0x2f7e @1375	
	WRITE_ASCIIT 0x3046 ~F_DEATHK~
	WRITE_ASCII 0x3246 ~F_SW2H08~ #8
	// Actor 10
    SAY 0x3262 @43
    SAY 0x3266 @43    
	SAY 0x32fe @1371	
	SAY 0x3322 @1372	
	SAY 0x3346 @1373
	SAY 0x334a @1374	
	SAY 0x3366 @1375	
	SAY 0x3412 @1375	
	WRITE_ASCIIT 0x34da ~F_DEATHK~
	WRITE_ASCII 0x36da ~F_SW2H08~ #8
	// Actor 11
	SAY 0x36f6 @42
	SAY 0x36fa @42	
	SAY 0x3792 @1371
	SAY 0x37b6 @1372
	SAY 0x37da @1373
	SAY 0x37de @1374
	SAY 0x37fa @1375
	SAY 0x38a6 @1375
	WRITE_LONG 0x3716 0x2300	// DEATH_KNIGHT
	WRITE_ASCII 0x3b82 ~BGSW2H07~ #8
	// Actor 12
	SAY 0x3b9e @99
	SAY 0x3ba2 @99
    SAY 0x3c3a @1446
    SAY 0x3c3e @1447
    SAY 0x3c5e @1448
    SAY 0x3c62 @1449
    SAY 0x3c66 @1446
    SAY 0x3c82 @1450
    SAY 0x3c86 @1451
    SAY 0x3ca2 @1449
    SAY 0x3d4e @1448
	// Actor 13
	SAY 0x405a @99
	SAY 0x405e @99	
    SAY 0x40f6 @1446
    SAY 0x40fa @1447    
    SAY 0x411a @1448
    SAY 0x411e @1449    
    SAY 0x4122 @1446    
    SAY 0x413e @1450    
    SAY 0x4142 @1451    
    SAY 0x415e @1449    
    SAY 0x420a @1448
	// Actor 14
    SAY 0x4516 @43
    SAY 0x451a @43    
	SAY 0x45b2 @1371	
	SAY 0x45d6 @1372		
	SAY 0x45fa @1373
	SAY 0x45fe @1374	
	SAY 0x461a @1375	
	SAY 0x46c6 @1375	
	WRITE_ASCIIT 0x478e ~F_DEATHK~
	
COPY ~DRIZZTSAGA/ARE/F_6667.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_6668.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_7777.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_7778.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_7779.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_8888.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_8889.ARE~ ~OVERRIDE~
	
COPY ~DRIZZTSAGA/ARE/F_9191.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_9292.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x4cc ~BGSKELWA~ #8
	WRITE_ASCII 0x5dc ~BGSKELWA~ #8
	WRITE_ASCII 0x6ec ~BGSKELWA~ #8

COPY ~DRIZZTSAGA/ARE/F_9393.ARE~ ~OVERRIDE~
	
COPY ~DRIZZTSAGA/ARE/F_9494.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_9595.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_9696.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_9797.ARE~ ~OVERRIDE~

COPY ~DRIZZTSAGA/ARE/F_9898.ARE~ ~OVERRIDE~
	WRITE_ASCII 0x19c ~BGSKELWA~ #8
	WRITE_ASCII 0x2ac ~BGSKELWA~ #8
	WRITE_ASCII 0x3bc ~BGSKELWA~ #8
	WRITE_ASCII 0x4cc ~BGSKELWA~ #8
	WRITE_ASCII 0x5dc ~BGSKELWA~ #8
	WRITE_ASCII 0x6ec ~BGSKELWA~ #8
	WRITE_ASCII 0x7fc ~BGSKELWA~ #8
	WRITE_ASCII 0x90c ~BGSKELWA~ #8
	WRITE_ASCII 0x112c ~BGSKELWA~ #8
	WRITE_ASCII 0x1134 ~BGSKELWA~ #8
	WRITE_ASCII 0x113c ~BGSKELWA~ #8
	WRITE_ASCII 0x1144 ~BGSKELWA~ #8
	WRITE_ASCII 0x114c ~BGSKELWA~ #8

COPY ~DRIZZTSAGA/ARE/F_9999.ARE~ ~OVERRIDE~

// Add Medusas into the game, part 1
COPY_EXISTING ~AR6560.ARE~ ~OVERRIDE~
	READ_LONG 0x54 ~actoroffset~
	READ_SHORT 0x58 ~actornum~
	SET ~numsofar~=0
	WHILE (~%numsofar%~<~%actornum%~) BEGIN
		READ_ASCII (~%numsofar%~*0x110 + ~%actoroffset%~+0x80) ~crename~
		PATCH_IF !(~%crename%~ STRING_COMPARE_CASE ~BASILG~) THEN BEGIN
			WRITE_ASCII (~%numsofar%~*0x110 + ~%actoroffset%~+0x80) ~F_MEDUSA~ #8
		END
		SET ~numsofar~=~%numsofar%~+1
	END	
BUT_ONLY_IF_IT_CHANGES

// Scripts:	
	
PRINT @367

COMPILE	~DRIZZTSAGA/BAF/BGT~

COPY_EXISTING ~TANARI.BCS~ ~override~
	REPLACE_BCS_BLOCK ~DRIZZTSAGA/SNIP/oTANARI.BAF~ ~DRIZZTSAGA/SNIP/nTANARI.BAF~
BUT_ONLY_IF_IT_CHANGES

COPY_EXISTING ~ARAM00.BCS~ ~override~
	REPLACE_BCS_BLOCK ~DRIZZTSAGA/SNIP/oARAM00.BAF~ ~DRIZZTSAGA/SNIP/nARAM00.BAF~
BUT_ONLY_IF_IT_CHANGES

EXTEND_TOP ~AR7223.BCS~ ~DRIZZTSAGA/SNIP/eAR0123.BAF~
EXTEND_TOP ~ARU000.BCS~ ~DRIZZTSAGA/SNIP/eARU000.BAF~
EXTEND_TOP ~ARU001.BCS~ ~DRIZZTSAGA/SNIP/eARU001.BAF~
EXTEND_TOP ~ARD000.BCS~ ~DRIZZTSAGA/SNIP/eARD000.BAF~


// Add Medusas into the game, part 2
EXTEND_TOP ~AR9400.BCS~ ~DRIZZTSAGA/SNIP/eAR9400.BAF~

// Update gnolls script to use new drizzt DV:
COPY_EXISTING ~GNOLLDR.BCS~ ~override~
  DECOMPILE_BCS_TO_BAF
	REPLACE_TEXTUALLY ~"Drizzt"~ ~"F_DRIZZT"~
  COMPILE_BAF_TO_BCS
BUT_ONLY_IF_IT_CHANGES

// Dialogues:

COMPILE ~DRIZZTSAGA/DLG/BGT~
		
//Misc:

COPY ~DRIZZTSAGA/misc/F_NIBSHP.Sto~         ~override~
  SAY 0x0c @1

// Creatures:

PRINT @360

COPY ~DRIZZTSAGA/Creatures/F_ARTEMI.CRE~ ~override~
  SAY NAME1 @2
  SAY NAME2 @2
  SAY INITIAL_MEETING @3
  SAY MORALE @4
  SAY LEADER @3
  SAY TIRED @5
  SAY BORED @6
  SAY BATTLE_CRY1 @3
  SAY BATTLE_CRY2 @5
  SAY BATTLE_CRY3 @7
  SAY BATTLE_CRY4 @8
  SAY DAMAGE @1009
  SAY DYING @1010
  SAY SELECT_COMMON1 @3
  SAY SELECT_COMMON2 @5
  SAY SELECT_COMMON3 @6
  SAY BIO @11

COPY ~DRIZZTSAGA/Creatures/F_BEARFM.cre~ ~override~
  SAY NAME1 @12
  SAY NAME2 @12
  SAY INITIAL_MEETING @1377
  SAY DAMAGE @1378
  SAY DYING @1379
  SAY SELECT_COMMON1 @1380
  WRITE_ASCII 0x268 ~WTASIGHT~ #8

COPY ~DRIZZTSAGA/Creatures/F_BEAROL.cre~ ~override~
  SAY NAME1 @13
  SAY NAME2 @13
  SAY INITIAL_MEETING @1381
  SAY DAMAGE @1382
  SAY DYING @1383
  SAY SELECT_COMMON1 @1384
  
COPY ~DRIZZTSAGA/Creatures/F_BEARSU.CRE~ ~override~
  SAY NAME1 @14
  SAY NAME2 @14
  SAY BATTLE_CRY1 @1385
  SAY 0xcc @1386
  SAY 0xdc @1387
  SAY 0xe0 @1388
  SAY 0xec @1389
  SAY 0xf0 @1390
  SAY 0x10c @1391
  SAY 0x110 @1392
  
COPY ~DRIZZTSAGA/Creatures/F_BEARW2.cre~ ~override~
	 ~DRIZZTSAGA/Creatures/F_BEARW1.cre~ ~override~
  SAY NAME1 @15
  SAY NAME2 @15
  SAY INITIAL_MEETING @393
  SAY BATTLE_CRY1 @393
  SAY 0xec @394
  SAY 0xf0 @395
  SAY 0x1a0 @393
  SAY 0x1a4 @396
  SAY 0x1a8 @397
  SAY 0x1ac @398
  
COPY ~DRIZZTSAGA/Creatures/F_BRUENO.CRE~ ~override~
  SAY NAME1 @22
  SAY NAME2 @22
  SAY INITIAL_MEETING @1023
  SAY TIRED @1023
  SAY BORED @1023
  SAY BATTLE_CRY1 @1024
  SAY DAMAGE @1025
  SAY DYING @1026
  SAY SELECT_COMMON1 @1023
  SAY SELECT_COMMON2 @1024
  SAY BIO @27
  
COPY ~DRIZZTSAGA/Creatures/F_CATTIB.CRE~ ~override~
  SAY NAME1 @28
  SAY NAME2 @28
  SAY INITIAL_MEETING @1029
  SAY BATTLE_CRY1 @1030
  SAY DAMAGE @1031
  SAY DYING @1032
  SAY SELECT_COMMON1 @1033
  SAY SELECT_COMMON2 @1029
  SAY DIALOG_HOSTILE @34
  SAY BIO @35

COPY ~DRIZZTSAGA/Creatures/F_DEADM2.CRE~ ~override~
  SAY NAME1 @40
  SAY NAME2 @40
  SAY INITIAL_MEETING @1376
  SAY DYING @1399

COPY ~DRIZZTSAGA/Creatures/F_deathl.CRE~ ~override~
  SAY NAME1 @43
  SAY NAME2 @43
  SAY INITIAL_MEETING @1371
  SAY BATTLE_CRY1 @1372
  SAY DAMAGE @1373
  SAY DYING @1374
  SAY SELECT_COMMON1 @1375  
  SAY PICKED_POCKET @1375
  WRITE_ASCIIT 0x280 ~F_DEATHK~

COPY ~DRIZZTSAGA/Creatures/F_DEMDRG.CRE~ ~override~
  SAY NAME1 @44
  SAY NAME2 @44
  SAY INITIAL_MEETING @400
  SAY 0xa8 @401
  SAY 0xc8 @402
  SAY 0xdc @1403
  SAY 0xe0 @1404
  SAY 0xec @405
  SAY 0xf0 @406
  SAY 0x10c @407
  SAY 0x110 @408
  SAY 0x114 @409
  SAY 0x1b8 @407

COPY ~DRIZZTSAGA/Creatures/F_DEMSPI.CRE~ ~override~
  SAY NAME1 @45
  SAY NAME2 @45
  SAY BATTLE_CRY1 @410
  SAY 0xcc @411
  SAY 0xdc @412
  SAY 0xe0 @413
  SAY 0xec @414
  SAY 0xf0 @415
  SAY 0x10c @416
  SAY 0x110 @417
  SAY 0x1b8 @418

COPY ~DRIZZTSAGA/Creatures/F_DEMWAR.CRE~ ~override~
  SAY NAME1 @46
  SAY NAME2 @46
  SAY 0xc8 @1419
  SAY 0xcc @1420
  SAY 0xd0 @1421
  SAY 0xd4 @1422
  SAY 0xec @1420
  SAY 0xf0 @1423
  SAY 0x10c @1419
  SAY 0x110 @1420
  SAY 0x114 @1421
  SAY 0x118 @1422
  
COPY ~DRIZZTSAGA/Creatures/F_DIPNOS.cre~ ~override~
  SAY NAME1 @47
  SAY NAME2 @47
  SAY INITIAL_MEETING @1095
  SAY DAMAGE @1091
  SAY DYING @1092
  SAY 0x10c @1095

COPY ~DRIZZTSAGA/Creatures/F_DRAGON.CRE~ ~override~
  SAY NAME1 @48
  SAY NAME2 @48
  SAY 0xc8 @1427
  SAY 0xcc @1428
  SAY 0xdc @1429
  SAY 0xe0 @1430
  SAY 0xe4 @1431
  SAY 0xec @1432
  SAY 0xf0 @1433
  SAY 0x10c @1434
  SAY 0x110 @1435
  SAY 0x1b8 @1436

COPY ~DRIZZTSAGA/Creatures/F_DRIZZT.CRE~ ~override~
  SAY NAME1 @49
  SAY NAME2 @49
  SAY INITIAL_MEETING @1050
  SAY UNHAPPY_BREAKING_POINT  @1051
  SAY BORED @1050
  SAY BATTLE_CRY1 @1052
  SAY BATTLE_CRY2 @1053
  SAY BATTLE_CRY3 @1054
  SAY DAMAGE @1055
  SAY DYING @1056
  SAY SELECT_COMMON1 @1057
  SAY SELECT_COMMON2 @1058
  SAY SELECT_COMMON3 @1053
  SAY SELECT_COMMON4 @1054
  SAY DIALOG_HOSTILE @59
  SAY BIO @60
  WRITE_ASCII 0x2cc ~DRIZZT~ #8

COPY ~DRIZZTSAGA/Creatures/F_DROMAG.CRE~ ~override~
  SAY NAME1 @61
  SAY NAME2 @61
  SAY INITIAL_MEETING @76
  SAY TIRED @77
  SAY BORED @77
  SAY BATTLE_CRY1 @78
  SAY AREA_CITY @77
  SAY DAMAGE ~~ [F_DRSL16]
  SAY DYING ~~ [F_DRSL15]
  SAY SELECT_COMMON3 @77 
  SAY SELECT_COMMON2 @82 
  SAY SELECT_COMMON1 @17

COPY ~DRIZZTSAGA/Creatures/F_DROWAR.CRE~ ~override~
  SAY NAME1 @62
  SAY NAME2 @62
  SAY BATTLE_CRY1 @78
  SAY DAMAGE ~~ [F_DRSL16]
  SAY DYING ~~ [F_DRSL15]
  SAY TIRED @77 
  SAY BORED @77 
  SAY AREA_CITY @77 
  SAY SELECT_COMMON3 @77 
  SAY SELECT_COMMON2 @82 
  SAY SELECT_COMMON1 @17 
  SAY INITIAL_MEETING @18 

COPY ~DRIZZTSAGA/Creatures/F_DROWPR.CRE~ ~override~
  SAY NAME1 @63
  SAY NAME2 @63
  SAY BATTLE_CRY1 @19 
  SAY DAMAGE @1424
  SAY DYING @1425

COPY ~DRIZZTSAGA/Creatures/F_DRSCUL.CRE~ ~override~
  SAY NAME1 @64
  SAY NAME2 @64
  SAY 0xc8 @402
  SAY 0xec @405
  SAY 0xf0 @406

COPY ~DRIZZTSAGA/Creatures/F_DWSMIT.CRE~ ~override~
  SAY NAME1 @65
  SAY NAME2 @65
  SAY INITIAL_MEETING @1023
  SAY TIRED @1023
  SAY BORED @1023
  SAY BATTLE_CRY1 @1024

COPY ~DRIZZTSAGA/Creatures/F_ELMINS.CRE~ ~override~
  SAY NAME1 @66
  SAY NAME2 @66
  SAY INITIAL_MEETING @1341
  SAY UNHAPPY_BREAKING_POINT @1342
  SAY BATTLE_CRY1 @1343
  SAY DAMAGE @1344
  SAY DYING @1345
  SAY SELECT_COMMON1 @1346
  SAY SELECT_COMMON2 @1347
  SAY SELECT_COMMON3 @1348
  SAY SELECT_ACTION4 @1349

COPY ~DRIZZTSAGA/Creatures/F_ERRTU.CRE~ ~override~
  SAY NAME1 @67
  SAY NAME2 @67
  SAY INITIAL_MEETING @400
  SAY 0xa8 @401
  SAY 0xc8 @402
  SAY 0xdc @1403
  SAY 0xe0 @1404
  SAY 0xec @405
  SAY 0xf0 @406
  SAY 0x10c @407
  SAY 0x110 @408
  SAY 0x114 @409
  SAY 0x1b8 @407

COPY ~DRIZZTSAGA/Creatures/F_GHOST.CRE~ ~override~
  SAY NAME1 @69
  SAY NAME2 @69
  SAY 0xc8 @1437
  SAY 0xcc @1438
  SAY 0xdc @1437
  SAY 0xec @1439
  SAY 0xf0 @1440
  SAY 0x10c @1441
  SAY 0x110 @1437

COPY ~DRIZZTSAGA/Creatures/F_JARLAX.cre~ ~override~
  SAY NAME1 @75
  SAY NAME2 @75
  SAY INITIAL_MEETING @76
  SAY TIRED @77
  SAY BORED @77
  SAY BATTLE_CRY1 @78
  SAY DAMAGE @79
  SAY DYING @80
  SAY AREA_CITY @77
  SAY SELECT_COMMON1 @81
  SAY SELECT_COMMON2 @82
  SAY SELECT_COMMON3 @77
  SAY BIO @83

COPY ~DRIZZTSAGA/Creatures/F_REGIS2.CRE~ ~override~
	 ~DRIZZTSAGA/Creatures/F_REGIS.CRE~ ~override~
  SAY NAME1 @89
  SAY NAME2 @89
  SAY INITIAL_MEETING @1090
  SAY DAMAGE @1091
  SAY DYING @1092
  SAY SELECT_COMMON1 @1093
  SAY SELECT_COMMON2 @1094
  SAY SELECT_COMMON3 @1095
  SAY BIO @96

COPY ~DRIZZTSAGA/Creatures/F_ROBED2.CRE~ ~override~
  SAY NAME1 @97
  SAY NAME2 @97
  SAY INITIAL_MEETING @351
  SAY BATTLE_CRY1 @352
  SAY DAMAGE ~~ [F_IREN05]
  SAY DYING ~~ [F_IREN06]

COPY ~DRIZZTSAGA/Creatures/F_ROBED.CRE~ ~override~
  SAY NAME1 @97
  SAY NAME2 @97
  SAY INITIAL_MEETING @1443
  SAY 0xec @1444
  SAY 0xf0 @1445
  SAY 0x10c @1443
  
COPY ~DRIZZTSAGA/Creatures/F_SLAYSH.cre~ ~override~
  SAY NAME1 @99
  SAY NAME2 @99
  SAY INITIAL_MEETING @1446
  SAY 0xa8 @1447
  SAY 0xc8 @1448
  SAY 0xcc @1449
  SAY 0xd0 @1446
  SAY 0xec @1450
  SAY 0xf0 @1451
  SAY 0x10c @1449
  SAY 0x1bc @1448

COPY ~DRIZZTSAGA/Creatures/F_SPIBEA.CRE~ ~override~
  SAY NAME1 @14
  SAY NAME2 @14
  SAY 0xc8 @1385
  SAY 0xcc @1386
  SAY 0xdc @1387
  SAY 0xe0 @1388
  SAY 0xec @1389
  SAY 0xf0 @1390
  SAY 0x10c @1391
  SAY 0x110 @1392

COPY ~DRIZZTSAGA/Creatures/F_SPIDQU.CRE~ ~override~
  SAY NAME1 @100
  SAY NAME2 @100
  SAY INITIAL_MEETING @1452
  SAY 0xc8 @1453
  SAY 0xec @1454
  SAY 0xf0 @1455
  SAY 0x10c @1453
  SAY 0x110 @1452

COPY ~DRIZZTSAGA/Creatures/F_SUMSPI.CRE~ ~override~
  SAY NAME1 @102
  SAY NAME2 @102
  SAY 0xc8 @1410
  SAY 0xcc @1411
  SAY 0xdc @1412
  SAY 0xe0 @1413
  SAY 0xec @1414
  SAY 0xf0 @1415
  SAY 0x10c @1416
  SAY 0x110 @1417

COPY ~DRIZZTSAGA/Creatures/F_TANARI.CRE~ ~override~
	 ~DRIZZTSAGA/Creatures/F_TANSUM.CRE~ ~override~
  SAY NAME1 @103
  SAY NAME2 @103
  SAY INITIAL_MEETING @400
  SAY 0xa8 @401
  SAY 0xc8 @402
  SAY 0xdc @1403
  SAY 0xe0 @1404
  SAY 0xec @405
  SAY 0xf0 @406
  SAY 0x10c @407
  SAY 0x110 @408
  SAY 0x114 @409
  SAY 0x1b8 @407

COPY ~DRIZZTSAGA/Creatures/F_WERECH.CRE~ ~override~
  SAY NAME1 @107
  SAY NAME2 @107
  SAY INITIAL_MEETING @1456
  SAY 0xc8 @1457
  SAY 0xcc @1458
  SAY 0xec @1459
  SAY 0xf0 @1460
  SAY 0x10c @1458
  SAY 0x1b8 @1458
  WRITE_ASCII 0x3e4 ~IMMUNE2~ #8
  
COPY ~DRIZZTSAGA/Creatures/F_WLFSPR.cre~ ~override~
  SAY NAME1 @108
  SAY NAME2 @108
  SAY 0xc8 @1461
  SAY 0xcc @1462
  SAY 0xdc @1463
  SAY 0xe0 @1464
  SAY 0xec @1465
  SAY 0xf0 @1466
  SAY 0x10c @1467
  SAY 0x110 @1468
  
COPY ~DRIZZTSAGA/Creatures/F_WULFGA.CRE~ ~override~
  SAY NAME1 @109
  SAY NAME2 @109
  SAY INITIAL_MEETING @1110
  SAY UNHAPPY_BREAKING_POINT @1111
  SAY BATTLE_CRY1 @1112
  SAY BATTLE_CRY2 @1113
  SAY BATTLE_CRY3 @1114
  SAY DAMAGE @1115
  SAY DYING @1116
  SAY SELECT_COMMON1 @1110
  SAY SELECT_COMMON2 @1117
  SAY SELECT_COMMON3 @1114
  SAY SELECT_COMMON4 @1113
  SAY DIALOG_HOSTILE @118
  SAY BIO @119

COPY ~DRIZZTSAGA/Creatures/F_DEATHK.CRE~ ~override~	
  SAY NAME1 @42
  SAY NAME2 @42
  SAY INITIAL_MEETING @1371
  SAY BATTLE_CRY1 @1372
  SAY DAMAGE @1373
  SAY DYING @1374
  SAY SELECT_COMMON1 @1375  
  SAY PICKED_POCKET @1375
  WRITE_LONG 0x28 0x2300	// DEATH_KNIGHT
  WRITE_ASCII 0x444 ~BGSW2H07~ #8

COPY ~DRIZZTSAGA/Creatures/F_ETTIN.cre~ ~override~
  SAY NAME1 @68
  SAY NAME2 @68
  SAY INITIAL_MEETING ~~ [ETTIN01]
  SAY BATTLE_CRY1 ~~ [ETTIN03A]
  SAY ATTACK1 ~~ [ETTIN04A]
  SAY DAMAGE ~~ [ETTIN08]
  SAY DYING ~~ [ETTIN09A]
  WRITE_LONG 0x28 0xE010		// IC_ETTIN

COPY ~DRIZZTSAGA/Creatures/F_GIANTF.cre~ ~override~
  SAY NAME1 @70
  SAY NAME2 @70
  SAY INITIAL_MEETING ~~ [F_GIANT1]
  SAY BATTLE_CRY1 ~~ [F_GIANT1]
  SAY DAMAGE ~~ [F_GIANT4]
  SAY DYING ~~ [F_GIANT5]
  WRITE_LONG 0x28 0xE710		// IC_OROG2

COPY ~DRIZZTSAGA/Creatures/F_CORN.CRE~ ~override~
	 ~DRIZZTSAGA/Creatures/F_CORN02.CRE~ ~override~
  SAY NAME1 @36
  SAY NAME2 @36
  SAY INITIAL_MEETING ~~ [F_CORN01]
  SAY BATTLE_CRY1 ~~ [F_CORN02]
  SAY ATTACK1 ~~ [F_CORN03]
  SAY ATTACK2 ~~ [F_CORN04]
  SAY DAMAGE ~~ [F_CORN08]
  SAY DYING ~~ [F_CORN09]
  SAY SELECT_COMMON1 ~~ [F_CORN01]
  WRITE_LONG 0x28 0xE0E0		// IC_CORNUGONSKI

COPY ~DRIZZTSAGA/Creatures/F_orc.cre~ ~override~
  SAY NAME1 @88
  SAY NAME2 @88
  SAY INITIAL_MEETING ~~ [F_ORC01]
  SAY BATTLE_CRY1 ~~ [F_ORC02]
  SAY ATTACK1 ~~ [F_ORC03]
  SAY  ATTACK2 ~~ [F_ORC04]
  SAY DAMAGE ~~ [F_ORC08]
  SAY DYING ~~ [F_ORC09]
  WRITE_LONG 0x28 0xE800		// IC_ORC_MELEE1
	
COPY ~DRIZZTSAGA/Creatures/F_BEL.CRE~ ~override~
  SAY NAME1 @16
  SAY NAME2 @16
  SAY INITIAL_MEETING ~~ [F_BEL01]
  SAY BATTLE_CRY1 ~~ [F_BEL01]
  SAY ATTACK1 ~~ [F_BEL03]
  SAY ATTACK2 ~~ [F_BEL04]
  SAY DAMAGE ~~ [F_BEL08]
  SAY DYING ~~ [F_BEL09]
  WRITE_LONG 0x28 0xE0D0		// IC_UMBERHULK

COPY ~DRIZZTSAGA/Creatures/F_CYCLOP.cre~ ~override~
  SAY NAME1 @37
  SAY NAME2 @37
  SAY INITIAL_MEETING ~~ [F_CYCLO1]
  SAY BATTLE_CRY1 ~~ [F_CYCLO5]
  SAY ATTACK1 ~~ [F_CYCLO3]
  SAY ATTACK2 ~~ [F_CYCLO4]
  SAY DAMAGE ~~ [F_CYCLO8]
  SAY DYING ~~ [F_CYCLO9]
  SAY SELECT_COMMON1 ~~ [F_CYCLO1]
  WRITE_LONG 0x28 0xE000   //IC_CYCLOP
	
COPY ~DRIZZTSAGA/Creatures/F_MARI.cre~ ~override~
  SAY NAME1 @85
  SAY NAME2 @85
  SAY INITIAL_MEETING ~~ [F_MARB01]
  SAY MORALE ~~ [F_MARB04]
  SAY BATTLE_CRY1 ~~ [F_MARB01]
  SAY BATTLE_CRY2 ~~ [F_MARB02]
  SAY BATTLE_CRY3 ~~ [F_MARB03]
  SAY ATTACK1 ~~ [F_MARAT1]
  SAY ATTACK2 ~~ [F_MARAT2]
  SAY ATTACK3 ~~ [F_MARAT4]
  SAY DAMAGE ~~ [F_MARAT6]
  SAY DYING ~~ [F_MARAT7]
  WRITE_LONG 0x28 0xE090   //IC_MERILITH
	
COPY ~DRIZZTSAGA/Creatures/F_GUEN.CRE~ ~override~
  SAY NAME1 @73
  SAY NAME2 @73
  SAY INITIAL_MEETING ~~ [F_PANTH1]
  SAY BATTLE_CRY1 ~~ [F_PANTH1]
  SAY BATTLE_CRY2 ~~ [F_PANTH2]
  SAY ATTACK1 ~~ [F_PANTH3]
  SAY ATTACK2 ~~ [F_PANTH4]
  SAY ATTACK3 ~~ [F_PANTH5]
  SAY DAMAGE ~~ [F_PANTH6]
  SAY DYING ~~ [F_PANTH7]
  SAY SELECT_COMMON1 ~~ [F_PANTH1]
  WRITE_LONG 0x28 0x7F0A   //GREATCAT_PANTHER
	
COPY ~DRIZZTSAGA/Creatures/F_HARPY.CRE~ ~override~
  SAY NAME1 @74
  SAY NAME2 @74
  SAY INITIAL_MEETING ~~ [F_HARPY1]
  SAY BATTLE_CRY1 ~~ [F_HARPY3]
  SAY BATTLE_CRY2 ~~ [F_HARPY1]
  SAY ATTACK1 ~~ [F_HARPY4]
  SAY ATTACK2 ~~ [F_HARPY6]
  SAY DAMAGE ~~ [F_HARPY8]
  SAY DYING ~~ [F_HARPY9]
  SAY SELECT_COMMON1 ~~ [F_HARPY1]
  WRITE_LONG 0x28 0xE0A0   //IC_ICE_TROLL

COPY ~DRIZZTSAGA/Creatures/F_GOBELE.CRE~ ~override~
  SAY NAME1 @71
  SAY NAME2 @71
  SAY INITIAL_MEETING ~~ [F_GOB01]
  SAY BATTLE_CRY1 ~~ [F_GOB11]
  SAY BATTLE_CRY2 ~~ [F_GOB02]
  SAY ATTACK1 ~~ [F_GOB03]
  SAY ATTACK2 ~~ [F_GOB04]
  SAY DAMAGE ~~ [F_GOB08]
  SAY DYING ~~ [F_GOB09]
  SAY SELECT_COMMON1 ~~ [F_GOB10]
  WRITE_LONG 0x28 0xE400	// IC_GOBLIN_AXE

COPY ~DRIZZTSAGA/Creatures/F_GOBLIN.CRE~ ~override~
  SAY NAME1 @72
  SAY NAME2 @72
  SAY INITIAL_MEETING ~~ [F_GOB01]
  SAY BATTLE_CRY1 ~~ [F_GOB11]
  SAY BATTLE_CRY2 ~~ [F_GOB02]
  SAY ATTACK1 ~~ [F_GOB03]
  SAY ATTACK2 ~~ [F_GOB04]
  SAY DAMAGE ~~ [F_GOB08]
  SAY DYING ~~ [F_GOB09]
  SAY SELECT_COMMON1 ~~ [F_GOB10]
  WRITE_LONG 0x28 0xE400	// IC_GOBLIN_AXE

COPY ~DRIZZTSAGA/Creatures/F_LICH.cre~ ~override~
  SAY NAME1 @84
  SAY NAME2 @84
  SAY 0xc8 @1438
  SAY 0xcc @1470
  SAY 0xf0 @1439
  WRITE_LONG 0x28 0x7F0D	// LICH
	
COPY ~DRIZZTSAGA/Creatures/F_MUMMY.CRE~ ~override~
  SAY NAME1 @86
  SAY NAME2 @86
  SAY 0xc8 @1471
  SAY 0xcc @1472
  SAY 0xdc @1473
  SAY 0xe0 @1474
  SAY 0xf0 @1439
  SAY 0x10c @1475
  SAY 0x110 @1476
  WRITE_LONG 0x28 0xE080	// IC_MUMMY

COPY ~DRIZZTSAGA/Creatures/F_SHFIEN.CRE~ ~override~
  SAY NAME1 @98
  SAY NAME2 @98
  SAY 0xc8 @1438
  SAY 0xdc @1438
  SAY 0xf0 @1440
  WRITE_LONG 0x28 0x7703	// SHADOW
	
COPY ~DRIZZTSAGA/Creatures/F_VALEN.CRE~ ~override~
  SAY NAME1 @104
  SAY NAME2 @104
  SAY BATTLE_CRY1 @20
  SAY BATTLE_CRY2 @21
  SAY DAMAGE ~~ [F_VMPFX7]
  SAY DYING ~~ [F_VMPFX8]
  WRITE_LONG 0x28 0x7F22	// VAMPIRE_FEMALE
	
COPY ~DRIZZTSAGA/Creatures/F_VAMPF.CRE~ ~override~
  SAY NAME1 @104
  SAY NAME2 @104
  SAY BATTLE_CRY1 @20
  SAY BATTLE_CRY2 @21
  SAY DAMAGE ~~ [F_VMPFX7]
  SAY DYING ~~ [F_VMPFX8]
  WRITE_LONG 0x28 0x7F22	// VAMPIRE_FEMALE	

COPY ~DRIZZTSAGA/Creatures/WEREWOGR.cre~         ~override~
  SAY NAME1 @131
  SAY NAME2 @131  
  SAY INITIAL_MEETING @1456
  SAY 0xc8 @1457
  SAY 0xcc @1458
  SAY 0xec @1459
  SAY 0xf0 @1460
  SAY 0x10c @1457
  SAY 0x110 @1458
  WRITE_LONG 0x28 0x7E01 //WEREWOLF_GREATER
  WRITE_ASCII 0x3e4 ~IMMUNE2~ #8
  
COPY ~DRIZZTSAGA/Creatures/WOLFWEGR.cre~         ~override~
  SAY NAME1 @132
  SAY NAME2 @132
  SAY INITIAL_MEETING @1456
  SAY 0xc8 @1457
  SAY 0xcc @1458
  SAY 0xec @1459
  SAY 0xf0 @1460
  SAY 0x10c @1457
  SAY 0x110 @1458
  WRITE_LONG 0x28 0x7E01 //WEREWOLF_GREATER

COPY_EXISTING ~DEATHK1.CRE~ ~override~
			  ~DEATHK.CRE~ ~override~
    REPLACE_CRE_ITEM ~F_DEATHS~ #0 #0 #0 ~UNDROPPABLE~ ~WEAPON1~ EQUIP
    ADD_CRE_ITEM ~BGSW2H07~ #0 #0 #0 ~NONE~ ~INV~
    PATCH_IF ("%SOURCE_RES%" STRING_EQUAL_CASE "DEATHK") BEGIN
    	REPLACE_CRE_ITEM ~HELM08~ #0 #0 #0 ~NONE~ ~HELMET~
    	REPLACE_CRE_ITEM ~PLAT05~ #0 #0 #0 ~NONE~ ~ARMOR~
    END
BUT_ONLY_IF_IT_CHANGES

COPY ~DRIZZTSAGA/Creatures/F_DEADBO.cre~ ~override~
  SAY NAME1 @38
  SAY NAME2 @38
  SAY INITIAL_MEETING @1376
	
COPY ~DRIZZTSAGA/Creatures/F_DEADMA.cre~ ~override~
  SAY NAME1 @40
  SAY NAME2 @40
  SAY INITIAL_MEETING @1376 

COPY ~DRIZZTSAGA/Creatures/F_DEADWM.cre~ ~override~
  SAY NAME1 @41
  SAY NAME2 @41
  SAY INITIAL_MEETING @1376

COPY ~DRIZZTSAGA/Creatures/F_NIB.cre~ ~override~
  SAY NAME1 @87
  SAY NAME2 @87
  SAY INITIAL_MEETING @350
  SAY SELECT_COMMON1 @350
  SAY 0xec @1091
  SAY 0xf0 @1092
  
COPY ~DRIZZTSAGA/Creatures/F_WAILIN.CRE~ ~override~
  SAY NAME1 @106
  SAY NAME2 @106
  SAY 0xc8 @1469
  SAY 0xdc @1469
  SAY DAMAGE ~~ [F_VMPFX7]
  SAY DYING ~~ [F_VMPFX8]

END	// BGT
END // Non-Tutu	
 
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////  


// Common things to do for all platforms

COPY ~DRIZZTSAGA/Creatures/F_DEADHR.cre~ ~override~
  SAY NAME1 @39
  SAY NAME2 @39
  
COPY ~DRIZZTSAGA/Creatures/F_STONGL.CRE~ ~override~
  SAY NAME1 @101
  SAY NAME2 @101  

COPY ~DRIZZTSAGA/Creatures/F_MEDUSA.cre~ ~override~
  SAY NAME1 @120
  SAY NAME2 @120
  SAY INITIAL_MEETING ~~ [F_MED03]
  SAY BATTLE_CRY1 ~~ [F_MED03]
  SAY ATTACK1 ~~ [TRA_04C]
  SAY ATTACK2 ~~ [F_MED04]
  SAY DAMAGE ~~ [F_MED06]
  SAY DYING ~~ [F_MED07]

  
PRINT @488

COPY_EXISTING ~BALDUR.GAM~ ~override~
	READ_LONG 0x20 "PC_offset"
	READ_LONG 0x28 "US_offset"
	READ_LONG 0x30 "NPC_offset"
	READ_LONG 0x38 "glob_offset"
	READ_LONG 0x50 "jrnl_offset"
	READ_LONG 0x34 "NPC_num"
	READ_LONG 0x68 "famil_offset"
	READ_LONG 0x6c "locat_offset"
	READ_LONG 0x78 "US2_offset"
	
	SET "idx" = 0
	WHILE ("%idx%" < "%GAM_count%") BEGIN
	  READ_2DA_ENTRY_FORMER ~#GAM_patch_table~ "idx" 1 "cre_name"
	  READ_2DA_ENTRY_FORMER ~#GAM_patch_table~ "idx" 2 "area_name"
	  READ_2DA_ENTRY_FORMER ~#GAM_patch_table~ "idx" 3 "loc_x"
	  READ_2DA_ENTRY_FORMER ~#GAM_patch_table~ "idx" 4 "loc_y"
	  
	  INSERT_BYTES "%NPC_offset%" 0x160
	  WRITE_EVALUATED_ASCII ("%NPC_offset%" + 0x0c) "%cre_name%" #8
	  WRITE_EVALUATED_ASCII ("%NPC_offset%" + 0x18) "%area_name%" #8
	  WRITE_SHORT ("%NPC_offset%" + 0x20) "%loc_x%"
	  WRITE_SHORT ("%NPC_offset%" + 0x22) "%loc_y%"
	  WRITE_SHORT ("%NPC_offset%" + 0x8c) 0xffff
	  WRITE_SHORT ("%NPC_offset%" + 0x8e) 0xffff
	  WRITE_SHORT ("%NPC_offset%" + 0x90) 0xffff
	  WRITE_SHORT ("%NPC_offset%" + 0x92) 0xffff
	  WRITE_SHORT ("%NPC_offset%" + 0xb4) 0xffff
	  WRITE_SHORT ("%NPC_offset%" + 0xb6) 0xffff
	  WRITE_SHORT ("%NPC_offset%" + 0xb8) 0xffff	  
	  SET "idx" = "%idx%" + 1
	END
	
	PATCH_IF ("%idx%" > 0) BEGIN	
	  SET "delta" = 0x160 * "%idx%"
	  SET "NPC_num" = "%NPC_num%" + "%idx%"
	  WRITE_LONG 0x34 "%NPC_num%"
	  
      PATCH_IF ("%PC_offset%">="%NPC_offset%") BEGIN
        "PC_offset"="%PC_offset%"+"%delta%"
        WRITE_LONG  0x20 "%PC_offset%"
      END
      PATCH_IF ("%US_offset%">="%NPC_offset%") BEGIN
        "US_offset"="%US_offset%"+"%delta%"
        WRITE_LONG  0x28  "%US_offset%"
      END
      PATCH_IF ("%glob_offset%">="%NPC_offset%") BEGIN
        "glob_offset"="%glob_offset%"+"%delta%"
        WRITE_LONG  0x38  "%glob_offset%"
      END
      PATCH_IF ("%jrnl_offset%">="%NPC_offset%") BEGIN
        "jrnl_offset"="%jrnl_offset%"+"%delta%"
        WRITE_LONG  0x50  "%jrnl_offset%"
      END
      PATCH_IF ("%famil_offset%">="%NPC_offset%") BEGIN
        "famil_offset"="%famil_offset%"+"%delta%"
        WRITE_LONG  0x68  "%famil_offset%"
      END
      PATCH_IF ("%locat_offset%">="%NPC_offset%") BEGIN
        "locat_offset"="%locat_offset%"+"%delta%"
        WRITE_LONG  0x6c  "%locat_offset%"
      END
      PATCH_IF ("%US2_offset%">="%NPC_offset%") BEGIN
        "US2_offset"="%US2_offset%"+"%delta%"
        WRITE_LONG  0x78  "%US2_offset%"
      END
	END
BUT_ONLY_IF_IT_CHANGES
  

PRINT @357

APPEND ~PDIALOG.2DA~
~F_JARLAXE    F_MULTIP            F_JARLAJ          ***            ***                ***                ***                 ***
F_ARTEMIS    F_MULTIP            F_ARTEMJ          ***            ***                ***                ***                 ***
F_CATTIBR    F_MULTIP            F_CATTIJ           ***            ***                ***                ***                 ***          
F_BRUENOR    F_MULTIP            F_BRUENJ          ***            ***                ***                ***                 ***
F_REGIS2     F_MULTIP            F_REGISJ          ***            ***                ***                ***                 ***
F_DRIZZT     F_MULTIP            F_DRIZTJ          ***            ***                ***                ***                 ***
F_WULFGAR    F_MULTIP            F_WULFGJ          ***            ***                ***                ***                 ***~
	UNLESS ~F_REGIS2~

APPEND ~INTERDIA.2DA~	// Placeholders for possible future expansions on NPC interaction
~F_JARLAXE       BF_JARLA      ***
F_CATTIBR       BF_CATTI      ***
F_ARTEMIS       BF_ARTEM      ***
F_BRUENOR       BF_BRUEN      ***
F_REGIS2        BF_REGIS      ***
F_DRIZZT        BF_DRIZT      ***
F_WULFGAR       BF_WULFG      ***~
	UNLESS ~F_REGIS2~
    
// Area data:

PRINT @364

APPEND ~MASTAREA.2DA~
~F_7777  value
F_7779  value
F_8888  value
F_0111  value
F_0112  value
F_0115  value
F_0222  value~
	UNLESS ~F_0111~

//COPY ~DRIZZTSAGA/TIZ~ ~DZTS-ARE~
COPY + ~DRIZZTSAGA/tisunpack.exe~ ~tisunpack.exe~
	 ~DRIZZTSAGA/ARE-DATA~ ~DZTS-ARE~

// Assign area scripts:
COPY + ~OVERRIDE/F_0111.are~ ~OVERRIDE~
	 ~OVERRIDE/F_0112.are~ ~OVERRIDE~
	 ~OVERRIDE/F_0113.are~ ~OVERRIDE~
	 ~OVERRIDE/F_0114.are~ ~OVERRIDE~
	 ~OVERRIDE/F_0115.are~ ~OVERRIDE~
	 ~OVERRIDE/F_0222.are~ ~OVERRIDE~
	 ~OVERRIDE/F_0223.are~ ~OVERRIDE~
	 ~OVERRIDE/F_6661.are~ ~OVERRIDE~
	 ~OVERRIDE/F_6664.are~ ~OVERRIDE~
	 ~OVERRIDE/F_6666.are~ ~OVERRIDE~
	 ~OVERRIDE/F_6667.are~ ~OVERRIDE~
	 ~OVERRIDE/F_6668.are~ ~OVERRIDE~
	 ~OVERRIDE/F_7777.are~ ~OVERRIDE~
	 ~OVERRIDE/F_7778.are~ ~OVERRIDE~
	 ~OVERRIDE/F_7779.are~ ~OVERRIDE~
	 ~OVERRIDE/F_8888.are~ ~OVERRIDE~
	 ~OVERRIDE/F_8889.are~ ~OVERRIDE~
	 ~OVERRIDE/F_9191.are~ ~OVERRIDE~
	 ~OVERRIDE/F_9292.are~ ~OVERRIDE~
	 ~OVERRIDE/F_9393.are~ ~OVERRIDE~
	 ~OVERRIDE/F_9494.are~ ~OVERRIDE~
	 ~OVERRIDE/F_9595.are~ ~OVERRIDE~
	 ~OVERRIDE/F_9696.are~ ~OVERRIDE~
	 ~OVERRIDE/F_9797.are~ ~OVERRIDE~
	 ~OVERRIDE/F_9898.are~ ~OVERRIDE~
	 ~OVERRIDE/F_9999.are~ ~OVERRIDE~
	WRITE_EVALUATED_ASCII 0x94 "%SOURCE_RES%" #8
BUT_ONLY_IF_IT_CHANGES
	 
// Sounds:

PRINT @361

COPY ~DRIZZTSAGA/Sounds~ ~override~	

// Items:

PRINT @363

COPY ~DRIZZTSAGA/ITM/F_ADAGGR.ITM~     ~override~       
  SAY NAME1 @133 
  SAY NAME2 @134 
  SAY UNIDENTIFIED_DESC @135
  SAY DESC @136

COPY ~DRIZZTSAGA/ITM/F_ALEAT.ITM~     ~override~       
  SAY NAME1 @137 
  SAY NAME2 @138 
  SAY UNIDENTIFIED_DESC @139
  SAY DESC @140

COPY ~DRIZZTSAGA/ITM/F_AMUL28.ITM~     ~override~       
  SAY NAME1 @141 
  SAY NAME2 @141
  SAY UNIDENTIFIED_DESC @142
  SAY DESC @143

COPY ~DRIZZTSAGA/ITM/F_AMSHLD.ITM~     ~override~       
  SAY NAME1 @141 
  SAY NAME2 @144 
  SAY UNIDENTIFIED_DESC @142
  SAY DESC @145

COPY ~DRIZZTSAGA/ITM/F_AMSPID.ITM~     ~override~       
  SAY NAME1 @146 
  SAY NAME2 @146 
  SAY UNIDENTIFIED_DESC @147 
  SAY DESC @148

COPY ~DRIZZTSAGA/ITM/F_ARTSWD.ITM~     ~override~       
  SAY NAME1 @149 
  SAY NAME2 @150 
  SAY UNIDENTIFIED_DESC @151 
  SAY DESC @152

COPY ~DRIZZTSAGA/ITM/F_BEARKI.itm~     ~override~       
  SAY NAME1 @153 
  SAY NAME2 @153 
  SAY UNIDENTIFIED_DESC @154 
  SAY DESC @154

COPY ~DRIZZTSAGA/ITM/F_BEARSU.ITM~     ~override~       
  SAY NAME1 @155
  SAY NAME2 @155
  SAY UNIDENTIFIED_DESC @156
  SAY DESC @156
  SAY 0x16e @477
  SAY 0x19e @478

COPY ~DRIZZTSAGA/ITM/F_BELAMU.ITM~     ~override~       

COPY ~DRIZZTSAGA/ITM/F_BELSW.ITM~     ~override~       

COPY ~DRIZZTSAGA/ITM/F_BELT12.ITM~     ~override~       
  SAY NAME1 @157 
  SAY NAME2 @158 
  SAY UNIDENTIFIED_DESC @159 
  SAY DESC @160

COPY ~DRIZZTSAGA/ITM/F_BELT13.ITM~     ~override~       
  SAY NAME1 @157 
  SAY NAME2 @161 
  SAY UNIDENTIFIED_DESC @159 
  SAY DESC @162

COPY ~DRIZZTSAGA/ITM/F_BELT14.ITM~     ~override~       
  SAY NAME1 @157 
  SAY NAME2 @163 
  SAY UNIDENTIFIED_DESC @159 
  SAY DESC @164

COPY ~DRIZZTSAGA/ITM/F_BLUN28.ITM~     ~override~       
  SAY NAME1 @165 
  SAY NAME2 @166 
  SAY UNIDENTIFIED_DESC @167 
  SAY DESC @168

COPY ~DRIZZTSAGA/ITM/F_BLUN35.ITM~     ~override~       
  SAY NAME1 @169 
  SAY NAME2 @170 
  SAY UNIDENTIFIED_DESC @171 
  SAY DESC @172

COPY ~DRIZZTSAGA/ITM/F_BOOTHS.ITM~     ~override~       
  SAY NAME1 @173 
  SAY NAME2 @174 
  SAY UNIDENTIFIED_DESC @175 
  SAY DESC @176

COPY ~DRIZZTSAGA/ITM/F_BRUBOO.ITM~     ~override~       
  SAY NAME1 @177 
  SAY NAME2 @177 
  SAY UNIDENTIFIED_DESC @178 
  SAY DESC @178

COPY ~DRIZZTSAGA/ITM/F_BRUEAX.ITM~     ~override~       
  SAY NAME1 @179 
  SAY NAME2 @180 
  SAY DESC @181

COPY ~DRIZZTSAGA/ITM/F_BRUEHL.ITM~     ~override~       
  SAY NAME1 @182 
  SAY NAME2 @183 
  SAY DESC @184

COPY ~DRIZZTSAGA/ITM/F_BRUEPL.ITM~     ~override~       
  SAY NAME1 @185 
  SAY NAME2 @186 
  SAY UNIDENTIFIED_DESC @187 
  SAY DESC @188

COPY ~DRIZZTSAGA/ITM/F_BRUEXB.ITM~     ~override~       
  SAY NAME1 @189 
  SAY NAME2 @190 
  SAY UNIDENTIFIED_DESC @191 
  SAY DESC @192

COPY ~DRIZZTSAGA/ITM/F_CATARW.ITM~           ~override~  
  SAY NAME1 @193 
  SAY NAME2 @194 
  SAY DESC @195

COPY ~DRIZZTSAGA/ITM/F_CATSBW.ITM~           ~override~        
  SAY NAME1 @196 
  SAY NAME2 @197 
  SAY DESC @198

COPY ~DRIZZTSAGA/ITM/F_CATSWD.ITM~           ~override~        
  SAY NAME1 @199 
  SAY NAME2 @200 
  SAY DESC @201

COPY ~DRIZZTSAGA/ITM/F_CLDCLK.ITM~          ~override~       
  SAY NAME1 @202 
  SAY NAME2 @202 
  SAY UNIDENTIFIED_DESC @203 
  SAY DESC @203

COPY ~DRIZZTSAGA/ITM/F_CORN.ITM~             ~override~          
  SAY NAME1 @204 
  SAY NAME2 @204 
  SAY UNIDENTIFIED_DESC @205
  SAY 0xae @479
  SAY 0x10e @479
  SAY 0x16e @479
  SAY 0x1ce @479
  SAY 0x22e @479
  SAY 0x28e @479
  SAY 0x2ee @479
  SAY 0x34e @479
  SAY 0x3ae @479
  SAY 0x40e @479
  SAY 0x46e @479

COPY ~DRIZZTSAGA/ITM/F_CYCWPN.ITM~           ~override~        
  SAY NAME2 @206 

COPY ~DRIZZTSAGA/ITM/F_DAGPSN.ITM~           ~override~        
  SAY NAME1 @207 
  SAY NAME2 @208 
  SAY UNIDENTIFIED_DESC @209 
  SAY DESC @210

COPY ~DRIZZTSAGA/ITM/F_DDRINK.ITM~           ~override~        
  SAY NAME1 @211 
  SAY NAME2 @212 
  SAY UNIDENTIFIED_DESC @213 
  SAY DESC @214
  SAY 0x19e @480

COPY ~DRIZZTSAGA/ITM/F_DEATHS.ITM~          ~override~       

COPY ~DRIZZTSAGA/ITM/F_DEMLIT.ITM~          ~override~       
  SAY NAME1 @215 
  SAY NAME2 @216 
  SAY UNIDENTIFIED_DESC @217 
  SAY DESC @218

COPY ~DRIZZTSAGA/ITM/F_DEMSPI.ITM~          ~override~       
  SAY NAME1 @219 

COPY ~DRIZZTSAGA/ITM/F_DISMAC.ITM~          ~override~       
  SAY NAME1 @165 
  SAY NAME2 @220 
  SAY UNIDENTIFIED_DESC @221 
  SAY DESC @222

COPY ~DRIZZTSAGA/ITM/F_DRAGCL.ITM~          ~override~       
  SAY NAME1 @219 

COPY ~DRIZZTSAGA/ITM/F_DRGPLA.ITM~          ~override~       
  SAY NAME1 @223 
  SAY NAME2 @224 
  SAY DESC @225

COPY ~DRIZZTSAGA/ITM/F_DRIWPN.ITM~           ~override~        
  SAY NAME1 @227
  SAY NAME2 @227 
  SAY UNIDENTIFIED_DESC @228 
  SAY DESC @228

COPY ~DRIZZTSAGA/ITM/F_DWKEY.ITM~          ~override~       
  SAY NAME1 @229 
  SAY NAME2 @230 
  SAY UNIDENTIFIED_DESC @231 
  SAY DESC @232

COPY ~DRIZZTSAGA/ITM/F_DRSCUL.itm~          ~override~       
  SAY NAME1 @233 
  SAY NAME2 @233 
  SAY UNIDENTIFIED_DESC @234 
  SAY DESC @234

COPY ~DRIZZTSAGA/ITM/F_DWRDPT.ITM~          ~override~       
  SAY NAME1 @235 
  SAY NAME2 @236 
  SAY UNIDENTIFIED_DESC @237 
  SAY DESC @238

COPY ~DRIZZTSAGA/ITM/F_ELFCLK.ITM~           ~override~        
  SAY NAME1 @239 
  SAY NAME2 @240 
  SAY UNIDENTIFIED_DESC @241 
  SAY DESC @242

COPY ~DRIZZTSAGA/ITM/F_ETTN.ITM~             ~override~          

COPY ~DRIZZTSAGA/ITM/F_FROSBL.ITM~          ~override~       
  SAY NAME1 @157 
  SAY NAME2 @243 
  SAY UNIDENTIFIED_DESC @159 
  SAY DESC @244

COPY ~DRIZZTSAGA/ITM/F_FROSTS.ITM~          ~override~       
  SAY NAME1 @245 
  SAY NAME2 @245 
  SAY UNIDENTIFIED_DESC @246 
  SAY DESC @246

COPY ~DRIZZTSAGA/ITM/F_GAXRNG.ITM~          ~override~       
  SAY NAME1 @215 
  SAY NAME2 @247 
  SAY UNIDENTIFIED_DESC @217 
  SAY DESC @248

COPY ~DRIZZTSAGA/ITM/F_GHOST.ITM~            ~override~         
  SAY NAME2 @206 

COPY ~DRIZZTSAGA/ITM/F_GIANAX.ITM~          ~override~       
  SAY NAME1 @179 
  SAY NAME2 @249 

COPY ~DRIZZTSAGA/ITM/F_GOCLAW.ITM~           ~override~        
  SAY NAME1 @250 
  SAY NAME2 @251 
  SAY UNIDENTIFIED_DESC @252 
  SAY DESC @253

COPY ~DRIZZTSAGA/ITM/F_GRIOUN.itm~           ~override~        
  SAY NAME1 @254 
  SAY NAME2 @255 
  SAY UNIDENTIFIED_DESC @256 
  SAY DESC @257

COPY ~DRIZZTSAGA/ITM/F_GUECLW.ITM~          ~override~       
  SAY NAME2 @206 

COPY ~DRIZZTSAGA/ITM/F_HARPY.ITM~            ~override~         

COPY ~DRIZZTSAGA/ITM/F_ICEAXE.ITM~           ~override~        
  SAY NAME1 @258 
  SAY NAME2 @259 
  SAY UNIDENTIFIED_DESC @260 
  SAY DESC @261

COPY ~DRIZZTSAGA/ITM/F_ICEAX5.ITM~          ~override~       
  SAY NAME1 @258 
  SAY NAME2 @262 
  SAY UNIDENTIFIED_DESC @260 
  SAY DESC @263

COPY ~DRIZZTSAGA/ITM/F_IMMUN2.ITM~          ~override~       

COPY ~DRIZZTSAGA/ITM/F_IMMUN3.ITM~          ~override~       

COPY ~DRIZZTSAGA/ITM/F_IRENOT.ITM~          ~override~       
  SAY NAME1 @264 
  SAY NAME2 @264 
  SAY UNIDENTIFIED_DESC @265 
  SAY DESC @265

COPY ~DRIZZTSAGA/ITM/F_JARLAX.ITM~          ~override~       
  SAY NAME1 @179 
  SAY NAME2 @266 
  SAY UNIDENTIFIED_DESC @267 
  SAY DESC @268
  SAY 0x25e @481

COPY ~DRIZZTSAGA/ITM/F_JARLPL.ITM~          ~override~       
  SAY NAME1 @269 
  SAY NAME2 @270 
  SAY UNIDENTIFIED_DESC @271 
  SAY DESC @272

COPY ~DRIZZTSAGA/ITM/F_JMPBOO.ITM~          ~override~       
  SAY NAME1 @173 
  SAY NAME2 @273 
  SAY UNIDENTIFIED_DESC @274 
  SAY DESC @275

COPY ~DRIZZTSAGA/ITM/F_KSCULL.ITM~           ~override~        
  SAY NAME1 @206 
  SAY NAME2 @206 
  SAY UNIDENTIFIED_DESC @276 
  SAY DESC @276

COPY ~DRIZZTSAGA/ITM/F_MAGMAC.ITM~          ~override~       
  SAY NAME1 @277 
  SAY NAME2 @278 
  SAY UNIDENTIFIED_DESC @279 
  SAY DESC @280
  SAY 0x2be @482
  SAY 0x55e @483
  SAY 0x5ee @484

COPY ~DRIZZTSAGA/ITM/F_MARRNG.ITM~          ~override~       

COPY ~DRIZZTSAGA/ITM/F_MARISW.ITM~           ~override~        
  SAY NAME1 @199 
  SAY NAME2 @281 
  SAY UNIDENTIFIED_DESC @282 
  SAY DESC @283

COPY ~DRIZZTSAGA/ITM/F_MEDBIT.ITM~          ~override~       
  SAY NAME1 @284 
  SAY NAME2 @284 
  SAY UNIDENTIFIED_DESC @284 

COPY ~DRIZZTSAGA/ITM/F_MITHCH.ITM~          ~override~       
  SAY NAME1 @285 
  SAY NAME2 @286 
  SAY UNIDENTIFIED_DESC @287 
  SAY DESC @288

COPY ~DRIZZTSAGA/ITM/F_MOONSW.ITM~           ~override~        
  SAY NAME1 @289 
  SAY NAME2 @289 
  SAY UNIDENTIFIED_DESC @282 
  SAY DESC @290

COPY ~DRIZZTSAGA/ITM/F_MUMFIS.ITM~          ~override~       

COPY ~DRIZZTSAGA/ITM/F_OPALPL.ITM~          ~override~       
  SAY NAME1 @185 
  SAY NAME2 @291 
  SAY UNIDENTIFIED_DESC @292 
  SAY DESC @293

COPY ~DRIZZTSAGA/ITM/F_PANTH.ITM~            ~override~         
  SAY NAME1 @294 
  SAY NAME2 @294 
  SAY UNIDENTIFIED_DESC @295 
  SAY DESC @295
  SAY 0x16e @484
  SAY 0x19e @485

COPY ~DRIZZTSAGA/ITM/F_PETHLM.ITM~           ~override~        
  SAY NAME1 @182 
  SAY NAME2 @296 
  SAY UNIDENTIFIED_DESC @297 
  SAY DESC @298

COPY ~DRIZZTSAGA/ITM/F_POTN52.ITM~           ~override~        
  SAY NAME1 @235 
  SAY NAME2 @299 
  SAY UNIDENTIFIED_DESC @300 
  SAY DESC @301
  SAY 0xde @486

COPY ~DRIZZTSAGA/ITM/F_POTN55.itm~           ~override~        
  SAY NAME1 @235 
  SAY NAME2 @302 
  SAY UNIDENTIFIED_DESC @303 
  SAY DESC @304
  SAY 0xde @486

COPY ~DRIZZTSAGA/ITM/F_RAISER.ITM~           ~override~        
  SAY NAME1 @305 
  SAY NAME2 @306 
  SAY UNIDENTIFIED_DESC @307 
  SAY DESC @308

COPY ~DRIZZTSAGA/ITM/F_SCIM03.ITM~           ~override~        
  SAY NAME1 @309 
  SAY NAME2 @310 
  SAY UNIDENTIFIED_DESC @311 
  SAY DESC @312

COPY ~DRIZZTSAGA/ITM/F_SLAYCL.ITM~          ~override~       
  SAY NAME2 @206 

COPY ~DRIZZTSAGA/ITM/F_SPIRCL.ITM~           ~override~        
  SAY NAME2 @206 

COPY ~DRIZZTSAGA/ITM/F_SUMTAN.ITM~           ~override~        
  SAY NAME1 @313 
  SAY NAME2 @313 
  SAY UNIDENTIFIED_DESC @314 
  SAY DESC @314

COPY ~DRIZZTSAGA/ITM/F_SW2H09.ITM~           ~override~        
  SAY NAME1 @315 
  SAY NAME2 @316 
  SAY UNIDENTIFIED_DESC @317 
  SAY DESC @318

COPY ~DRIZZTSAGA/ITM/F_SW2H17.ITM~           ~override~        
  SAY NAME1 @315 
  SAY NAME2 @319 
  SAY UNIDENTIFIED_DESC @317 
  SAY DESC @320

COPY ~DRIZZTSAGA/ITM/F_THOOD.itm~            ~override~         
  SAY NAME1 @321 
  SAY NAME2 @321 
  SAY UNIDENTIFIED_DESC @322 
  SAY DESC @323

COPY ~DRIZZTSAGA/ITM/F_UNDRNG.ITM~          ~override~       
  SAY NAME1 @215 
  SAY NAME2 @215 
  SAY UNIDENTIFIED_DESC @217 
  SAY DESC @217

COPY ~DRIZZTSAGA/ITM/F_VAMP1.ITM~            ~override~         
  SAY NAME1 @324 

COPY ~DRIZZTSAGA/ITM/F_VIMMUN.ITM~          ~override~       

COPY ~DRIZZTSAGA/ITM/F_WAILIN.ITM~          ~override~       
  SAY NAME1 @324 

COPY ~DRIZZTSAGA/ITM/F_WERECL.ITM~          ~override~       
  SAY NAME1 @239 
  SAY NAME2 @325 
  SAY UNIDENTIFIED_DESC @326 
  SAY DESC @327

COPY ~DRIZZTSAGA/ITM/F_WEREHI.ITM~          ~override~       
  SAY NAME1 @284 
  SAY NAME2 @284 
  SAY UNIDENTIFIED_DESC @284 

COPY ~DRIZZTSAGA/ITM/F_WINTCL.ITM~          ~override~       
  SAY NAME1 @328 
  SAY NAME2 @329 
  SAY UNIDENTIFIED_DESC @330 
  SAY DESC @331

COPY ~DRIZZTSAGA/ITM/F_WOLFCL.ITM~          ~override~       
  SAY NAME1 @284 
  SAY NAME2 @284 
  SAY UNIDENTIFIED_DESC @284 

COPY ~DRIZZTSAGA/ITM/F_WULFHI.itm~          ~override~       
  SAY NAME1 @332 
  SAY NAME2 @333 
  SAY DESC @334

COPY ~DRIZZTSAGA/ITM/F_WULFHM.ITM~          ~override~       
  SAY NAME1 @335 
  SAY NAME2 @336 
  SAY DESC @337
  WRITE_ASCII 0x3a "F_IHAM04"
  WRITE_ASCII 0x76 "F_IHAM04"

COPY ~DRIZZTSAGA/ITM/F_WULHLM.ITM~           ~override~        
  SAY NAME1 @182 
  SAY NAME2 @182 
  SAY UNIDENTIFIED_DESC @338 
  SAY DESC @338

COPY ~DRIZZTSAGA/ITM/F_XBOW08.itm~           ~override~        
  SAY NAME1 @189
  SAY NAME2 @339
  SAY UNIDENTIFIED_DESC @191
  SAY DESC @340

COPY ~DRIZZTSAGA/ITM/F_SW2H08.ITM~		~override~
  SAY NAME1 @315
  SAY NAME2 @501
  SAY UNIDENTIFIED_DESC @317
  SAY DESC @502
  
COPY ~DRIZZTSAGA/ITM/F_MEDGAZ.ITM~		~override~
  SAY NAME1 @284
  SAY NAME2 @284
  SAY UNIDENTIFIED_DESC @284

COPY_EXISTING ~MISC01.ITM~ 	~override/F_EMPTY.ITM~	// undroppable placeholder for Drizzt's shield slot, otherwise game crashes when off-hand weapon is equipped
  SAY NAME1 @227
  SAY NAME2 @227 
  SAY UNIDENTIFIED_DESC @228 
  SAY DESC @228
  WRITE_BYTE 0x18 0x21
  WRITE_SHORT 0x1c 12
  WRITE_ASCII 0x3a ~~ #8
  WRITE_ASCII 0x58 ~~ #8
  WRITE_ASCII 0x44 ~~ #8
    
// item BAMs:
COPY ~DRIZZTSAGA/BAM~ ~override~

// Scripts:	

PRINT @369

COMPILE	~DRIZZTSAGA/BAF~

// Dialogues:
COMPILE ~DRIZZTSAGA/DLG~

// Misc:

PRINT @370

COPY ~DRIZZTSAGA/misc/F_DIE.EFF~ 	~override~
	 ~DRIZZTSAGA/misc/F_MACDIS.EFF~ ~override~
  
COPY ~DRIZZTSAGA/BMP~ 	~override~

PRINT @487

AT_EXIT ~DRIZZTSAGA/Areas.bat~


///////////////////////////////////////////////////////////////////
//// BP-BGT Worldmap Support //////////////////////////////////////
///////////////////////////////////////////////////////////////////


BEGIN @489  //Install Worldmap v7 Support
REQUIRE_PREDICATE FILE_EXISTS ~DZTS-ARE/F_0111SR.BMP~ @490

ACTION_IF FILE_EXISTS_IN_GAME ~FW0100.are~ THEN BEGIN	// Tutu
  ACTION_IF FILE_EXISTS ~Worldmap/map_mods_areas.tbl~ THEN BEGIN
    COPY ~Worldmap/map_mods_areas.tbl~  ~Worldmap~
     APPEND_FILE ~DRIZZTSAGA/Worldmap/wm6_areas.tbl~
    COPY ~Worldmap/map_mods_links.tbl~  ~Worldmap~
     APPEND_FILE ~DRIZZTSAGA/Worldmap/Tutu/wm6_links.tbl~
    COPY ~Worldmap/map_mods_trans.tra~  ~Worldmap~
     APPEND_FILE_EVALUATE ~DRIZZTSAGA/Worldmap/TRA/%LANGUAGE%/WM6_worldmap.tra~
  END
  ELSE BEGIN
    MKDIR ~Worldmap~
    COPY ~DRIZZTSAGA/Worldmap/wm6_areas.tbl~ ~Worldmap/map_mods_areas.tbl~
    COPY ~DRIZZTSAGA/Worldmap/Tutu/wm6_links.tbl~ ~Worldmap/map_mods_links.tbl~
    COPY ~DRIZZTSAGA/Worldmap/TRA/%LANGUAGE%/WM6_worldmap.tra~ ~Worldmap/map_mods_trans.tra~
  END
END
ELSE BEGIN												// BGT
  ACTION_IF FILE_EXISTS ~Worldmap/map_mods_areas.tbl~ THEN BEGIN
    COPY ~Worldmap/map_mods_areas.tbl~  ~Worldmap~
     APPEND_FILE ~DRIZZTSAGA/Worldmap/wm6_areas.tbl~
    COPY ~Worldmap/map_mods_links.tbl~  ~Worldmap~
     APPEND_FILE ~DRIZZTSAGA/Worldmap/BGT/wm6_links.tbl~
    COPY ~Worldmap/map_mods_trans.tra~  ~Worldmap~
     APPEND_FILE_EVALUATE ~DRIZZTSAGA/Worldmap/TRA/%LANGUAGE%/WM6_worldmap.tra~
  END
  ELSE BEGIN
    MKDIR ~Worldmap~
    COPY ~DRIZZTSAGA/Worldmap/wm6_areas.tbl~ ~Worldmap/map_mods_areas.tbl~
    COPY ~DRIZZTSAGA/Worldmap/BGT/wm6_links.tbl~ ~Worldmap/map_mods_links.tbl~
    COPY ~DRIZZTSAGA/Worldmap/TRA/%LANGUAGE%/WM6_worldmap.tra~ ~Worldmap/map_mods_trans.tra~
  END
END

EXTEND_TOP  ~F_0113.BCS~   ~DRIZZTSAGA/SNIP/eF_0113.BAF~

INCLUDE ~DRIZZTSAGA/MISC/del_are_trigger.tph~	// Good occasion to make use of that messy chunk of code... :p

COPY_EXISTING ~F_0111.ARE~ ~OVERRIDE~
  SPRINT TRIGGERNAME "bear village"
  SET TRIGGERTYPE = 2
  LAUNCH_PATCH_MACRO ~DELETE_INFO_TRIGGER~
BUT_ONLY_IF_IT_CHANGES

COPY_EXISTING ~F_0112.ARE~ ~OVERRIDE~
  SPRINT TRIGGERNAME "GIANT HILLS"
  LAUNCH_PATCH_MACRO ~DELETE_INFO_TRIGGER~
BUT_ONLY_IF_IT_CHANGES

COPY_EXISTING ~F_7777.ARE~ ~OVERRIDE~
  SPRINT TRIGGERNAME "#icewind02"
  LAUNCH_PATCH_MACRO ~DELETE_INFO_TRIGGER~
BUT_ONLY_IF_IT_CHANGES

COPY_EXISTING ~F_7779.ARE~ ~OVERRIDE~
  SPRINT TRIGGERNAME "#icewind05"
  LAUNCH_PATCH_MACRO ~DELETE_INFO_TRIGGER~
  SPRINT TRIGGERNAME "#tocrate"
  LAUNCH_PATCH_MACRO ~DELETE_INFO_TRIGGER~
BUT_ONLY_IF_IT_CHANGES

COPY_EXISTING ~F_8888.ARE~ ~OVERRIDE~
  SPRINT TRIGGERNAME "#thecrate"
  LAUNCH_PATCH_MACRO ~DELETE_INFO_TRIGGER~
BUT_ONLY_IF_IT_CHANGES

COPY + ~DRIZZTSAGA\ARE-DATA\WM6~ ~DZTS-ARE~	 // Replace travel triggers with searchmap WM regions


/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////  
// EOF
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////  
