Title: How to create New Mods and Campaigns Post by: olly on December 21, 2014, 05:20:12 PM With all the recent development of tools, we can now make new maps and armies for whole new campaigns.
http://forum.dark-omen.org/news/well-change-t780.0.html;msg12680#msg12680 (http://forum.dark-omen.org/news/well-change-t780.0.html;msg12680#msg12680) Please download and use our latest Mod Pack and copy the Dark Omen 2 mod as the perfect starting point to examine and create your own campaigns from. Rename your original PRG_ENG folder to PRG_ENGOrig and then extract or copy/paste the 3 new folders into Dark Omen folder. http://forum.dark-omen.org/help-section/read-me-ultimate-dark-omen-xpvistawin7win81win10-game-fixes-t111.0.html (http://forum.dark-omen.org/help-section/read-me-ultimate-dark-omen-xpvistawin7win81win10-game-fixes-t111.0.html) http://forum.dark-omen.org/2d-sprites/adding-more-sprites-to-dark-omen-t1214.0.html (http://forum.dark-omen.org/2d-sprites/adding-more-sprites-to-dark-omen-t1214.0.html) and how to add more multiplayer races and how to add new sprites, portraits, banners, waypoints/triggers and AI onto mission 1 trading post. Over the following weeks I will create separate topics for each stage -> but for now I will post a quick guide to modifying AI CTL scripts for alternate campaigns. 1) Adding new Units onto Mission 1 - Add new unit to xslots.txt C:\Program Files (x86)\Dark Omen\Mods\Dark Omen 2\PRG_ENG Then add new deployment in B1_01.BTB and waypoints and assign CTL AI script. 2) Creating New 3d maps 3) Adding new Audio to maps 4) Creating new Cut-scene meetings/talking 5) Title: Re: How to create New Mods and Campaigns Post by: olly on December 21, 2014, 05:28:59 PM 1) Adding new Units onto Mission 1
work in progress -> Open B1_01.BTB using BTB Editor http://en.dark-omen.org/downloads/1.-modding-tools/1.-map-editor/index.html (http://en.dark-omen.org/downloads/1.-modding-tools/1.-map-editor/index.html) Scroll to bottom and add in new SUBCHUNK using BTB to XML converter BTB CHUNK 6000 <503>SUBCHUNK <5>INTEGER = 16387 (Type of Game Object Enemy AI) <1>INTEGER = 100 (X position) <2>INTEGER = 1120 (Y position) <6>INTEGER = 48 (radius of area) <7>INTEGER = 11 (direction) <11>INTEGER = 12 (Node ID) <12>INTEGER = 13 (Unit ID) (WH32Edit Unit ID 133 = Enemy AI) Original Goblin Archer <SUBRECORD type="503"> <INT type="5"> 16387 </INT> <INT type="1"> 1044 </INT> <INT type="2"> 1111 </INT> <INT type="6"> 48 </INT> <INT type="7"> 301 </INT> <INT type="11"> 0 </INT> <INT type="12"> 129 </INT> <INT type="13"> 2 </INT> </SUBRECORD> Using Wh32Editv2 http://en.dark-omen.org/downloads/view-details/1.-modding-tools/2.-army-editors/wh32edit-v2.html (http://en.dark-omen.org/downloads/view-details/1.-modding-tools/2.-army-editors/wh32edit-v2.html) open B101NME.ARM and copy & paste Gribnut, the Night Goblin Archers and set -> General Troops 1 / 1 No Ranks 1 Banner to [xSlot Banner 00] Unit Id: 133 Name Id: [xSlot NAME 00] Book Profile: [xSlot Book 00] Leader/Unit Sprite: [xSlot SPRITE 000] for Leader and Unit Use BTB/XML http://forum.dark-omen.org/tools/btb-editor-t1498.0.html;msg14522#msg14522 (http://forum.dark-omen.org/tools/btb-editor-t1498.0.html;msg14522#msg14522) Add in a new subchunk 6000 503 with Unit Id: 133 and script 17 by copy and pasting the 2nd subchunk for 129 Unit Id: and remember to increase the 6000 header by 1. Use CTL dis tool http://en.dark-omen.org/downloads/view-details/1.-modding-tools/4.-miscellaneous-tools/ctldis.html (http://en.dark-omen.org/downloads/view-details/1.-modding-tools/4.-miscellaneous-tools/ctldis.html) and read the following CTL discussions -> http://forum.dark-omen.org/singleplayer/enemy-units-in-campaign-t1094.0.html (http://forum.dark-omen.org/singleplayer/enemy-units-in-campaign-t1094.0.html) Ammend B101.CTL script to have a new .func 17 by copy and pasting .func 2 and change set_label to 43976 as .func 6 = 43975 .func 17 init_unit 128 clear_ctrl_flag 32768 set_label 43976 #3c 240, 0 set_event_handler 15 #3e 13, 31 wait_for_deploy save_ip goto 7 Then copy and paste .func 7,8 and 9 and rename to 18,19 and 20 being careful to ammend .func to end with goto 18 and check their inner calls to each other -> This will provide our new archer unit with his own nodes to navigate and check if enemy is present. Remember to increase Block 6000 Header to now have 38 nodes, it was 35. BTB editor shows nodes 9 17 and 26 were the original 1st goblin archer waypoints that we will copy and paste onto the end of the section as nodes 36,37 and 38, adjusting their map X and Y positions to new locations. Also set subchunk 35 to now use AI script 17 and set .func 17 to end with goto 18 .func 17 init_unit 128 clear_ctrl_flag 32768 set_label 43976 #3c 240, 0 set_event_handler 15 #3e 13, 31 wait_for_deploy save_ip goto 18 .func 18 reset_call_stack save_ip set_unit_r_i 0, 1 move_to_node 36 reset_call_stack save_ip do test_self_at_node 36 iftrue search_and_shoot_enemy 58, 100, 512 else search_and_shoot_enemy 58, 50, 512 iffalse test_unit_flag1 16 iftrue move_to_node 36 endif else block_movement sleep endif endif set_timer 10 wait_for_timer always .func 19 reset_call_stack save_ip set_unit_r_i 0, 2 move_to_node 37 reset_call_stack save_ip set_unit_r_i 2, 30 do test_self_at_node 37 iftrue search_and_shoot_enemy 58, 100, 512 iftrue set_unit_r_i 2, 30 else add_unit_r_i 2, -1 endif else search_and_shoot_enemy 58, 50, 512 iffalse test_unit_flag1 16 iftrue move_to_node 37 endif else block_movement sleep endif endif set_timer 10 wait_for_timer test_unit_r_eq_i 2, 0 whilenot goto 20 .func 20 reset_call_stack save_ip set_unit_r_i 0, 0 move_to_node 38 reset_call_stack save_ip set_unit_r_i 2, 30 do test_self_at_node 38 iftrue search_and_shoot_enemy 58, 100, 512 iftrue set_unit_r_i 2, 30 else add_unit_r_i 2, -1 endif else search_and_shoot_enemy 58, 50, 512 iffalse test_unit_flag1 16 iftrue move_to_node 38 endif else block_movement sleep endif endif set_timer 10 wait_for_timer test_unit_r_eq_i 2, 0 whilenot goto 18 and using XML to BTB copy 9 17 and 26 to be new nodes 36 37 and 38 <SUBRECORD type="503"> <INT type="5"> 1 </INT> <INT type="1"> 136 </INT> <INT type="2"> 783 </INT> <INT type="6"> 16 </INT> <INT type="7"> 0 </INT> <INT type="11"> 0 </INT> <INT type="12"> 0 </INT> <INT type="13"> 0 </INT> </SUBRECORD> <SUBRECORD type="503"> <INT type="5"> 1 </INT> <INT type="1"> 364 </INT> <INT type="2"> 255 </INT> <INT type="6"> 55 </INT> <INT type="7"> 0 </INT> <INT type="11"> 0 </INT> <INT type="12"> 0 </INT> <INT type="13"> 0 </INT> </SUBRECORD> <SUBRECORD type="503"> <INT type="5"> 1 </INT> <INT type="1"> 1256 </INT> <INT type="2"> 630 </INT> <INT type="6"> 51 </INT> <INT type="7"> 0 </INT> <INT type="11"> 0 </INT> <INT type="12"> 0 </INT> <INT type="13"> 0 </INT> </SUBRECORD> Add in new Infantry by modifying out.xml in notepad to have an extra deployment zone and waypoint (98) and increase header by 1 to 39 with matching AI CTL new script .func 21 with set_label 43977 <SUBRECORD type="503"> <INT type="5"> 16387 </INT> <INT type="1"> 150 </INT> <INT type="2"> 1250 </INT> <INT type="6"> 48 </INT> <INT type="7"> 11 </INT> <INT type="11"> 0 </INT> <INT type="12"> 134 </INT> <INT type="13"> 21 </INT> </SUBRECORD> <SUBRECORD type="503"> <INT type="5"> 5 </INT> <INT type="1"> 1380 </INT> <INT type="2"> 550 </INT> <INT type="6"> 40 </INT> <INT type="7"> 0 </INT> <INT type="11"> 98 </INT> <INT type="12"> 0 </INT> <INT type="13"> 34 </INT> </SUBRECORD> and CTL patrolling to waypoint 98 to match <INT type="11"> 98 </INT> .func 21 init_unit 128 clear_ctrl_flag 32768 set_label 43977 #3c 240, 0 set_event_handler 14 #3e 13, 29 set_global_r_i 0, 0 set_global_r_i 1, 0 wait_for_deploy save_ip #d0 58 set_timer 25 wait_for_timer play_self 01 reset_call_stack save_ip do wait_unit_flag3_clear 8192 #d0 58 iffalse search_and_attack_enemy 4, 0, 4096 iffalse test_unit_flag3 1024 iffalse patrol_to_waypoint 98 endif endif endif set_timer 10 wait_for_timer always ***** Maybe copy and paste original .func 14 to a new .func 22 and alter set_event_handler 14 to a new set_event_handler 22 and alter all other new sprites functions and numbers below by 1. Can test by adding copy of .func 14 to end of file (func. 24) and set_event_handler to that number (24) and then add in a new xSlots Sprite 002.spr for new Skaven Rat Ogre (give him glade guard 00fc for 80# sprite frames) NAME 02 "Rat Ogre" SPRITE 002 002 0x00fc SPRITE 002 002 0x00fc BANNER 002 002 0 BOOK 02 23 "[BOOKS]\\Troops\\SK_RO.bmp" "[BOOKS]\\Troops\\T_RatOgre.bmp" "Rat Ogre. m5 ws6 bs6 s4 t4 w4 i7 a4 Ld7" ********and alter all other new sprites functions and numbers below by 1 Title: Re: How to create New Mods and Campaigns Post by: olly on December 21, 2014, 05:30:23 PM Add in 003.sprite the Dwarf Slayer from DOE as a companion to your own human troops again with 00fc for 80# sprtie frames
Add in wizard class by using AI script taken from B5_01B .func 9 and set_event_handler 40 means goto .func 40 so copy and paste from B5_01B into our B1_01.CTL and Change .func 9 to .func 22 and set_label 43977 to set_label 43978. Change set_event_handler 40 to set_event_handler 23 and further down change send_event_to_unit_with_label 43977 to 43978 84 Then copy and paste B5_01B .func 40 into B1_01.CTL at the end of file and rename to .func 23 .func 9 init_unit 128 clear_ctrl_flag 32768 set_label 43977 #3c 360, 0 set_event_handler 40 #3e 13, 31 test_boss_defeated 2 iftrue #89 do sleep always endif add_spell 50 add_spell 51 add_spell 52 add_spell 53 set_unit_r_i 5, 1 wait_for_deploy save_ip add_magic_points 3 send_event_to_unit_with_label 43977, 84 reset_call_stack save_ip do set_timer 30 wait_for_timer search_and_attack_enemy 75, 0, 0 iffalse test_unit_flag3 1024 iffalse patrol_to_waypoint 99 endif endif always .func 40 clear_ctrl_flag 8 do get_event call 146 on_event 80 send_event_to_unit_with_label 43977, 81 end_event 6844 on_event 10 call 142 iffalse send_event_to_unit_with_label 43977, 82 endif end_event 3567 on_event 61 call 147 end_event 3567 on_event 84 cast_spell2 66, 32768, 1 end_event 6844 on_event 19 #14 8, 75 end_event 6844 on_event 20 #14 8, 75 end_event 6844 on_event 21 #14 9, 75 end_event 6844 on_event 5 #14 5, -1 iftrue send_event_to_stored_unit 21 endif end_event 6844 on_event 3 #9f iftrue call 142 iffalse call 143 endif endif end_event 6844 on_event 85 #47 iftrue set_unit_flag2 16 #48 set_return_func_iftrue 139 endif end_event 6844 on_event 75 #9f iftrue cast_spell -76, 128, 3 endif end_event 6844 on_event 76 call 145 end_event 3567 on_event 26 #9f iftrue call 144 endif end_event 6844 on_event 27 call 144 end_event 6844 on_event 4 #9b 0, 0 iffalse #44 set_return_func_with_restart_iftrue 127 endif end_event 6844 on_event 71 #d4 iffalse #d1 240 set_return_func_iftrue 137 endif end_event 6844 on_event 69 #d2 iftrue test_event_from_enemy iftrue #9f call 144 else set_return_func 134 endif endif end_event 6844 on_event 70 set_return_func 134 end_event 6844 on_event 22 test_event_from_enemy iffalse test_boss_defeated 2 iffalse test_label_exists 43978 iftrue test_global_r_eq_i 0, 1 iffalse test_label_exists 43977 iffalse play_other 1, 60 set_global_r_i 0, 1 endif endif endif endif test_boss_defeated 3 iffalse test_global_r_eq_i 1, 1 iffalse test_label_exists 43976 iffalse play_other 1, 61 set_global_r_i 1, 1 endif endif endif test_global_r_eq_i 2, 1 iffalse test_label_exists 43978 iffalse play_other 1, 62 set_global_r_i 2, 1 endif endif endif end_event 3567 call 124 @0xABC test_more_events while return_from_event_handler After changes -> add_spell 50 add_spell 51 add_spell 52 add_spell 53 .func 22 init_unit 128 clear_ctrl_flag 32768 set_label 43978 #3c 360, 0 set_event_handler 23 #3e 13, 31 test_boss_defeated 2 iftrue #89 do sleep always endif add_spell 50 add_spell 51 add_spell 52 add_spell 53 set_unit_r_i 5, 1 wait_for_deploy save_ip add_magic_points 3 send_event_to_unit_with_label 43978, 84 reset_call_stack save_ip do set_timer 30 wait_for_timer search_and_attack_enemy 75, 0, 0 iffalse test_unit_flag3 1024 iffalse patrol_to_waypoint 99 endif endif always .func 23 clear_ctrl_flag 8 do get_event call 146 on_event 80 send_event_to_unit_with_label 43978, 81 end_event 6844 on_event 10 call 142 iffalse send_event_to_unit_with_label 43978, 82 endif end_event 3567 on_event 61 call 147 end_event 3567 on_event 84 cast_spell2 66, 32768, 1 end_event 6844 on_event 19 #14 8, 75 end_event 6844 on_event 20 #14 8, 75 end_event 6844 on_event 21 #14 9, 75 end_event 6844 on_event 5 #14 5, -1 iftrue send_event_to_stored_unit 21 endif end_event 6844 on_event 3 #9f iftrue call 142 iffalse call 143 endif endif end_event 6844 on_event 85 #47 iftrue set_unit_flag2 16 #48 set_return_func_iftrue 139 endif end_event 6844 on_event 75 #9f iftrue cast_spell -76, 128, 3 endif end_event 6844 on_event 76 call 145 end_event 3567 on_event 26 #9f iftrue call 144 endif end_event 6844 on_event 27 call 144 end_event 6844 on_event 4 #9b 0, 0 iffalse #44 set_return_func_with_restart_iftrue 127 endif end_event 6844 on_event 71 #d4 iffalse #d1 240 set_return_func_iftrue 137 endif end_event 6844 on_event 69 #d2 iftrue test_event_from_enemy iftrue #9f call 144 else set_return_func 134 endif endif end_event 6844 on_event 70 set_return_func 134 end_event 6844 on_event 22 test_event_from_enemy iffalse test_boss_defeated 2 iffalse test_label_exists 43978 iftrue test_global_r_eq_i 0, 1 iffalse test_label_exists 43978 iffalse play_other 1, 60 set_global_r_i 0, 1 endif endif endif endif test_boss_defeated 3 iffalse test_global_r_eq_i 1, 1 iffalse test_label_exists 43976 iffalse play_other 1, 61 set_global_r_i 1, 1 endif endif endif test_global_r_eq_i 2, 1 iffalse test_label_exists 43979 iffalse play_other 1, 62 set_global_r_i 2, 1 endif endif endif end_event 3567 call 124 @0xABC test_more_events while return_from_event_handler Add into Xslots another copy of Grey Seer and change as seen below -> SPRITE 004 NAME 04 "Grey Seer" SPRITE 004 004 0x0230 SPRITE 004 004 0x0230 BANNER 004 004 0 BOOK 04 22 "[BOOKS]\\Troops\\SK_GR.bmp" "[BOOKS]\\Troops\\T_GreySeer.bmp" "Grey Seers occupy elevated positions in the Skaven hierachy and ordinary Skaven fear them greatly. The power of Skaven magic is anarchic and highly destructive. m5 ws6 bs6 s4 t4 w4 i7 a4 Ld7" Create new 004.spr banners in C:\Program Files (x86)\Dark Omen\Mods\Skaven\Graphics\Banners B1_01 SUBCHUNK 6000 = 42 so make it 43 as we are adding a deployment zone for the mage based on previous infantry rat ogre <SUBRECORD type="503"> <INT type="5"> 16387 </INT> <INT type="1"> 200 </INT> <INT type="2"> 1150 </INT> <INT type="6"> 50 </INT> <INT type="7"> 11 </INT> <INT type="11"> 0 </INT> <INT type="12"> 135 </INT> <INT type="13"> 21 </INT> </SUBRECORD> Use Wh32Edit to add grey seer on B101NME.ARM ////////////////////Multiplayer = Copy PRG_ENG Armytemp and Save Game into Mods\Skaven Folder and add in GS_ALLMP.AUD and UD_ALLMP.AUD to C:\Program Files (x86)\Dark Omen\Mods\Skaven\GAMEDATA\2parm for Aqrits xSlots to work /////////////////// C:\Program Files (x86)\Dark Omen\GRAPHICS\BOOKS\New folder HLBAN.SPR Width 216 / 3 = 72 (24 x 72 = 1728) Height 832 / 8 = 104 = 24 Tiles in total so make tiles 4-24 continue across from 3 and add new banners 25 - 192 tiles but counts down 1-8 then 2nd colum 1-8 - 3rd column -> 24 down to 8 so copy and past banners in correct order Title: Re: How to create New Mods and Campaigns Post by: olly on April 19, 2015, 10:58:55 PM Download the latest Mod Pack
http://forum.dark-omen.org/help-section/read-me-ultimate-dark-omen-xpvistawin7win81win10-game-fixes-t111.0.html (http://forum.dark-omen.org/help-section/read-me-ultimate-dark-omen-xpvistawin7win81win10-game-fixes-t111.0.html) Duplicate and rename then edit the latest Dark Omen 2 Mod template to create your own mod campaign, as it contains all the new characters and maps for single and multiplayer. :) |