commit 357520d4eee81c3a70a00c1b81b781f268b0ff0c Author: Chokboyz Date: Fri Apr 17 23:27:04 2009 +0000 Initial Win32 Character Editor import git-svn-id: http://openexile.googlecode.com/svn/trunk@21 4ebdad44-0ea0-11de-aab3-ff745001d230 diff --git a/Blades of Exile Char Editor/BLADPCED.CPP b/Blades of Exile Char Editor/BLADPCED.CPP new file mode 100644 index 00000000..3b816046 --- /dev/null +++ b/Blades of Exile Char Editor/BLADPCED.CPP @@ -0,0 +1,691 @@ +// Blades of Exile Editor +// May God have mercy on all our souls. + +#include + +#include "stdlib.h" +#include "string.h" +#include "stdio.h" +#include "math.h" + +#include "global.h" +#include "graphics.h" +#include "editors.h" +#include "edfileio.h" +#include "edsound.h" +#include "dlogtool.h" +#include "edaction.h" +#include "graphutl.h" + +void check_game_done(); +void load_cursors(); +void set_cursor(HCURSOR which_curs); +void change_cursor(POINT where_curs); +void check_colors(); +void cursor_go(); +void cursor_stay(); +Boolean verify_restore_quit(short mode); +void max_window(HWND window); +void update_item_menu(); +void check_cd_event(HWND hwnd,UINT message,UINT wparam,LONG lparam); + +scen_item_data_type far scen_item_list; + + + +/* Mac stuff globals */ +RECT windRECT, Drag_RECT; +Boolean All_Done = FALSE; +short had_text_freeze = 0,num_fonts; +Boolean in_startup_mode = TRUE,app_started_normally = FALSE,file_in_mem = FALSE; +Boolean play_sounds = TRUE,first_startup_update = TRUE,party_in_scen = FALSE; +Boolean diff_depth_ok = FALSE,first_sound_played = FALSE,spell_forced = FALSE,startup_loaded = FALSE; +Boolean save_maps = FALSE,first_time = FALSE,palette_suspect = FALSE,window_in_front = TRUE; + +HWND sbar; + +Boolean bgm_on = FALSE,bgm_init = FALSE; + +Boolean gInBackground = FALSE; +long start_time; + +// Cursors +short current_cursor = 120; +HCURSOR arrow_curs[3][3], sword_curs, boot_curs, key_curs, target_curs,talk_curs,look_curs; + +RECT pc_area_buttons[6][4] ; // 0 - whole 1 - pic 2 - name 3 - stat strs 4,5 - later +RECT item_string_rects[24][4]; // 0 - name 1 - drop 2 - id 3 - +RECT pc_info_rect; // Frame that holds a pc's basic info and items +RECT name_rect; //Holds pc name inside pc_info_rect +RECT info_area_rect; +RECT hp_sp_rect; // Holds hit points and spells points for pc +RECT skill_rect; // Holds "Skills:" string +RECT pc_skills_rect[19]; //Holds current pc's skill levels +RECT status_rect; //Holds the string "Status:" +RECT pc_status_rect[10]; //Holds first 8 effects on pc +RECT traits_rect; //Holds the string "Traits:" +RECT pc_traits_rect[16]; //Holds pc traits +RECT pc_race_rect; //Holds current pc's race +RECT edit_rect[5][2]; //Buttons that bring up pc edit dialog boxs + +Boolean game_run_before = TRUE; +short store_flags[3]; + +/* Adventure globals */ +party_record_type far party; +pc_record_type far adven[6]; +outdoor_record_type far outdoors[2][2]; +current_town_type far c_town; +big_tr_type far t_d; +town_item_list far t_i; +unsigned char far out[96][96]; + unsigned char far out_e[96][96]; +setup_save_type far setup_save; +unsigned char misc_i[64][64],sfx[64][64]; + +short current_active_pc = 0; + +stored_items_list_type far stored_items[3]; +stored_town_maps_type far town_maps,town_maps2; +stored_outdoor_maps_type far o_maps; + + +/* Display globals */ +short overall_mode = 45,current_spell_range; +Boolean first_update = TRUE,anim_onscreen = FALSE,frills_on = TRUE,sys_7_avail,suppress_stat_screen = FALSE; +short stat_window = 0,store_modifier; +Boolean monsters_going = FALSE; +short give_delays = 0; +Boolean dialog_not_toast = TRUE; + +// storage for dialogs +short store_chosen_pc; +short store_choice_mode; +location store_choice_loc; + +short town_size[3] = {64,48,24}; +short which_item_page[6] = {0,0,0,0,0,0}; // Remembers which of the 2 item pages pc looked at +//short display_mode = 0; // 0 - center 1- ul 2 - ur 3 - dl 4 - dr 5 - small win +short pixel_depth,dialog_answer; + + +// Spell casting globals +short store_mage = 0, store_priest = 0; +short store_mage_lev = 0, store_priest_lev = 0; +short store_spell_target = 6,pc_casting; +short num_targets_left = 0; +location spell_targets[8]; + + +/* Windoze stuff globals */ +Boolean cursor_shown = TRUE; +short store_pc_being_created; + +short ulx = 0, uly = 0; + +HWND mainPtr; +HWND force_dlog = NULL; +HFONT font,small_bold_font,italic_font,underline_font,bold_font,tiny_font; +HBITMAP bmap = NULL; +//HPALETTE hpal; +HDC main_dc,main_dc2,main_dc3; +HINSTANCE store_hInstance; +HACCEL accel; +BOOL event_handled; + +char szWinName[] = "Blades of Exile dialogs"; +char szAppName[] = "Blades of Exile Editor"; +char file_path_name[256]; + +Boolean block_erase = FALSE; + +long CALLBACK _export WndProc (HWND, UINT, WPARAM, LPARAM); +Boolean handle_menu (short, HMENU); + +int WINAPI WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR, int nCmdShow) +{ + MSG msg; + WNDCLASS wndclass,wndclass2; + short seed; + + if (!hPrevInstance) { + wndclass.style = CS_HREDRAW | CS_VREDRAW | CS_BYTEALIGNWINDOW; + wndclass.lpfnWndProc = WndProc; + wndclass.cbClsExtra = 0; + wndclass.cbWndExtra = 0; + wndclass.hInstance = hInstance; + wndclass.hIcon = LoadIcon(hInstance,MAKEINTRESOURCE(10)); + wndclass.hCursor = NULL; + wndclass.hbrBackground = (HBRUSH) GetStockObject(WHITE_BRUSH); + wndclass.lpszMenuName = MAKEINTRESOURCE(1); + wndclass.lpszClassName = szAppName; + + RegisterClass(&wndclass); + + wndclass2.style = CS_HREDRAW | CS_VREDRAW | CS_BYTEALIGNWINDOW; + wndclass2.lpfnWndProc = WndProc; + wndclass2.cbClsExtra = 0; + wndclass2.cbWndExtra = 0; + wndclass2.hInstance = hInstance; + wndclass2.hIcon = LoadIcon(hInstance,MAKEINTRESOURCE(10)); + wndclass2.hCursor = NULL; + wndclass2.hbrBackground = (HBRUSH) GetStockObject(WHITE_BRUSH); + wndclass2.lpszMenuName = NULL; + wndclass2.lpszClassName = szWinName; + + RegisterClass(&wndclass2); + } + + mainPtr = CreateWindow (szAppName, + "Blades of Exile Editor", + WS_OVERLAPPEDWINDOW, + 0, + 0, + 536, + 478, + NULL, + NULL, + hInstance, + NULL); + + if (!hPrevInstance) { // initialize + Get_Path(file_path_name); + store_hInstance = hInstance; + accel = LoadAccelerators(hInstance, MAKEINTRESOURCE(1)); + + load_cursors(); + seed = (short) GetCurrentTime(); + srand(seed); + + max_window(mainPtr); + Set_up_win (); + + font = CreateFont(-9,0,0,0,0, 0,0,0, 0,0, + 0,0,0,"MS Sans Serif"); + small_bold_font = CreateFont(12,0,0,0,700, 0,0,0, 0,0, + 0,0,0,"MS Sans Serif"); + italic_font = CreateFont(12,0,0,0,0, 1,0,0, 0,0, + 0,0,0,"MS Sans Serif"); + underline_font = CreateFont(12,0,0,0,0, 0,1,0, 0,0, + 0,0,0,"MS Sans Serif"); + bold_font = CreateFont(14,0,0,0,700, 0,0,0, 0,0, + 0,0,0,"MS Sans Serif"); + tiny_font = font; + load_sounds(); + + ShowWindow(mainPtr,nCmdShow); + + init_main_buttons(); + + file_initialize(); + check_colors(); + cursor_stay(); +// update_item_menu(); + + cd_init_dialogs(); + + FCD(900,0); + } + + event_handled = FALSE; + while(GetMessage(&msg,NULL,0,0)) { + if (event_handled == FALSE) { + if (!TranslateAccelerator(mainPtr, accel, &msg)) { + TranslateMessage(&msg); + DispatchMessage(&msg); + } + } + } + return msg.wParam; +} + +long CALLBACK WndProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) +{ +HDC hdc; +PAINTSTRUCT ps; +POINT press; +HMENU menu; + + switch (message) { + case WM_KEYDOWN: + if (hwnd != mainPtr) + check_cd_event(hwnd,message,wParam,lParam); + return 0; + break; + + case WM_CHAR: + if (hwnd != mainPtr) + check_cd_event(hwnd,message,wParam,lParam); + return 0; + break; + + case WM_LBUTTONDOWN: + cursor_stay(); + if (hwnd != mainPtr) + check_cd_event(hwnd,message,wParam,lParam); + else { + SetFocus(hwnd); + press = MAKEPOINT(lParam); + + All_Done = handle_action(press, wParam,lParam); + check_game_done(); + } + return 0; + break; + + + case WM_RBUTTONDOWN: + cursor_stay(); + if (hwnd != mainPtr) + check_cd_event(hwnd,message,wParam,lParam); + return 0; + break; + + case WM_ACTIVATE: + if (hwnd == mainPtr) { + if ((LOWORD(wParam) == WA_ACTIVE) ||(LOWORD(wParam) == WA_CLICKACTIVE)) { + window_in_front = TRUE; + } + if (LOWORD(wParam) == WA_INACTIVE) { + window_in_front = FALSE; + } + } + return 0; + + + case WM_MOUSEMOVE: + set_cursor(sword_curs); + return 0; + + case WM_PAINT: + hdc = BeginPaint(hwnd,&ps); + EndPaint(hwnd,&ps); + if (hwnd != mainPtr) + check_cd_event(hwnd,message,wParam,lParam); + else redraw_screen(); + return 0; + + + case WM_COMMAND: + if (hwnd == mainPtr) { + + menu = GetMenu(mainPtr); + handle_menu((short) LOWORD(wParam), menu); + check_game_done(); + } + else { + check_cd_event(hwnd,message,wParam,lParam); + } + return 0; + + + case WM_DESTROY: + case WM_CLOSE: + if (hwnd == mainPtr) { + lose_graphics(); + PostQuitMessage(0); + } + return 0; + case WM_QUIT: + if (hwnd == mainPtr){ + lose_graphics(); + PostQuitMessage(0); + } + break; + } + +return DefWindowProc(hwnd,message,wParam,lParam); +} + +void check_game_done() +{ + // through_sending(); + if (All_Done == TRUE) { + lose_graphics(); + PostQuitMessage(0); + } +} + +Boolean handle_menu (short item, HMENU) +{ + short choice,i,j,k; + Boolean to_return = FALSE; + item_record_type store_i; + + + if ((file_in_mem == FALSE) && ((item == 1) || + (item >= 40)) && (item != 200) && (item != 100)) { + display_strings(20,5,0,0,"Editing party",57,707,0); + item = -1; + } + + switch (item) { + case -1: break; + case 1: + save_file(0); + break; + case 2: + if (verify_restore_quit(1) == TRUE) + load_file(); + update_item_menu(); + break; + case 4: + All_Done = verify_restore_quit(0); + break; + + case 41: + edit_gold_or_food(0); + redraw_screen(); + + break; + case 42: + edit_gold_or_food(1); + redraw_screen(); + + break; + + case 44: + if (party.stuff_done[304][0] > 0) { + FCD(909,0); + break; + } + FCD(901,0); + leave_town(); + break; + + case 45: + if (party.stuff_done[304][0] == 0) { + FCD(911,0); + break; + } + FCD(910,0); + c_town.p_loc.x = party.stuff_done[304][1]; + c_town.p_loc.y = party.stuff_done[304][2]; + party.stuff_done[304][0] = 0; + for (i = 0; i < 6; i++) + if (adven[i].main_status >= 10) + adven[i].main_status -= 10; + redraw_screen(); + break; + + + case 48: + display_strings(20,20,0,0,"Editing party",57,707,0); + for (i = 0; i < 4; i++) + party.creature_save[i].which_town = 200; + break; + case 51: // damage + display_strings(20,1,0,0,"Editing party",57,715,0); + for (i = 0; i < 6; i++) + adven[i].cur_health = adven[i].max_health; + redraw_screen(); + break; + case 52: // spell pts + display_strings(20,2,0,0,"Editing party",57,715,0); + for (i = 0; i < 6; i++) + adven[i].cur_sp = adven[i].max_sp; + redraw_screen(); + break; + case 53: // raise dead + display_strings(20,3,0,0,"Editing party",57,715,0); + for (i = 0; i < 6; i++) + if ((adven[i].main_status == 2) || (adven[i].main_status == 3) || + (adven[i].main_status == 4)) + adven[i].main_status = 1; + redraw_screen(); + break; + case 54: // conditions + display_strings(20,4,0,0,"Editing party",57,715,0); + for (i = 0; i < 6; i++) { + adven[i].status[2] = 0; + if (adven[i].status[3] < 0) + adven[i].status[3] = 0; + adven[i].status[6] = 0; + adven[i].status[7] = 0; + adven[i].status[9] = 0; + adven[i].status[11] = 0; + adven[i].status[12] = 0; + adven[i].status[13] = 0; + } + redraw_screen(); + break; + + case 55: + if (party_in_scen == FALSE) { + display_strings(20,25,0,0,"Editing party",57,715,0); + break; + } + if (FCD(912,0) != 1) + break; + remove_party_from_scen(); + party.stuff_done[304][0] = 0; + redraw_screen(); + break; + case 62: + display_alchemy(); + break; + case 63: // all property + display_strings(20,6,0,0,"Editing party",57,707,0); + for (i = 0; i < 30; i++) { + party.boats[i].property = FALSE; + party.horses[i].property = FALSE; + } + break; + case 70: // edit day + edit_day(); + break; + case 71: // ouit maps + if (party_in_scen == FALSE) { + display_strings(20,25,0,0,"Editing party",57,715,0); + break; + } + display_strings(20,13,0,0,"Editing party",57,715,0); + for (i = 0; i < 96; i++) + for (j = 0; j < 96; j++) + out_e[i][j] = 1; + for (i = 0; i < 100; i++) + for (j = 0; j < 6; j++) + for (k = 0; k < 48; k++) + o_maps.outdoor_maps[i][j][k] = 255; + + break; + case 72: // town maps + if (party_in_scen == FALSE) { + display_strings(20,25,0,0,"Editing party",57,715,0); + break; + } + display_strings(20,14,0,0,"Editing party",57,715,0); + for (i = 0; i < 64; i++) + for (j = 0; j < 64; j++) + c_town.explored[i][j] = 1; + for (i = 0; i < 100; i++) + for (j = 0; j < 8; j++) + for (k = 0; k < 64; k++) + town_maps.town_maps[i][j][k] = 255; + for (i = 0; i < 100; i++) + for (j = 0; j < 8; j++) + for (k = 0; k < 64; k++) + town_maps2.town_maps[i][j][k] = 255; + break; + case 100: // index + WinHelp(mainPtr,"bladhelp.hlp",HELP_CONTENTS,0L); + break; + case 200: // about + FCD(1062,0); + break; + default: + item -= 600; + store_i = scen_item_list.scen_items[item]; + if(store_i.variety == 3){ + party.gold += get_ran(1,1,20); + redraw_screen(); + break; + } + if(store_i.variety == 11){ + party.food += get_ran(1,1,20); + redraw_screen(); + break; + } + give_to_pc(current_active_pc,store_i,FALSE); + draw_items(1); + break; + + } + + return to_return; +} + +void load_cursors() +{ + sword_curs = LoadCursor(store_hInstance,MAKEINTRESOURCE(120)); + + set_cursor(sword_curs); + current_cursor = 124; +} + +void set_cursor(HCURSOR which_curs) +{ + SetCursor (which_curs); +} + + +void check_colors() +{ + short a,b; + + a = GetDeviceCaps(main_dc,BITSPIXEL); + b = GetDeviceCaps(main_dc,PLANES); + if (a * b < 8) { + MessageBox(mainPtr,"The Blades of Exile Editor is designed for 256 colors. The current graphics device is set for less. Exile is playable with less colors, but will look somewhat odd." , + "Not 256 colors!",MB_OK | MB_ICONEXCLAMATION); + MessageBox(mainPtr,"For tips on how to get 256 colors, hit F1 for help, and then select 'Getting 256 Colors' from the table of contents." , + "Not 256 colors!",MB_OK | MB_ICONEXCLAMATION); + } +} + +void cursor_go() +{ + if (in_startup_mode == TRUE) + return; + if (cursor_shown == TRUE) { + cursor_shown = FALSE; + showcursor(FALSE); + } +} + +void cursor_stay() +{ + if ((cursor_shown == FALSE) || (in_startup_mode == TRUE)) { + cursor_shown = TRUE; + showcursor(TRUE); + } +} + +Boolean verify_restore_quit(short mode) +//short mode; // 0 - quit 1- restore +{ + short choice; + + if (file_in_mem == FALSE) + return TRUE; + choice = FCD(1066 + mode,0); + if (choice == 3) + return FALSE; + if (choice == 2) + return TRUE; + save_file(0); + return TRUE; +} + +void update_item_menu() +{ + short i,j; + + HMENU menu[10],big_menu; + char item_name[256]; + + big_menu = GetMenu(mainPtr); + + for (i = 0; i < 10; i++) + menu[i] = GetSubMenu(big_menu,3 + i); + for(j=0;j<10;j++){ //first let's clean the menu + DeleteMenu(menu[j],1000 + j,MF_BYCOMMAND); //If there is any dummy, flush it + for (i=0;i<40;i++) + DeleteMenu(menu[j],600+(40*j)+i,MF_BYCOMMAND); + } + for (j = 0; j < 10; j++) { //then populate it + for (i = 0; i < 40; i++) { + sprintf(item_name, "%s",scen_item_list.scen_items[i + j * 40].full_name); + if ((i % 20 == 0) && (i > 0)) + AppendMenu(menu[j],MF_MENUBREAK | MF_BYCOMMAND | MF_ENABLED | MF_STRING, 600 + (40 * j) + i, item_name); + else AppendMenu(menu[j],MF_BYCOMMAND | MF_ENABLED | MF_STRING, 600 + (40 * j) + i, item_name); + } + } +} + +void max_window(HWND window) +{ + RECT main_rect,wind_rect; + short width,height; + + cursor_shown = TRUE; + showcursor(TRUE); + + GetWindowRect(GetDesktopWindow(),&main_rect); + GetWindowRect(window,&wind_rect); + width = main_rect.right - main_rect.left; + height = main_rect.bottom - main_rect.top; + MoveWindow(window,0,0,width,height,TRUE); + +} + +void check_cd_event(HWND hwnd,UINT message,WPARAM wparam,LPARAM lparam) +{ + POINT press; + short wind_hit = -1,item_hit = -1; + + switch (message) { + case WM_COMMAND: + if (LOWORD(wparam) == 150) + break; + cd_find_dlog(hwnd,&wind_hit,&item_hit); // item_hit is dummy + item_hit = (short) LOWORD(wparam); + break; + case WM_KEYDOWN: + wind_hit = cd_process_syskeystroke(hwnd, wparam, lparam,&item_hit); + break; + + case WM_CHAR: + wind_hit = cd_process_keystroke(hwnd, wparam, lparam,&item_hit); + break; + + case WM_LBUTTONDOWN: + press = MAKEPOINT(lparam); + wind_hit = cd_process_click(hwnd,press, wparam, lparam,&item_hit); + break; + case WM_RBUTTONDOWN: + press = MAKEPOINT(lparam); + wparam = wparam | MK_CONTROL; + wind_hit = cd_process_click(hwnd,press, wparam, lparam,&item_hit); + break; + + case WM_PAINT: + cd_redraw(hwnd); + break; + } + if (wind_hit < 0) + return; + switch (wind_hit) { + case -1: break; + case 917: edit_day_event_filter(item_hit); break; + case 970: case 971: case 972: case 973: display_strings_event_filter(item_hit); break; + case 991: display_pc_event_filter(item_hit); break; + case 996: display_alchemy_event_filter(item_hit); break; + case 1010: spend_xp_event_filter (item_hit); break; + case 1012: case 947: edit_gold_or_food_event_filter (item_hit); break; + case 1013: pick_race_abil_event_filter (item_hit); break; + case 1018: select_pc_event_filter (item_hit); break; + case 1024: edit_xp_event_filter (item_hit); break; + default: fancy_choice_dialog_event_filter (item_hit); break; + } +} diff --git a/Blades of Exile Char Editor/BLADPCED.RC b/Blades of Exile Char Editor/BLADPCED.RC new file mode 100644 index 00000000..98ce75e7 --- /dev/null +++ b/Blades of Exile Char Editor/BLADPCED.RC @@ -0,0 +1,2129 @@ +/**************************************************************************** + + +EXILE.RC + +produced by Borland Resource Workshop + + +*****************************************************************************/ +#include +#define DIALOG_3 3 +#define CURSOR_1 1 +#define WAVE 100 +#define DIALOG_2 2 +#define DIALOG_1 1 +#define ACCELERATORS_1 1 +#define MENU_2 2 +#define MENU_1 1 +#define Exile 1 + +Exile MENU +{ + POPUP "&File" + { + MENUITEM "&Save Game\tCtrl+S", 1 + MENUITEM "&Open Game\tCtrl+O", 2 + MENUITEM SEPARATOR + MENUITEM "&Quit\tCtrl+Q", 4 + } + + POPUP "Free Extras" + { + MENUITEM "Edit Gold", 41 + MENUITEM "Edit Food", 42 + MENUITEM SEPARATOR + MENUITEM "Leave Town", 44 + MENUITEM "Reunite Party", 45 + MENUITEM "Make Towns Forget You", 48 + MENUITEM SEPARATOR + MENUITEM "Heal Damage", 51 + MENUITEM "Restore Spell Points", 52 + MENUITEM "Raise Dead, Destone, etc.", 53 + MENUITEM "Remove Bad Conditions", 54 + MENUITEM SEPARATOR + MENUITEM "Remove Party From Scenario", 55 + } + + POPUP "&Edit Party" + { + MENUITEM "Add Alchemy", 62 + MENUITEM "Own All Boats/Horses", 63 + MENUITEM SEPARATOR + MENUITEM "Edit Day", 70 + MENUITEM SEPARATOR + MENUITEM "Add All Outdoor Maps", 71 + MENUITEM "Add All Town Maps", 72 + } + + POPUP "&I1" + { + MENUITEM "None", 1000 + } + POPUP "&I2" + { + MENUITEM "None", 1001 + } + POPUP "&I3" + { + MENUITEM "None", 1002 + } + POPUP "&I4" + { + MENUITEM "None", 1003 + } + POPUP "&I5" + { + MENUITEM "None", 1004 + } + POPUP "&I6" + { + MENUITEM "None", 1005 + } + POPUP "&I7" + { + MENUITEM "None", 1006 + } + POPUP "&I8" + { + MENUITEM "None", 1007 + } + POPUP "&I9" + { + MENUITEM "None", 1008 + } + POPUP "&I10" + { + MENUITEM "None", 1009 + } + + POPUP "&Help" + { + MENUITEM "Index\tF1", 100 + MENUITEM SEPARATOR + MENUITEM "About Blades of Exile Editor", 200 + } + +} + +ACCELERATORS_1 ACCELERATORS +{ + + "^O", 2, ASCII + "^S", 1, ASCII + "^Q", 4, ASCII +} + +120 CURSOR "resources/sword.cur" + + +10 ICON "resources/bladexil.ico" + + +1 WAVE "resources/snd0.wav" +2 WAVE "resources/snd1.wav" +4 WAVE "resources/snd3.wav" +35 WAVE "resources/snd34.wav" +38 WAVE "resources/snd37.wav" + +STRINGTABLE +{ + 1501, "Makes you more resistant to damage. Blows of all sorts have less of an effect on you." + 1502, "The posessor of this advantage will find that his or her spell will function better. This helps both Priest and Mage spells." + 1503, "An ambidextrous warrior will be able to use one weapon in each hand without any penalties. Normally using two weapons both of them much less likely to hit." + 1504, "Having nimble fingers improves one's chance of picking locks and disarming traps." + 1505, "When underground, knowledge of Cave Lore helps one hunt and forage food and deal better with special circumstances." + 1506, "When roaming the surface of the world, a Woodsman is able to hunt and bring down food, find useful herbs, and deal with circumstances involving nature's adversity." + 1507, "Someone with a Good Constitution will find that poison and disease has a reduced (although not elimated) effect." + 1508, "Highly Alert people have the edginess that helps them resist magical sleep. In addition, having someone in your group who is Highly Alert may help keep you from being surprised." + 1509, "An Exceptionally Strong character will be able to carry much more stuff, and, in addition, will do a small amount more damage in combat." + 1510, "A very few adventurers have magical blood running in their veins, causing them to heal damage to their bodies at an amazing rate." + 1511, "Sluggish characters just can't move that quickly, even when circumstances seem to demand it. A sluggish character gets less action points in combat." + 1512, "Magically Inept characters just, for some reason, resist the effects of magical items, and are unable to use them. Potions and scolls won't work for them, although worn items, such as rings, will have a small effect." + 1513, "Frail characters are cursed at birth with a weak constitution. Poison and disease will have a greater effect on such characters." + 1514, "Chronic Disease is the worst disadvantage a character may posess. Such characters have a slow, lingering, incurable physical ailment, causing them to occasionally suffer the effects of a mild disease." + 1515, "A character with a Bad Back cannot bear to haul too much weight. Such a person cannot carry as much as he or she might have been able to otherwise." + 1516, "Human is the default species in Blades of Exile. Humans have skins of a variety of hues, and are soft, generally fragile, and incredibly resourceful." + 1517, "The Nephilim are a race of feline humanoids. Once common on the surface world, they have been hunted to near extinction, although some now remain in Exile. Nephilim characters start with better dexterity, and are much better at using missile weapons." + 1518, "The Slithzerikai (sliths for short) are a race of lizard men, both strong and smart. Once unknown on the surface world, they are starting to appear there. Slith characters get bonuses to strength and intelligence, and are better at using pole weapons." + 1519, "Exile III Prefs" + 2101, "Light" + 2102, "Creates a weak light." + 2103, "Spark" + 2104, "Fires a weak bolt of electricity at an enemy." + 2105, "Minor Haste" + 2106, "Makes the selected PC move faster for a while. All haste spells take effect at the beginning of the next round." + 2107, "Strength" + 2108, "Makes the selected PC more skilled for a short time. Works like the priest spell ïBless.Í" + 2109, "Scare" + 2110, "Decreases the morale of the victim. Casting this on a weak foe will make the foe flee. Even if the monster doesn't flee, later castings have a higher chance of success." + 2111, "Flame Cloud" + 2112, "This spell fills the selected space with a short-lasting wall of fire." + 2113, "Identify" + 2114, "This draining spell identifies all the unidentified items being held by your characters." + 2115, "Scry Monster" + 2116, "This spell is cast during combat. When cast, you receive information about the monster you target: current health, spell points, morale, etc." + 2117, "Goo" + 2118, "This spell covers the target with sticky goo, slowing it down and interfering with its attacks." + 2119, "True Sight" + 2120, "This spell lets you see everything in a short radius around you, even spaces blocked off by walls. It's useful for finding secret passages, for example." + 2121, "Minor Poison" + 2122, "Poisons the target creature. This does a fair amount of damage, but it takes time to happen." + 2123, "Flame" + 2124, "Fires a decent-sized bolt of flame at the target. The damage done increases with the level of the caster." + 2125, "Slow" + 2126, "Makes the victim get half its usual number of actions for a while." + 2127, "Dumbfound" + 2128, "Makes the victim incompetent: easier to hit, easier to damage, and less able to attack you." + 2129, "Envenom" + 2130, "This spell puts poison on the weapon of the selected PC, with no chance of failure or accidental poisoning." + 2131, "Stinking Cloud" + 2132, "When cast, a 3x3 area you select becomes filled with choking gasses. Anyone entering will have far less effective attacks for a short time. The gas will slowly fade on its own." + 2133, "Summon Beast" + 2134, "This spell summons one low-level non-magical monster to fight on your side. It disappears after a short time." + 2135, "Conflagration" + 2136, "This spell makes the air in a radius 2 circle burst into flames, charring anyone inside the cloud. After creation, the cloud will rapidly fade." + 2137, "Dispel Fields" + 2138, "This spell dispels magical fields in the selected area. It removes blade walls, ice walls, and similar fields. Note, however, that the spell doesn't work on Fire and Force Barriers." + 2139, "Sleep Cloud" + 2140, "This spell creates a small cloud of sleep gas. There is a chance that anyone passing through the cloud will fall asleep (note that some creatures, like slimes, never sleep)." + 2141, "Unlock Doors" + 2142, "Some doors are magically locked, and others are just hard to open. This spell can unlock them. However, it isnÍt guaranteed to succeed, and wonÍt work on all doors." + 2143, "Haste" + 2144, "Makes the selected PC get twice the usual number of actions for a long time. All haste spells take effect at the beginning of the next round." + 2145, "Fireball" + 2146, "Fires a powerful ball of flame, which affects the target space and every space adjacent. The damage done increases with the level of the caster." + 2147, "Long Light" + 2148, "Like the first level light spell, but much more effective." + 2149, "Fear" + 2150, "Like scare, but much more powerful. " + 2151, "Wall of Force" + 2152, "This powerful spell creates a line of force walls, which are like fire walls but more damaging and lasting. Hitting space while targeting makes the wall rotate." + 2153, "Weak Summoning" + 2154, "When cast, a group of monsters appears and attacks all enemies of the caster. The number of monsters depends on the level of the caster. After a time, they disappear." + 2155, "Flame Arrows" + 2156, "This spell is like flame, but the caster gets to select several targets. The number of missiles increases with the level of the caster. If you don't want to use all the missiles, hit space to cast the spell." + 2157, "Web" + 2158, "This spell covers a large circle with icky webs, slowing down everyone inside. The webs last until torn down." + 2159, "Resist Magic" + 2160, "You can cast this spell on another PC to make him/her resistant to magical damage and effects. Note this does not help against damage from fire and cold." + 2161, "Poison" + 2162, "This makes poison run thick in the veins of the target. Repeated castings will have a devastating effect." + 2163, "Ice Bolt" + 2164, "Slams the target with a heavy, pointed bolt of ice. Effective against monsters who are resistant to fire. Damage increases as level of caster increases." + 2165, "Slow Group" + 2166, "Makes all monsters within a 12 space radius move at half speed for a time." + 2167, "Magic Map" + 2168, "When cast in town, this powerful spell gives you a vision - Your map will show you the entire area. However, to cast this spell you need a sapphire." + 2169, "Capture Soul" + 2170, "This spell stores a target monster in a Soul Crystal, so that it may later be created with the Simulacrum spell. You need a Soul Crystal to cast this." + 2171, "Simulacrum" + 2172, "This spell summons a monster you select from your Soul Crystal. The cost depends on the level of the monster being summoned." + 2173, "Venom Arrows" + 2174, "This spell is similar to Flame Arrows, except that your targets are poisoned." + 2175, "Wall of Ice" + 2176, "This spell is similar to Wall of Force, except that it creates an ice wall. Ice walls do as much damage as force walls, but last a lot longer." + 2177, "Stealth" + 2178, "This powerful spell makes monsters less likely to see you for a time (duration depends on your level). Try casting it before walking through a room crowded with monsters." + 2179, "Major Haste" + 2180, "Gives the entire party double its actions (duration depends on the level of the caster). All haste spells take effect at the beginning of the next round." + 2181, "Fire Storm" + 2182, "This spell is like fireball, but does more damage, and affects all creatures within two spaces of the space you target. Be careful not to fry your party!" + 2183, "Dispel Barrier" + 2184, "This spell has a chance (increasing with level) of destroying magical barriers. Some barriers are harder to dispel than others; some cannot be dispelled. Some barriers can be\twalked through." + 2185, "Fire Barrier" + 2186, "This spell creates a single fire barrier at the target space. Fire barriers are damaging and permanent." + 2187, "Summoning" + 2188, "This spell is like Minor Summoning, but summons more powerful monsters." + 2189, "Shockstorm" + 2190, "This spell creates a large sphere of force walls." + 2191, "Spray Fields" + 2192, "This spell creates a large number of small fields of a random sort, each of which may be individually targeted. The number of fields increases with the level of the caster." + 2193, "Major Poison" + 2194, "This spell makes the targeted monster very poisoned. This spell does a huge amount of damage, but it takes time to take effect." + 2195, "Group Fear" + 2196, "When cast, the caster begins to radiate a horrible aura of fear. All monsters within 12 spaces lose a lot of morale. This spell gains effectiveness rapidly with the level of the caster." + 2197, "Kill" + 2198, "The deadly Kill spell deals a devastating blow to one target you select." + 2199, "Paralyze" + 2200, "This spell affects several monsters - the number affected increases with your level and intelligence. Whoever you cast this on will be immobilized for a very long time. Powerful monsters might resist this spell." + 2201, "Daemon" + 2202, "This dangerous spell summons a beast from the netherworld to fight at your side." + 2203, "Antimagic Cloud" + 2204, "This spell created a spherical field, from which no spells may be cast and in which no spells may be targeted. After creation, it slowly fades." + 2205, "Mindduel" + 2206, "When cast on a magic using enemy, the two creatures get in a mental battle, absorbing spell points from each other. The loser may end up dumbfounded or killed. Requires Smoky Crystal to cast." + 2207, "Flight" + 2208, "When cast outdoors, the party can fly for a short time." + 2209, "Shockwave" + 2210, "This spell sends a wave of force out from the caster, damaging \teveryone nearby. The farther someone is from the caster, the more damage is taken, out to a radius of 10. DonÍt cast in towns." + 2211, "Major Blessing" + 2212, "When cast, the entire party is blessed and hasted, and has their weapons\tmildly poisoned." + 2213, "Mass Paralysis" + 2214, "When cast, every monsters within a small radius of the caster will become paralyzed for quite some time. There is a chance they might resist the spell." + 2215, "Protection" + 2216, "One of the most powerful spells in the mageÍs repertoire. It makes the whole party temporarily magic resistant, and makes one PC you select immune to ALL damage for a short time." + 2217, "Major Summoning" + 2218, "This spell works like Summoning, but brings forth much more powerful creatures." + 2219, "Force Barrier" + 2220, "This spell creates an impenetrable, permanent barrier. Be careful not to trap yourself." + 2221, "Quickfire" + 2222, "Devastating beyond words, this spell creates a space of quickfire, which will sweep over the area killing everyone and everything." + 2223, "Death Arrows" + 2224, "This spell is like the previous Arrow spells, but strikes each target with a kill spell. The number of arrows increases with the level of the caster." + 2401, "Minor Bless" + 2402, "Makes the character harder to hit and take less damage from blows. It\talso makes the PC hit more often, and his or her blows do more damage. Its effects decay with time." + 2403, "Minor Heal" + 2404, "Increases the health of the selected PC a small amount, up to the PCs\tmaximum health." + 2405, "Weaken Poison" + 2406, "Reduces the amount of poison running around in the veins of the\tselected PC." + 2407, "Turn Undead" + 2408, "When cast on an undead creature, it usually does a reasonable\tamount of damage to it. It has no effect on non-undead." + 2409, "Location" + 2410, "Returns the partyÍs x-y location in the town." + 2411, "Sanctuary" + 2412, "The target of this spell becomes magically shielded. For a time, monsters probably won't be able to attack him/her. The effects disappears when the PC attacks someone." + 2413, "Symbiosis" + 2414, "This spell has the caster absorb the damage taken by another character. The higher the level, the less damage the caster takes per health point healed." + 2415, "Minor Manna" + 2416, "Casting this spell gives the party a little more food." + 2417, "Ritual - Sanctify" + 2418, "When cast on a location filled with evil magic, the location receives a blessing. This might drive out the evil magic. Then again, it might not." + 2419, "Stumble" + 2420, "The victim of this spell moves slower and has worse attacks for a short time." + 2421, "Bless" + 2422, "Like Minor Bless, but better. Its effect increases with the level of the caster." + 2423, "Cure Poison" + 2424, "Like Weaken Poison, but better. Its effect increases with the level of the caster." + 2425, "Curse" + 2426, "The opposite of bless. It makes everything much worse for the victim, for a time. Hitting someone with this spell several times vastly increases the effect." + 2427, "Light" + 2428, "Creates a short duration magical light source." + 2429, "Wound" + 2430, "Deals a painful blow to the targeted victim. The damage increases\twith your level." + 2431, "Summon Spirit" + 2432, "This spell summons a shade from the netherworld to aid you. It will disappear after a short time." + 2433, "Move Mountains" + 2434, "When cast on a fragile wall or outcropping of rock, the wall or outcropping crumbles into rubble. It doesn't work on all walls." + 2435, "Charm Foe" + 2436, "This spell has a chance of making the target monster start to fight for the party. The chance of it working drops sharply with the level of the monster." + 2437, "Disease" + 2438, "The victim of this spell is afflicted by a disease, which slowly weakens it. The disease lasts a long time." + 2439, "Awaken" + 2440, "Casting this on a sleeping character instantly wakes that character up." + 2441, "Heal" + 2442, "A much better version of Minor Heal." + 2443, "Light Heal All" + 2444, "Casts one minor heal on each PC." + 2445, "Holy Scourge" + 2446, "This spell gives the victim a powerful curse, the effect of which increases with the level of the caster." + 2447, "Detect Life" + 2448, "This spell causes all other living things to appear on your map for a short time. Note, however, that this spell only detects creatures in areas you have explored." + 2449, "Cure Paralysis" + 2450, "This spell instantly removes the effects of paralysis." + 2451, "Manna" + 2452, "This spell magically creates a lot of food for the party." + 2453, "Forcefield" + 2454, "This spell fills an area with walls of force, which are fairly damaging and reasonably long lasting." + 2455, "Cure Disease" + 2456, "Casting this spell on a PC cures all his/her disease." + 2457, "Restore Mind" + 2458, "This spell completely unfeebleminds the recipient." + 2459, "Smite" + 2460, "This spell fires a number of bolts of divinely inspired cold, the number of which increases with the level of the caster. To cast without using all the target, hit space." + 2461, "Cure All Poison" + 2462, "Causes everyone to become less poisoned. Useful for dealing with those nasty swamps." + 2463, "Curse All" + 2464, "Causes all monsters within ten spaces to receive a powerful curse." + 2465, "Dispel Undead" + 2466, "Deals a deadly blow to the targeted undead nasty. Chance of having\teffect increases with level." + 2467, "Remove Curse" + 2468, "Occasionally, you will put on an item which then refuses to be taken off. Casting this spell has a chance of removing the curse." + 2469, "Sticks to Snakes" + 2470, "This spell summons a bunch of snakes to aid the party. Skillful casters have a chance of getting asps instead of the weaker giant snakes." + 2471, "Martyr's Shield" + 2472, "When something strikes the recipient of this spell in hand-to-hand combat, it takes as much damage as the victim. The duration of this spell increases with the level of the caster." + 2473, "Cleanse" + 2474, "This spell purifies the recipient. The beneficiary is completely unwebbed, and all disease is cured." + 2475, "Firewalk" + 2476, "When cast, for a short time everyone in the party can walk across lava with no damage. The duration increases slowly with the level of the caster." + 2477, "Bless Party" + 2478, "Much like Bless, but affects everyone." + 2479, "Major Heal" + 2480, "Works like the Heal spell, but gives much more bang for the spell points." + 2481, "Raise Dead" + 2482, "This spell returns a body to life. You need Resurrection Balm to cast this. There is a small chance (decreasing with level) that it turns the body to dust. A dusted character can only be raised with a Resurrect spell. Raising a PC reduces his/her stats." + 2483, "Flamestrike" + 2484, "The first area of affect offensive priest spell. It chars all beings adjacent\tto the space you target. The damage done increases with level." + 2485, "Mass Sanctuary" + 2486, "This spell hides all PCs (like a sanctuary spell). As before, the effect for a PC is voided when that PC attacks." + 2487, "Summon Host" + 2488, "This powerful spell summons four spirits, and a magical being to lead them. They then fight on the side of the caster for a little while. " + 2489, "Shatter" + 2490, "This spell strikes every space adjacent to the party with a Move Mountains spell." + 2491, "Dispel Fields" + 2492, "All magical walls, etc. in the large area affected by this spell will be dispelled. It has a small chance of affecting quickfire." + 2493, "Heal All" + 2494, "Like the Heal spell, but affects the whole party. Very efficient." + 2495, "Revive" + 2496, "This spell heals all damage and cures all poison for one PC." + 2497, "Hyperactivity" + 2498, "This powerful instantly wakes up any sleeping characters in the party. What's more, it provides total resistance to magical sleep for a short time. Finally, it speeds back up any slowed character." + 2499, "Destone" + 2500, "Certain rare monsters can turn one of your characters to stone. This valuable spell undoes the damage." + 2501, "Summon Guardian" + 2502, "This spell summons a powerful, invisible being to fight on the side of the party. Be careful not to damage it by mistake!" + 2503, "Mass Charm" + 2504, "When cast, all creatures within eight spaces of the caster have a chance of coming under his/her control." + 2505, "Protective Circle" + 2506, "A very unusual and effective spell for a party on the defensive. The caster is surrounded by several layers of magical fields, which fend off anyone attacking." + 2507, "Pestilence" + 2508, "This spell afflicts everyone within eight spaces with an effective but slow-acting disease." + 2509, "Revive All" + 2510, "When cast, the party receives a powerful healing (increasing with level of\tthe caster) and has poison cured as well." + 2511, "Ravage Spirit" + 2512, "Demons are resistant to most magic. This spell gives them a blow which usually does a lot of damage.\tThe chance of success increases with the level of the caster." + 2513, "Resurrect" + 2514, "Like raise dead, but much more effective, and works on even a dusted\tcharacter. It also has a smaller chance of lowering the character's stats. It still requires Resurrection Balm to cast." + 2515, "Divine Thud" + 2516, "The most powerful offensive priest spell. It delivers a stunning blow of force to all beings within two spaces of the targeted space." + 2517, "Avatar" + 2518, "This spell temporarily makes the caster an invulnerable, incredibly powerful avatar of the gods. " + 2519, "Wall of Blades" + 2520, "This spell creates a wall of the most damaging (and long lasting) of the magic walls. Rotate the wall by hitting space." + 2521, "Word of Recall" + 2522, "This spell returns the party to Fort Emergence, where you began the game. Because of the danger of teleporting from narrow, windy tunnels, it can only be cast outdoors." + 2523, "Major Cleansing" + 2524, "This spell removes all webs and disease from the party." + 2701, "Strength" + 2702, "Measures how much brute strength the character possesses. High strength increases damage done in combat, improves odds of kicking down doors, and has other, more subtle effects." + 2703, "Dexterity" + 2704, "Measure how nimble the character is. High dexterity gives a better chance of hitting in combat (esp. with missile weapons) and makes the character harder to hit. High dexterity also makes picking locks and disarming traps easier." + 2705, "Intelligence" + 2706, "Measures mental strength and dexterity. High intelligence also makes your spells more effective, sometimes very much so. Intelligence below 4 makes your spells works poorly." + 2707, "Edged Weapons" + 2708, "Makes you better at using daggers, swords, axes, etc." + 2709, "Bashing Weap." + 2710, "Makes you better at using clubs, maces, hammers, flails, etc." + 2711, "Pole Weapons" + 2712, "Makes you better at using spears of all sorts, halberds, etc." + 2713, "Thrown Missiles" + 2714, "Makes you better at using darts, javelins, and throwing axes." + 2715, "Archery" + 2716, "Makes you better at using a bow and arrows." + 2717, "Defense" + 2718, "This skill has three effects. It determines how well a character does at parrying, decreases the penalty in combat from bulky armor, and occasionally decreases the damage taken from enemies weapons.|" + 2719, "Mage Spells" + 2720, "Having a certain level of this skill enables you to cast mage spells of up to that level." + 2721, "Priest Spells" + 2722, "Having a certain level of this skill enables you to cast priest spells of up to that level." + 2723, "Mage Lore" + 2724, "You will occasionally need to decipher strange magical readings. This skill determines how good you are at this. If your skill is high enough, you may gain a spell or a valuable piece of information." + 2725, "Alchemy" + 2726, "You will eventually gain the ability to make magic potions. To make a given potion, however, your Alchemy skill much be above a certain level. The higher it is above this level, the better the chance of succeeding." + 2727, "Item Lore" + 2728, "Having Item Lore skill gives you a chance of having the items from slain monsters be identified when you find them. The more of this skill that is present, the higher the chance of this happening." + 2729, "Disarm Traps" + 2730, "Many chests and some corridors will have traps on them, which can be devastating. The higher this skill, the better your chance of disarming them." + 2731, "Lockpicking" + 2732, "Many towns and dungeons will have locked doors. A PC with some of this skill and lock picks equipped can try to pick them. The higher this skill, the better." + 2733, "Assassination" + 2734, "Sometimes, when a character attacks a much weaker monster, the blow will do a good deal of extra damage. The more of this skill you have, the better the chance of this happening, and the stronger the monsters it can happen to." + 2735, "Poison" + 2736, "You will find poisons, which you can put on your weapons for a extra damage. Having a few levels in this skill will make it more likely you will put the poison on at full strength, and the less likely you will nick yourself with the poison accidentally." + 2737, "Luck" + 2738, "This skill is expensive, but can be a bargain at twice the cost. Its effects are pervasive, subtle, powerful, and sometimes irreplaceable." + 6001, "All of your character's damage has now been healed. Dead characters are still dead." + 6002, "All of your characters (even dead ones) now have their maximum number of spell points." + 6003, "All of your characters who were dead (or dust, or stoned) are now alive and intact. You may wish to select Heal Party now." + 6004, "All negative conditions (poison, dumbfounding, disease, paralysis, etc.) have been removed from your characters (even dead ones)." + 6005, "Before you can do this, you need to load in a Blades of Exile save file. Select Open from the file menu." + 6006, "All boats and horses are now your property." + 6007, "Any major NPCs you may have slain, such as Erika or the dragons, are now alive again. You should now use the Leave Town and then Reset Towns menu items to make sure the characters appear." + 6008, "You are now considered a member of the Anama church. You can no longer cast Mage spells. To get the full effect of this, add Anama Rings above." + 6009, "If you own Erika Amulets, they are now active. To get the full effect of this, add Erika Amulets above." + 6010, "If a job dispatcher is angry at you for making a late delivery, he/she has just forgiven you." + 6011, "If you belong to the Anama, you are no longer a member. If you robbed the Anama temple in Shayder, the people there will no longer attack you on sight." + 6012, "If you slew the vampire Vahkohs but did not destroy the crystal containing his soul, he is now totally dead and will torment you no longer." + 6013, "Your party now has the complete maps for the outdoors of your current scenario." + 6014, "Your party now has the complete maps for the towns in your current scenario." + 6015, "Your party now has the complete maps for outdoors southern Valorim. If your Save Maps preference is not set, this will have no effect." + 6016, "Your party now has the complete maps for large (64x64) dungeons, and for Valorim's 5 large cities. If your Save Maps preference is not set, this will have no effect." + 6017, "Your party now has the complete maps for medium (64x64) dungeons, and for medium size cities. If your Save Maps preference is not set, this will have no effect." + 6018, "Your party now has the complete maps for small (32x32) dungeons, and for small huts, etc. across the Valorim countryside. If your Save Maps preference is not set, this will have no effect." + 6019, "Your party now has the complete maps for the small towns dotting the Valorim countryside. If your Save Maps preference is not set, this will have no effect." + 6020, "Your save file no longer contains information on the towns you've visited. Monsters have reappeared, angry guards have forgotten you, etc. Note, if you are in town now, the game will still remember what happened in this town." + 6021, "The Tower of Magi timer is not currently running, so this will have no effect." + 6022, "You now have a bit more time before the Tower of Magi timer runs out. This time can be used to accumulate potions, train, and do other things to help you survive. Note that the Tower of Magi messages will eventually repeat themselves." + 6023, "If your characters became addicted to Skribbane herb, the addiction is now cured." + 6024, "You are now able to see all dungeons and towns, whether or not someone has told you about them." + 6025, "You can only use this feature if the current party is in a scenario." +} + + +901 DIALOG 10, 10, 332, 74 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 252, 48, 58, 20 + LTEXT "5_708" 2, 8, 8, 36, 36 + LTEXT "Your party will now be outdoors.|Things you have done in the town will not be remembered." 3, 52, 3, 257, 44 + } + +907 DIALOG 10, 10, 400, 142 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_65" 1, 299, 113, 58, 20 + LTEXT "0_64" 2, 231, 113, 58, 20 + LTEXT "5_708" 3, 9, 9, 36, 36 + LTEXT "This option moves your party to just outside Fort Emergence, where you started. Be careful that you aren't getting yourself stuck in doing this, by, for example, leaving a boat in a place where you can't get back to it." 4, 51, 4, 305, 66 + LTEXT "Saving a backup copy of the save file before using this option is recommended. Are you sure you want to do this?" 5, 51, 71, 306, 40 + } + +908 DIALOG 10, 10, 328, 70 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 255, 37, 58, 20 + LTEXT "5_708" 2, 8, 8, 36, 36 + LTEXT "You cannot use this option while the party is indoors, in a boat, or on a horse." 3, 52, 3, 261, 32 + } + +909 DIALOG 10, 10, 328, 72 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 251, 49, 58, 20 + LTEXT "5_708" 2, 8, 8, 36, 36 + LTEXT "You cannot use this option while the party is split up. Select Reunite party from this menu." 3, 52, 3, 256, 44 + } + +910 DIALOG 10, 10, 344, 110 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 261, 86, 58, 20 + LTEXT "5_708" 2, 8, 8, 36, 36 + LTEXT "Your party is now reunited. You are located where you were when you split up. Warning - doing this can trap your party if you didn't do something you needed to do while split up. Be sure to back up your save file before saving this change." 3, 52, 3, 266, 80 + } + +911 DIALOG 10, 10, 316, 48 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 246, 25, 58, 20 + LTEXT "5_708" 2, 8, 8, 36, 36 + LTEXT "Your party is not split up!" 3, 52, 3, 252, 16 + } + +912 DIALOG 10, 10, 400, 142 +STYLE WS_POPUP | WS_DLGFRAME +{ + LTEXT "1_64", 1, 299, 105, 58, 20 + LTEXT "0_65", 2, 231, 105, 58, 20 + LTEXT "5_708", 3, 9, 9, 36, 36 + LTEXT "Selecting this option removes your party from the scenario they're currently in. All of their progress in that adventure is forgotten ... if you want to play it again, you will need to start over from the very beginning. Are you sure you want to do this?", 4, 51, 4, 305, 84 +} + +915 DIALOG 10, 10, 336, 110 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_65" 1, 246, 88, 58, 20 + LTEXT "0_64" 2, 178, 88, 58, 20 + LTEXT "5_708" 3, 9, 9, 36, 36 + LTEXT "This will reset all boats and horses to their original positions. Whether you own them or not will remain unchanged. Be careful when using this that you don't strand yourself on an island somewhere! Go ahead?" 4, 51, 4, 253, 82 + } + +916 DIALOG 10, 10, 567, 391 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "5_707" 1, 6, 6, 36, 36 + LTEXT "2_0" 2, 132, 61, 14, 10 + LTEXT "2_0" 3, 132, 73, 14, 10 + LTEXT "2_0" 4, 132, 85, 14, 10 + LTEXT "2_0" 5, 132, 97, 14, 10 + LTEXT "2_0" 6, 132, 109, 14, 10 + LTEXT "2_0" 7, 132, 121, 14, 10 + LTEXT "2_0" 8, 132, 133, 14, 10 + LTEXT "2_0" 9, 132, 145, 14, 10 + LTEXT "2_0" 10, 132, 157, 14, 10 + LTEXT "2_0" 11, 132, 169, 14, 10 + LTEXT "2_0" 12, 132, 181, 14, 10 + LTEXT "2_0" 13, 132, 193, 14, 10 + LTEXT "2_0" 14, 132, 205, 14, 10 + LTEXT "2_0" 15, 261, 61, 14, 10 + LTEXT "2_0" 16, 261, 73, 14, 10 + LTEXT "2_0" 17, 261, 85, 14, 10 + LTEXT "2_0" 18, 261, 97, 14, 10 + LTEXT "2_0" 19, 261, 109, 14, 10 + LTEXT "2_0" 20, 261, 121, 14, 10 + LTEXT "2_0" 21, 261, 133, 14, 10 + LTEXT "2_0" 22, 261, 145, 14, 10 + LTEXT "2_0" 23, 261, 157, 14, 10 + LTEXT "2_0" 24, 261, 169, 14, 10 + LTEXT "2_0" 25, 261, 181, 14, 10 + LTEXT "2_0" 26, 261, 193, 14, 10 + LTEXT "2_0" 27, 261, 205, 14, 10 + LTEXT "2_0" 28, 396, 61, 14, 10 + LTEXT "2_0" 29, 396, 73, 14, 10 + LTEXT "2_0" 30, 396, 85, 14, 10 + LTEXT "2_0" 31, 396, 97, 14, 10 + LTEXT "2_0" 32, 396, 109, 14, 10 + LTEXT "2_0" 33, 396, 121, 14, 10 + LTEXT "2_0" 34, 396, 133, 14, 10 + LTEXT "2_0" 35, 396, 145, 14, 10 + LTEXT "2_0" 36, 396, 157, 14, 10 + LTEXT "2_0" 37, 396, 169, 14, 10 + LTEXT "2_0" 38, 396, 181, 14, 10 + LTEXT "2_0" 39, 396, 193, 14, 10 + LTEXT "2_0" 40, 396, 205, 14, 10 + LTEXT "2_0" 41, 531, 61, 14, 10 + LTEXT "2_0" 42, 531, 73, 14, 10 + LTEXT "2_0" 43, 531, 85, 14, 10 + LTEXT "2_0" 44, 531, 97, 14, 10 + LTEXT "2_0" 45, 531, 109, 14, 10 + LTEXT "2_0" 46, 531, 121, 14, 10 + LTEXT "2_0" 47, 531, 133, 14, 10 + LTEXT "1_0" 48, 470, 356, 63, 23 + LTEXT "~Edit Special Items/Traits" 49, 53, 15, 256, 15 + LTEXT "*Special Items:" 50, 53, 37, 105, 16 + LTEXT "*Other Special Traits:" 51, 11, 222, 200, 15 + LTEXT "0_106" 52, 13, 239, 25, 23 + LTEXT "*Raise special NPCs from dead." 53, 40, 243, 180, 15 + LTEXT "0_106" 54, 13, 263, 25, 23 + LTEXT "*Be member of Anama church." 55, 40, 267, 180, 15 + LTEXT "0_106" 56, 13, 287, 25, 23 + LTEXT "*Activate Erika amulets." 57, 40, 291, 180, 15 + LTEXT "0_106" 58, 13, 311, 25, 23 + LTEXT "*Make job dispatchers forgive you" 59, 40, 315, 180, 15 + LTEXT "0_106" 60, 13, 335, 25, 23 + LTEXT "*Reset Shayder, quit Anama." 61, 40, 339, 180, 15 + LTEXT "0_106" 62, 13, 359, 25, 23 + LTEXT "*End curse of Vahkohs" 63, 40, 363, 180, 15 + LTEXT "*Add maps:" 64, 240, 222, 146, 15 + LTEXT "2_0" 65, 386, 241, 14, 10 + LTEXT "2_0" 66, 386, 253, 14, 10 + LTEXT "2_0" 67, 386, 265, 14, 10 + LTEXT "2_0" 68, 386, 277, 14, 10 + LTEXT "2_0" 69, 386, 289, 14, 10 + LTEXT "2_0" 70, 386, 301, 14, 10 + LTEXT "2_0" 71, 386, 313, 14, 10 + LTEXT "0_106" 72, 234, 335, 25, 23 + LTEXT "*Cure Skribbane addiction." 73, 261, 339, 180, 15 + LTEXT "0_106" 74, 234, 359, 25, 23 + LTEXT "*Make all dungeons visible." 75, 261, 363, 180, 15 + } + +917 DIALOG 10, 10, 352, 172 +STYLE WS_POPUP | WS_DLGFRAME +{ + LTEXT "6_0", 2, 133, 36, 99, 26 + LTEXT "5_702", 3, 8, 8, 36, 36 + LTEXT "~What day would you like it to be?", 4, 49, 8, 255, 16 + LTEXT "1_63", 5, 243, 153, 75, 16 + LTEXT "Warning: Changing the day can have dramatically unexpected effects. Towns will reappear. People will be shifted around. The time limits on your jobs may expire. Back up your save file before doing this.", 6, 51, 72, 268, 79 +} + +947 DIALOG 10, 10, 282, 97 +STYLE WS_POPUP | WS_DLGFRAME +{ + LTEXT "6_0", 2, 133, 36, 91, 26 + LTEXT "5_702", 3, 8, 8, 36, 36 + LTEXT "~How much food do you want?", 4, 49, 8, 209, 17 + LTEXT "1_63", 5, 184, 74, 75, 16 +} + +948 DIALOG 10, 10, 352, 260 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_81" 1, 268, 233, 66, 20 + LTEXT "0_82" 2, 193, 233, 65, 20 + LTEXT "0_83" 3, 118, 233, 66, 20 + LTEXT "5_716" 4, 10, 9, 36, 36 + LTEXT "At long last, victory is yours. The plague of monsters has been ended, and the Exiles can one again see the light of the sun. The bizarre and tormented odyssey of the people of Exile may finally be drawing to a close." 5, 58, 6, 276, 78 + LTEXT "But surely not everything has been done! What of the plight of the people of Marish? The five artifact quests? The many small dungeons out in the wilderness? Perhaps your adventuring days are not yet done." 6, 58, 86, 276, 77 + LTEXT "But then, perhaps they are. If so, thank you very much for playing Exile III: Ruined World, and I hope you try Spiderweb Software's next production. Until then, happy hunting!" 7, 58, 164, 276, 67 + } + +949 DIALOG 10, 10, 326, 132 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 243, 106, 58, 20 + LTEXT "5_723" 2, 6, 6, 36, 36 + LTEXT "For some reason, the game was unable to open the files 'Exile III Towns' or 'Exile III Outdoors'. Quit Exile III, make sure these files are in the Exile III folder and run it again, and it should work. If not, contact Spiderweb Software." 3, 50, 6, 252, 98 + } + +950 DIALOG 10, 10, 306, 298 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 232, 276, 58, 20 + LTEXT "5_721" 2, 6, 6, 36, 36 + LTEXT "Map of Krizsan Province:" 3, 50, 6, 241, 17 + LTEXT "5_3600" 4, 50, 28, 240, 240 + } + +951 DIALOG 10, 10, 300, 296 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 232, 276, 58, 20 + LTEXT "5_721" 2, 6, 6, 36, 36 + LTEXT "Map of Upper Exile:" 3, 50, 6, 241, 17 + LTEXT "5_3601" 4, 50, 28, 240, 240 + } + +952 DIALOG 10, 10, 312, 302 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 232, 276, 58, 20 + LTEXT "5_721" 2, 6, 6, 36, 36 + LTEXT "Map of the Isle of Bigail:" 3, 50, 6, 241, 17 + LTEXT "5_3602" 4, 50, 28, 240, 240 + } + +953 DIALOG 10, 10, 312, 302 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 232, 276, 58, 20 + LTEXT "5_721" 2, 6, 6, 36, 36 + LTEXT "Map of Karnold Province:" 3, 50, 6, 241, 17 + LTEXT "5_3603" 4, 50, 28, 240, 240 + } + +954 DIALOG 10, 10, 312, 302 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 232, 276, 58, 20 + LTEXT "5_721" 2, 6, 6, 36, 36 + LTEXT "Map to Black Halberd:" 3, 50, 6, 241, 17 + LTEXT "5_3604" 4, 50, 28, 240, 240 + } + +955 DIALOG 10, 10, 330, 298 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 232, 276, 58, 20 + LTEXT "5_721" 2, 6, 6, 36, 36 + LTEXT "Map of Midori Province" 3, 50, 6, 241, 17 + LTEXT "5_3605" 4, 50, 28, 240, 240 + } + +956 DIALOG 10, 10, 330, 298 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 232, 276, 58, 20 + LTEXT "5_721" 2, 6, 6, 36, 36 + LTEXT "Map of Footracer Province" 3, 50, 6, 241, 17 + LTEXT "5_3606" 4, 50, 28, 240, 240 + } + +957 DIALOG 10, 10, 330, 298 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 232, 276, 58, 20 + LTEXT "5_721" 2, 6, 6, 36, 36 + LTEXT "Map of Monoroe Province" 3, 50, 6, 241, 17 + LTEXT "5_3607" 4, 50, 28, 240, 240 + } + +958 DIALOG 10, 10, 345, 189 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_0" 1, 242, 158, 70, 20 + LTEXT "5_708" 2, 9, 9, 36, 36 + LTEXT "= " 3, 53, 37, 257, 92 + LTEXT "~Tip of the Day:" 4, 53, 9, 257, 19 + LTEXT "0_103" 5, 54, 158, 70, 20 + LTEXT "*See tips upon startup:" 6, 53, 138, 136, 16 + LTEXT "2_0" 7, 192, 141, 28, 16 + } + +959 DIALOG 10, 10, 546, 343 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_0" 1, 426, 305, 70, 20 + LTEXT "5_708" 2, 9, 9, 36, 36 + LTEXT "~THE JOB BOARD:" 3, 53, 9, 161, 19 + LTEXT "= " 4, 54, 38, 364, 60 + LTEXT "0_51" 5, 426, 78, 70, 20 + LTEXT "= " 6, 54, 104, 364, 60 + LTEXT "0_51" 7, 426, 144, 70, 20 + LTEXT "= " 8, 54, 170, 364, 60 + LTEXT "0_51" 9, 426, 210, 70, 20 + LTEXT "= " 10, 54, 236, 364, 60 + LTEXT "0_51" 11, 426, 276, 70, 20 + LTEXT "Current day:" 12, 230, 9, 92, 19 + LTEXT "*" 13, 324, 9, 92, 19 + LTEXT " " 14, 19, 313, 183, 18 + } + +960 DIALOG 10, 10, 377, 322 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_0" 1, 250, 285, 70, 20 + LTEXT "5_708" 2, 9, 9, 36, 36 + LTEXT "= " 3, 53, 82, 257, 92 + LTEXT "~Conversation Journal:" 4, 53, 9, 257, 19 + LTEXT "= " 5, 53, 181, 257, 92 + LTEXT "*Speaking with:" 6, 53, 36, 105, 16 + LTEXT "+" 7, 165, 36, 146, 16 + LTEXT "*Located in:" 8, 53, 59, 105, 16 + LTEXT "+" 9, 165, 59, 146, 16 + LTEXT "0_2" 10, 39, 285, 63, 23 + LTEXT "0_3" 11, 102, 285, 63, 23 + LTEXT "0_53" 12, 173, 285, 70, 20 + } + +961 DIALOG 10, 10, 423, 375 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_0" 1, 319, 341, 70, 20 + LTEXT "5_708" 2, 9, 9, 36, 36 + LTEXT "= " 3, 53, 37, 257, 92 + LTEXT "= " 4, 53, 136, 257, 92 + LTEXT "= " 5, 53, 235, 257, 92 + LTEXT "~Encounter Notes:" 6, 53, 9, 257, 19 + LTEXT "0_2" 7, 48, 340, 63, 23 + LTEXT "0_3" 8, 111, 340, 63, 23 + LTEXT "0_53" 9, 319, 109, 70, 20 + LTEXT "0_53" 10, 319, 208, 70, 20 + LTEXT "0_53" 11, 319, 307, 70, 20 + } + +962 DIALOG 10, 10, 437, 371 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_0" 1, 319, 341, 70, 20 + LTEXT "5_708" 2, 9, 9, 36, 36 + LTEXT "= " 3, 121, 37, 257, 92 + LTEXT "= " 4, 121, 136, 257, 92 + LTEXT "= " 5, 121, 235, 257, 92 + LTEXT "~Journal of your Travels:" 6, 53, 9, 257, 19 + LTEXT "0_2" 7, 48, 340, 63, 23 + LTEXT "0_3" 8, 111, 340, 63, 23 + LTEXT "*" 9, 52, 37, 55, 15 + LTEXT "*" 10, 52, 136, 55, 15 + LTEXT "*" 11, 52, 234, 55, 15 + } + +970 DIALOG 10, 10, 346, 167 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_0" 1, 251, 107, 70, 20 + LTEXT "0_68" 2, 8, 107, 70, 20 + LTEXT "5_708" 3, 9, 9, 36, 36 + LTEXT "= " 4, 55, 8, 257, 90 + } + +971 DIALOG 10, 10, 347, 240 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_0" 1, 248, 212, 70, 20 + LTEXT "0_68" 2, 6, 212, 70, 20 + LTEXT "5_708" 3, 9, 9, 36, 36 + LTEXT "= " 4, 55, 8, 257, 91 + LTEXT "= " 5, 55, 107, 257, 98 + } + +972 DIALOG 10, 10, 350, 164 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_0" 1, 247, 140, 70, 20 + LTEXT "0_68" 2, 8, 140, 70, 20 + LTEXT "5_708" 3, 9, 9, 36, 36 + LTEXT "= " 4, 53, 38, 257, 92 + LTEXT "*" 5, 26, 74, 14, 19 + LTEXT "+" 6, 53, 9, 257, 19 + } + +973 DIALOG 10, 10, 347, 264 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_0" 1, 253, 238, 70, 20 + LTEXT "0_68" 2, 9, 238, 70, 20 + LTEXT "5_708" 3, 9, 9, 36, 36 + LTEXT "= " 4, 55, 39, 257, 87 + LTEXT "= " 5, 55, 136, 257, 93 + LTEXT "+" 6, 55, 9, 257, 19 + } + +986 DIALOG 10, 10, 491, 374 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "0_63" 1, 395, 334, 65, 20 + LTEXT "5_716" 2, 6, 6, 36, 36 + LTEXT "Welcome to the wonderful world of Exile III! Exile III is a true epic, with an intricate plot, a world that changes as events progress, and an amazing variety of paths your characters can take." 3, 50, 22, 413, 49 + LTEXT "Exile III, like most games of its type, is fairly complicated. Fortunately, there are plenty of places to look for help should you get confused. Be sure to read the file _Exile III Instructions/Order Form_ which comes with the game." 4, 50, 72, 411, 58 + LTEXT "This file contains not only complete instructions for playing and ordering the game, but a quick guide to getting started and a mini-hint book for the first few quests." 5, 50, 131, 411, 44 + LTEXT "Also be sure to look at the Preferences Window (in the Options menu). It can make the game faster, slower, and even easier, change the display, and remove the special effects." 6, 50, 176, 413, 44 + LTEXT "Rest assured, if you get stuck, there's plenty of stuff available to help you out. So on with the game, have fun, and watch your back!" 7, 50, 287, 410, 43 + LTEXT "Finally, alas, the Macintosh world nowadays is rife with extension conflicts and other problems. If you experience crashes playing Exile III, there is troubleshooting info in the file _READ ME - Game and ASP Info_." 8, 50, 221, 411, 65 + LTEXT "WELCOME TO EXILE III: RUINED WORLD!" 9, 136, 4, 265, 16 + LTEXT "THIS IS A BETA COPY! DO NOT DISTRIBUTE! IF YOU ARE NOT AUTHORIZED TO HAVE THIS, PLEASE DELETE IT NOW!" 10, 3, 333, 381, 30 + } + +987 DIALOG 10, 10, 433, 441 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_0" 1, 337, 408, 63, 23 + LTEXT "5_702" 2, 10, 10, 36, 36 + LTEXT "0_35" 3, 89, 354, 23, 23 + LTEXT "0_36" 4, 174, 354, 23, 23 + LTEXT "0_37" 5, 259, 354, 23, 23 + LTEXT "0_38" 6, 89, 397, 23, 23 + LTEXT "0_39" 7, 174, 397, 23, 23 + LTEXT "0_40" 8, 259, 397, 23, 23 + LTEXT "0_27" 9, 342, 5, 58, 20 + LTEXT "0_28" 10, 342, 346, 58, 20 + LTEXT "5_0" 11, 123, 348, 28, 36 + LTEXT "5_0" 12, 208, 348, 28, 36 + LTEXT "5_0" 13, 293, 348, 28, 36 + LTEXT "5_0" 14, 123, 393, 28, 36 + LTEXT "5_0" 15, 208, 393, 28, 36 + LTEXT "5_0" 16, 293, 393, 28, 36 + LTEXT "~You Find:" 17, 64, 6, 199, 18 + LTEXT "+" 18, 73, 31, 327, 309 + LTEXT "8_0" 19, 80, 37, 311, 36 + LTEXT "5_0" 20, 80, 37, 28, 36 + LTEXT "*" 21, 107, 37, 212, 18 + LTEXT "*" 22, 116, 55, 275, 17 + LTEXT "8_0" 23, 80, 74, 311, 36 + LTEXT "5_0" 24, 80, 74, 28, 36 + LTEXT "*" 25, 107, 74, 212, 18 + LTEXT "*" 26, 116, 92, 275, 18 + LTEXT "8_0" 27, 80, 111, 311, 36 + LTEXT "5_0" 28, 80, 111, 28, 36 + LTEXT "*" 29, 107, 111, 212, 18 + LTEXT "*" 30, 116, 129, 275, 18 + LTEXT "8_0" 31, 80, 148, 311, 36 + LTEXT "5_0" 32, 80, 148, 28, 36 + LTEXT "*" 33, 107, 148, 212, 18 + LTEXT "*" 34, 116, 166, 275, 18 + LTEXT "8_0" 35, 80, 185, 311, 36 + LTEXT "5_0" 36, 80, 185, 28, 36 + LTEXT "*" 37, 107, 185, 212, 18 + LTEXT "*" 38, 116, 203, 275, 18 + LTEXT "8_0" 39, 80, 222, 311, 36 + LTEXT "5_0" 40, 80, 222, 28, 36 + LTEXT "*" 41, 107, 222, 212, 18 + LTEXT "*" 42, 116, 240, 275, 18 + LTEXT "8_0" 43, 80, 259, 311, 37 + LTEXT "5_0" 44, 80, 259, 28, 36 + LTEXT "*" 45, 107, 259, 212, 18 + LTEXT "*" 46, 116, 277, 275, 18 + LTEXT "8_0" 47, 80, 297, 311, 36 + LTEXT "5_0" 48, 80, 297, 28, 36 + LTEXT "*" 49, 107, 297, 212, 18 + LTEXT "*" 50, 116, 315, 275, 18 + LTEXT "=Keyboard: To get item, hit 'a' - 'h'. To scroll, hit up and down arrows." 51, 1, 203, 64, 125 + LTEXT "=" 52, 1, 347, 66, 79 + LTEXT "*" 53, 319, 37, 72, 18 + LTEXT "*" 54, 319, 74, 72, 18 + LTEXT "*" 55, 319, 111, 72, 18 + LTEXT "*" 56, 319, 148, 72, 18 + LTEXT "*" 57, 319, 185, 72, 18 + LTEXT "*" 58, 319, 222, 72, 18 + LTEXT "*" 59, 319, 259, 72, 18 + LTEXT "*" 60, 319, 297, 72, 18 + } + +988 DIALOG 10, 10, 330, 174 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_5" 1, 238, 145, 58, 20 + LTEXT "0_35" 2, 50, 50, 24, 20 + LTEXT "+(spot empty)" 3, 83, 52, 172, 16 + LTEXT "+" 4, 262, 52, 31, 16 + LTEXT "0_36" 5, 50, 72, 24, 20 + LTEXT "+(spot empty)" 6, 83, 74, 172, 16 + LTEXT "+" 7, 262, 74, 31, 16 + LTEXT "0_37" 8, 50, 94, 24, 20 + LTEXT "+(spot empty)" 9, 83, 96, 172, 16 + LTEXT "+" 10, 262, 96, 31, 16 + LTEXT "0_38" 11, 50, 116, 24, 20 + LTEXT "+(spot empty)" 12, 83, 118, 172, 16 + LTEXT "+" 13, 262, 118, 31, 16 + LTEXT "~Select monster to summon:" 14, 50, 6, 251, 16 + LTEXT "5_713" 15, 6, 6, 36, 36 + LTEXT "~# Monster Cost" 16, 50, 28, 244, 16 + } + +989 DIALOG 10, 10, 545, 347 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_0" 1, 455, 320, 58, 20 + LTEXT "~Create/Edit Party:" 2, 50, 16, 205, 16 + LTEXT "*Click PC name to rename." 3, 9, 324, 181, 15 + LTEXT "5_707" 4, 6, 6, 36, 36 + LTEXT "8_1" 5, 93, 62, 152, 16 + LTEXT "0_96" 6, 258, 50, 58, 20 + LTEXT "0_95" 7, 324, 50, 58, 20 + LTEXT "0_31" 8, 390, 50, 58, 20 + LTEXT "~PC #1" 9, 42, 63, 40, 16 + LTEXT "8_1" 10, 93, 107, 152, 16 + LTEXT "0_96" 11, 258, 95, 58, 20 + LTEXT "0_95" 12, 324, 95, 58, 20 + LTEXT "0_31" 13, 390, 95, 58, 20 + LTEXT "~PC #2" 14, 42, 108, 40, 16 + LTEXT "8_1" 15, 93, 152, 152, 16 + LTEXT "0_96" 16, 258, 140, 58, 20 + LTEXT "0_95" 17, 324, 140, 58, 20 + LTEXT "0_31" 18, 390, 140, 58, 20 + LTEXT "~PC #3" 19, 42, 153, 40, 16 + LTEXT "8_1" 20, 93, 197, 152, 16 + LTEXT "0_96" 21, 258, 185, 58, 20 + LTEXT "0_95" 22, 324, 185, 58, 20 + LTEXT "0_31" 23, 390, 185, 58, 20 + LTEXT "~PC #4" 24, 42, 198, 40, 16 + LTEXT "8_1" 25, 93, 242, 152, 16 + LTEXT "0_96" 26, 258, 230, 58, 20 + LTEXT "0_95" 27, 324, 230, 58, 20 + LTEXT "0_31" 28, 390, 230, 58, 20 + LTEXT "~PC #5" 29, 42, 243, 40, 16 + LTEXT "8_1" 30, 93, 287, 152, 16 + LTEXT "0_96" 31, 258, 275, 58, 20 + LTEXT "0_95" 32, 324, 275, 58, 20 + LTEXT "0_31" 33, 390, 275, 58, 20 + LTEXT "~PC #6" 34, 42, 288, 40, 16 + LTEXT "0_97" 35, 455, 50, 58, 20 + LTEXT "0_97" 36, 455, 95, 58, 20 + LTEXT "0_97" 37, 455, 140, 58, 20 + LTEXT "0_97" 38, 455, 185, 58, 20 + LTEXT "0_97" 39, 455, 230, 58, 20 + LTEXT "0_97" 40, 455, 275, 58, 20 + LTEXT "0_67" 41, 498, 4, 21, 16 + LTEXT "5_0" 42, 12, 52, 28, 36 + LTEXT "5_0" 43, 12, 97, 28, 36 + LTEXT "5_0" 44, 12, 142, 28, 36 + LTEXT "5_0" 45, 12, 187, 28, 36 + LTEXT "5_0" 46, 12, 232, 28, 36 + LTEXT "5_0" 47, 12, 277, 28, 36 + } + +991 DIALOG 10, 10, 514, 338 +STYLE WS_POPUP | WS_DLGFRAME +{ + LTEXT "5_714", 2, 6, 6, 36, 36 + LTEXT "2_0", 3, 102, 57, 14, 10 + LTEXT "2_0", 4, 102, 69, 14, 10 + LTEXT "2_0", 5, 102, 81, 14, 10 + LTEXT "2_0", 6, 102, 93, 14, 10 + LTEXT "2_0", 7, 102, 105, 14, 10 + LTEXT "2_0", 8, 102, 117, 14, 10 + LTEXT "2_0", 9, 102, 129, 14, 10 + LTEXT "2_0", 10, 102, 141, 14, 10 + LTEXT "2_0", 11, 102, 153, 14, 10 + LTEXT "2_0", 12, 102, 165, 14, 10 + LTEXT "2_0", 13, 220, 57, 14, 10 + LTEXT "2_0", 14, 220, 69, 14, 10 + LTEXT "2_0", 15, 220, 81, 14, 10 + LTEXT "2_0", 16, 220, 93, 14, 10 + LTEXT "2_0", 17, 220, 105, 14, 10 + LTEXT "2_0", 18, 220, 117, 14, 10 + LTEXT "2_0", 19, 220, 129, 14, 10 + LTEXT "2_0", 20, 220, 141, 14, 10 + LTEXT "2_0", 21, 220, 153, 14, 10 + LTEXT "2_0", 22, 220, 165, 14, 10 + LTEXT "2_0", 23, 338, 57, 14, 10 + LTEXT "2_0", 24, 338, 69, 14, 10 + LTEXT "2_0", 25, 338, 81, 14, 10 + LTEXT "2_0", 26, 338, 93, 14, 10 + LTEXT "2_0", 27, 338, 105, 14, 10 + LTEXT "2_0", 28, 338, 117, 14, 10 + LTEXT "2_0", 29, 338, 129, 14, 10 + LTEXT "2_0", 30, 338, 141, 14, 10 + LTEXT "2_0", 31, 338, 153, 14, 10 + LTEXT "2_0", 32, 338, 165, 14, 10 + LTEXT "2_0", 33, 456, 57, 14, 10 + LTEXT "2_0", 34, 456, 69, 14, 10 + LTEXT "2_0", 35, 456, 81, 14, 10 + LTEXT "2_0", 36, 456, 93, 14, 10 + LTEXT "2_0", 37, 456, 105, 14, 10 + LTEXT "2_0", 38, 456, 117, 14, 10 + LTEXT "2_0", 39, 456, 129, 14, 10 + LTEXT "2_0", 40, 456, 141, 14, 10 + LTEXT "2_0", 41, 102, 188, 14, 10 + LTEXT "2_0", 42, 102, 200, 14, 10 + LTEXT "2_0", 43, 102, 212, 14, 10 + LTEXT "2_0", 44, 102, 224, 14, 10 + LTEXT "2_0", 45, 102, 236, 14, 10 + LTEXT "2_0", 46, 102, 248, 14, 10 + LTEXT "2_0", 47, 102, 260, 14, 10 + LTEXT "2_0", 48, 102, 272, 14, 10 + LTEXT "2_0", 49, 220, 188, 14, 10 + LTEXT "2_0", 50, 220, 200, 14, 10 + LTEXT "2_0", 51, 220, 212, 14, 10 + LTEXT "2_0", 52, 220, 224, 14, 10 + LTEXT "2_0", 53, 220, 236, 14, 10 + LTEXT "2_0", 54, 220, 248, 14, 10 + LTEXT "2_0", 55, 220, 260, 14, 10 + LTEXT "2_0", 56, 220, 272, 14, 10 + LTEXT "2_0", 57, 338, 188, 14, 10 + LTEXT "2_0", 58, 338, 200, 14, 10 + LTEXT "2_0", 59, 338, 212, 14, 10 + LTEXT "2_0", 60, 338, 224, 14, 10 + LTEXT "2_0", 61, 338, 236, 14, 10 + LTEXT "2_0", 62, 338, 248, 14, 10 + LTEXT "2_0", 63, 338, 260, 14, 10 + LTEXT "2_0", 64, 338, 272, 14, 10 + LTEXT "1_0", 65, 422, 310, 63, 23 + LTEXT "0_2", 66, 12, 310, 63, 23 + LTEXT "0_3", 67, 79, 310, 64, 23 + LTEXT "~Spells For:", 68, 53, 15, 83, 16 + LTEXT "+", 69, 146, 15, 186, 16 +} + +993 DIALOG 10, 10, 362, 65 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_60" 1, 271, 36, 58, 20 + LTEXT "0_59" 2, 161, 36, 75, 20 + LTEXT "0_58" 3, 50, 36, 75, 20 + LTEXT "This door is locked. What do you do?" 4, 50, 8, 252, 19 + LTEXT "5_112" 5, 8, 8, 28, 36 + } + +996 DIALOG 10, 10, 461, 206 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "~Alchemy known:" 1, 54, 10, 163, 15 + LTEXT "5_720" 2, 6, 6, 36, 36 + LTEXT "1_0" 3, 356, 174, 63, 23 + LTEXT "2_0" 4, 217, 33, 14, 10 + LTEXT "2_0" 5, 217, 47, 14, 10 + LTEXT "2_0" 6, 217, 61, 14, 10 + LTEXT "2_0" 7, 217, 75, 14, 10 + LTEXT "2_0" 8, 217, 89, 14, 10 + LTEXT "2_0" 9, 217, 103, 14, 10 + LTEXT "2_0" 10, 217, 117, 14, 10 + LTEXT "2_0" 11, 217, 131, 14, 10 + LTEXT "2_0" 12, 217, 145, 14, 10 + LTEXT "2_0" 13, 217, 159, 14, 10 + LTEXT "2_0" 14, 402, 33, 14, 10 + LTEXT "2_0" 15, 402, 47, 14, 10 + LTEXT "2_0" 16, 402, 61, 14, 10 + LTEXT "2_0" 17, 402, 75, 14, 10 + LTEXT "2_0" 18, 402, 89, 14, 10 + LTEXT "2_0" 19, 402, 103, 14, 10 + LTEXT "2_0" 20, 402, 117, 14, 10 + LTEXT "2_0" 21, 402, 131, 14, 10 + LTEXT "2_0" 22, 402, 145, 14, 10 + LTEXT "2_0" 23, 402, 159, 14, 10 + LTEXT "Number in ( ) is minimum skill to make." 24, 8, 179, 199, 16 + } +997 DIALOG 10, 10, 296, 234 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "5_724" 2, 6, 6, 36, 36 + LTEXT "1_0" 3, 199, 202, 63, 23 + LTEXT "0_2" 4, 55, 202, 63, 23 + LTEXT "0_3" 5, 124, 202, 63, 23 + LTEXT "7_0" 6, 55, 17, 179, 16 + LTEXT "=" 7, 17, 55, 238, 129 + } + +998 DIALOG 10, 10, 330, 327 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "5_0" 1, 8, 9, 28, 36 + LTEXT "~Item Info:" 2, 45, 6, 102, 16 + LTEXT "+" 3, 101, 33, 141, 16 + LTEXT "+" 4, 58, 61, 141, 16 + LTEXT "+" 5, 245, 61, 47, 16 + LTEXT "+" 6, 58, 89, 25, 15 + LTEXT "+" 7, 146, 89, 25, 15 + LTEXT "+" 8, 231, 89, 25, 15 + LTEXT "+" 9, 65, 117, 25, 16 + LTEXT "+" 10, 138, 118, 26, 16 + LTEXT "+" 11, 255, 118, 25, 16 + LTEXT "+" 12, 61, 168, 230, 16 + LTEXT "1_0" 13, 232, 307, 63, 23 + LTEXT "0_2" 14, 88, 307, 63, 23 + LTEXT "0_3" 15, 157, 307, 63, 23 + LTEXT "2_0" 16, 213, 8, 14, 10 + LTEXT "2_0" 17, 280, 8, 14, 10 + LTEXT "~Description:" 18, 8, 192, 102, 16 + LTEXT "=" 19, 8, 210, 286, 87 + LTEXT "+" 20, 60, 142, 44, 15 + } + +999 DIALOG 10, 10, 345, 332 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "~Immunities:" 1, 21, 187, 137, 16 + LTEXT "~Monster Info:" 2, 54, 7, 106, 16 + LTEXT "1_0" 3, 249, 297, 63, 23 + LTEXT "5_0" 4, 12, 8, 28, 36 + LTEXT "" 5, 104, 32, 195, 16 + LTEXT "" 6, 53, 59, 25, 16 + LTEXT "" 7, 134, 59, 47, 16 + LTEXT "" 8, 258, 59, 47, 16 + LTEXT "" 9, 57, 85, 25, 16 + LTEXT "" 10, 127, 85, 25, 16 + LTEXT "" 11, 205, 85, 32, 16 + LTEXT "" 12, 280, 85, 25, 16 + LTEXT "" 13, 63, 111, 44, 16 + LTEXT "" 14, 160, 111, 44, 16 + LTEXT "" 15, 261, 111, 44, 16 + LTEXT "" 16, 78, 137, 25, 17 + LTEXT "" 17, 188, 137, 25, 17 + LTEXT "" 18, 280, 137, 25, 17 + LTEXT "" 19, 67, 165, 238, 16 + LTEXT "2_0" 20, 118, 205, 14, 10 + LTEXT "2_0" 21, 118, 220, 14, 10 + LTEXT "2_0" 22, 118, 235, 14, 10 + LTEXT "2_0" 23, 118, 250, 14, 10 + LTEXT "2_0" 24, 241, 205, 14, 10 + LTEXT "2_0" 25, 241, 220, 14, 10 + LTEXT "2_0" 26, 241, 235, 14, 10 + LTEXT "2_0" 27, 241, 250, 14, 10 + LTEXT "0_2" 28, 11, 297, 63, 23 + LTEXT "0_3" 29, 74, 297, 63, 23 + LTEXT "*(To make monsters appear in roster menu, cast Scry Monster on them.)" 30, 10, 266, 305, 28 + } + +1010 DIALOG 10, 10, 570, 391 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "~Main statistics:" 1, 38, 99, 133, 17 + LTEXT "~Training For:" 2, 56, 8, 110, 16 + LTEXT "0_7" 3, 231, 53, 23, 20 + LTEXT "0_6" 4, 256, 53, 23, 20 + LTEXT "0_7" 5, 231, 75, 23, 20 + LTEXT "0_6" 6, 256, 75, 23, 20 + LTEXT "0_7" 7, 231, 119, 23, 20 + LTEXT "0_6" 8, 256, 119, 23, 20 + LTEXT "0_7" 9, 231, 141, 23, 20 + LTEXT "0_6" 10, 256, 141, 23, 20 + LTEXT "0_7" 11, 231, 163, 23, 20 + LTEXT "0_6" 12, 256, 163, 23, 20 + LTEXT "0_7" 13, 231, 204, 23, 20 + LTEXT "0_6" 14, 256, 204, 23, 20 + LTEXT "0_7" 15, 231, 226, 23, 20 + LTEXT "0_6" 16, 256, 226, 23, 20 + LTEXT "0_7" 17, 231, 248, 23, 20 + LTEXT "0_6" 18, 256, 248, 23, 20 + LTEXT "0_7" 19, 231, 270, 23, 20 + LTEXT "0_6" 20, 256, 270, 23, 20 + LTEXT "0_7" 21, 231, 292, 23, 20 + LTEXT "0_6" 22, 256, 292, 23, 20 + LTEXT "0_7" 23, 231, 314, 23, 20 + LTEXT "0_6" 24, 256, 314, 23, 20 + LTEXT "0_7" 25, 472, 74, 23, 20 + LTEXT "0_6" 26, 497, 74, 23, 20 + LTEXT "0_7" 27, 472, 96, 23, 20 + LTEXT "0_6" 28, 497, 96, 23, 20 + LTEXT "0_7" 29, 472, 118, 23, 20 + LTEXT "0_6" 30, 497, 118, 23, 20 + LTEXT "0_7" 31, 472, 140, 23, 20 + LTEXT "0_6" 32, 497, 140, 23, 20 + LTEXT "0_7" 33, 472, 162, 23, 20 + LTEXT "0_6" 34, 497, 162, 23, 20 + LTEXT "0_7" 35, 472, 206, 23, 20 + LTEXT "0_6" 36, 497, 206, 23, 20 + LTEXT "0_7" 37, 472, 228, 23, 20 + LTEXT "0_6" 38, 497, 228, 23, 20 + LTEXT "0_7" 39, 472, 250, 23, 20 + LTEXT "0_6" 40, 497, 250, 23, 20 + LTEXT "0_7" 41, 472, 272, 23, 20 + LTEXT "0_6" 42, 497, 272, 23, 20 + LTEXT "0_7" 43, 472, 294, 23, 20 + LTEXT "0_6" 44, 497, 294, 23, 20 + LTEXT "5_707" 45, 6, 7, 36, 36 + LTEXT "" 46, 148, 344, 75, 16 + LTEXT "" 47, 300, 344, 75, 16 + LTEXT "0_4" 48, 403, 355, 63, 25 + LTEXT "0_2" 49, 403, 329, 63, 23 + LTEXT "0_3" 50, 470, 329, 63, 23 + LTEXT "" 51, 177, 8, 166, 16 + LTEXT "" 52, 194, 56, 28, 15 + LTEXT "" 53, 194, 77, 28, 15 + LTEXT "" 54, 194, 121, 28, 15 + LTEXT "" 55, 194, 143, 28, 15 + LTEXT "" 56, 194, 165, 28, 15 + LTEXT "" 57, 194, 207, 28, 15 + LTEXT "" 58, 194, 229, 28, 15 + LTEXT "" 59, 194, 251, 28, 15 + LTEXT "" 60, 194, 272, 28, 15 + LTEXT "" 61, 194, 294, 28, 15 + LTEXT "" 62, 194, 316, 28, 15 + LTEXT "" 63, 435, 76, 28, 15 + LTEXT "" 64, 435, 98, 29, 15 + LTEXT "" 65, 435, 121, 29, 15 + LTEXT "" 66, 435, 142, 29, 15 + LTEXT "" 67, 435, 164, 29, 15 + LTEXT "" 68, 434, 208, 29, 15 + LTEXT "" 69, 434, 230, 29, 15 + LTEXT "" 70, 434, 252, 29, 15 + LTEXT "" 71, 434, 274, 29, 15 + LTEXT "" 72, 434, 296, 29, 15 + LTEXT "1_5" 73, 470, 355, 63, 25 + LTEXT "~Skill: Cost: Level:" 74, 56, 32, 228, 16 + LTEXT "~Skill: Cost: Level:" 75, 292, 32, 228, 16 + LTEXT "~Warrior Skills:" 76, 38, 185, 133, 17 + LTEXT "~Magic Skills:" 77, 292, 53, 133, 17 + LTEXT "~Other Skills:" 78, 292, 185, 133, 17 + LTEXT "*Cost: (Skill pts./Gold) " 79, 6, 365, 382, 16 + LTEXT "*Skill Pts.:" 80, 71, 344, 68, 16 + LTEXT "*Gold:" 81, 252, 344, 42, 16 + } + +1011 DIALOG 10, 10, 328, 78 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_9" 1, 236, 48, 58, 20 + LTEXT "0_61" 2, 168, 48, 58, 20 + LTEXT "5_412" 3, 6, 6, 36, 36 + LTEXT "This item is clearly someone's property. Do you steal it?" 4, 48, 6, 246, 35 + } + +1012 DIALOG 10, 10, 290, 94 +STYLE WS_POPUP | WS_DLGFRAME +{ + LTEXT "6_0", 2, 133, 36, 75, 24 + LTEXT "5_702", 3, 8, 8, 36, 36 + LTEXT "~How much gold do you want?", 4, 49, 8, 209, 17 + LTEXT "1_63", 5, 184, 74, 75, 16 +} + +1013 DIALOG 10, 10, 525, 379 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "~Special Characteristics:" 1, 55, 9, 181, 16 + LTEXT "5_707" 2, 6, 6, 36, 36 + LTEXT "1_0" 3, 423, 349, 63, 23 + LTEXT "2_0" 4, 161, 55, 14, 10 + LTEXT "2_0" 5, 289, 55, 14, 10 + LTEXT "2_0" 6, 447, 55, 14, 11 + LTEXT "2_0" 7, 215, 97, 14, 10 + LTEXT "2_0" 8, 215, 112, 14, 10 + LTEXT "2_0" 9, 215, 127, 14, 10 + LTEXT "2_0" 10, 215, 142, 14, 10 + LTEXT "2_0" 11, 215, 157, 14, 10 + LTEXT "2_0" 12, 416, 97, 14, 10 + LTEXT "2_0" 13, 416, 112, 14, 10 + LTEXT "2_0" 14, 416, 127, 14, 10 + LTEXT "2_0" 15, 416, 142, 14, 10 + LTEXT "2_0" 16, 416, 157, 14, 10 + LTEXT "~Species:" 17, 55, 30, 65, 18 + LTEXT "" 18, 254, 352, 50, 16 + LTEXT "=Select species and traits." 19, 15, 282, 469, 59 + LTEXT "*Human (%0)" 20, 55, 53, 75, 15 + LTEXT "*Nephilim (%12)" 21, 186, 53, 75, 15 + LTEXT "*Slithzerikai (%20)" 22, 316, 53, 92, 15 + LTEXT "*Toughness (%10)" 23, 55, 95, 75, 15 + LTEXT "*Magically Apt. (%20)" 24, 55, 110, 75, 15 + LTEXT "*Ambidextrous (%8)" 25, 55, 125, 116, 15 + LTEXT "*Nimble Fingers (%10)" 26, 55, 140, 75, 15 + LTEXT "*Cave Lore (%4)" 27, 55, 155, 75, 15 + LTEXT "*Woodsman (%6)" 28, 236, 95, 126, 15 + LTEXT "*Sluggish (%-10) " 29, 55, 197, 116, 15 + LTEXT "*Magically Inept (%-8) " 30, 55, 212, 75, 15 + LTEXT "*Frail (%-8) " 31, 55, 227, 75, 15 + LTEXT "*Chronic Disease (%-20) " 32, 55, 242, 126, 15 + LTEXT "Experience needed to gain each level:" 33, 19, 352, 216, 16 + LTEXT "~Advantages" 34, 55, 74, 75, 16 + LTEXT "~Disadvantages" 35, 55, 178, 75, 16 + LTEXT "2_0" 36, 237, 198, 14, 10 + LTEXT "2_0" 37, 237, 213, 14, 10 + LTEXT "2_0" 38, 237, 228, 14, 10 + LTEXT "2_0" 39, 237, 243, 14, 10 + LTEXT "2_0" 40, 237, 258, 14, 10 + LTEXT "*Good Constitution (%10)" 41, 236, 110, 126, 15 + LTEXT "*Highly Alert (%7)" 42, 236, 125, 126, 15 + LTEXT "*Exceptional Strength (%12)" 43, 236, 140, 126, 15 + LTEXT "*Recuperation (%15)" 44, 236, 155, 126, 15 + LTEXT "*Bad Back (%-8) " 45, 55, 257, 126, 15 + LTEXT "Number in () is how much having that trait affects the experience you need to gain a level." 46, 289, 223, 204, 43 + } + +1014 DIALOG 10, 10, 355, 124 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_0" 1, 260, 93, 63, 23 + LTEXT "=Fred" 2, 47, 9, 273, 77 + LTEXT "5_0" 3, 9, 10, 28, 36 + } + +1017 DIALOG 10, 10, 243, 86 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "6_0" 2, 88, 34, 75, 16 + LTEXT "~Ask about what?" 3, 55, 6, 141, 16 + LTEXT "5_708" 4, 8, 8, 36, 36 + LTEXT "1_63" 5, 146, 62, 75, 16 + } + +1018 DIALOG 10, 10, 311, 220 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "*Hit a button or type '1'-'6'." 1, 11, 190, 184, 18 + LTEXT "5_706" 2, 8, 8, 36, 36 + LTEXT "0_11" 3, 69, 31, 58, 20 + LTEXT "0_12" 4, 69, 56, 58, 20 + LTEXT "0_13" 5, 69, 81, 58, 20 + LTEXT "0_14" 6, 69, 106, 58, 20 + LTEXT "0_15" 7, 69, 131, 58, 20 + LTEXT "0_16" 8, 69, 156, 58, 20 + LTEXT "+" 9, 138, 35, 139, 16 + LTEXT "+" 10, 138, 60, 139, 16 + LTEXT "+ " 11, 138, 85, 139, 16 + LTEXT "+" 12, 138, 110, 139, 16 + LTEXT "+" 13, 138, 135, 139, 16 + LTEXT "+" 14, 138, 160, 139, 16 + LTEXT "~Select a PC:" 15, 49, 10, 228, 16 + LTEXT "1_5" 16, 214, 187, 63, 25 + } + +1019 DIALOG 10, 10, 512, 372 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_0" 1, 418, 339, 58, 20 + LTEXT "0_2" 2, 289, 339, 58, 20 + LTEXT "0_3" 3, 352, 339, 58, 20 + LTEXT "0_75" 4, 144, 310, 106, 20 + LTEXT "0_76" 5, 257, 310, 106, 20 + LTEXT "0_77" 6, 370, 310, 106, 20 + LTEXT "5_0" 7, 9, 10, 28, 36 + LTEXT "~Info on:" 8, 48, 6, 75, 16 + LTEXT "~" 9, 127, 6, 174, 16 + LTEXT "~Level:" 10, 48, 29, 53, 16 + LTEXT "~" 11, 103, 29, 29, 16 + LTEXT "~Experience:" 12, 134, 29, 78, 16 + LTEXT "~" 13, 215, 29, 38, 16 + LTEXT "~Next level:" 14, 258, 29, 78, 16 + LTEXT "~" 15, 339, 29, 38, 16 + LTEXT "~Statistics:" 16, 10, 51, 95, 16 + LTEXT "*" 17, 24, 70, 92, 16 + LTEXT "*" 18, 119, 70, 38, 16 + LTEXT "*" 19, 24, 88, 92, 16 + LTEXT "*" 20, 119, 88, 38, 16 + LTEXT "*" 21, 24, 106, 92, 16 + LTEXT "*" 22, 119, 106, 38, 16 + LTEXT "*" 23, 24, 129, 92, 16 + LTEXT "*" 24, 119, 129, 38, 16 + LTEXT "*" 25, 24, 147, 92, 16 + LTEXT "*" 26, 119, 147, 38, 16 + LTEXT "*" 27, 24, 165, 92, 16 + LTEXT "*" 28, 119, 165, 38, 16 + LTEXT "*" 29, 24, 183, 92, 16 + LTEXT "*" 30, 119, 183, 38, 16 + LTEXT "*" 31, 24, 201, 92, 16 + LTEXT "*" 32, 119, 201, 38, 16 + LTEXT "*" 33, 24, 219, 92, 16 + LTEXT "*" 34, 119, 219, 38, 16 + LTEXT "*" 35, 171, 70, 92, 16 + LTEXT "*" 36, 266, 70, 38, 16 + LTEXT "*" 37, 171, 88, 92, 16 + LTEXT "*" 38, 266, 88, 38, 16 + LTEXT "*" 39, 171, 106, 92, 16 + LTEXT "*" 40, 266, 106, 38, 16 + LTEXT "*" 41, 171, 124, 92, 16 + LTEXT "*" 42, 266, 124, 38, 16 + LTEXT "*" 43, 171, 142, 92, 16 + LTEXT "*" 44, 266, 142, 38, 16 + LTEXT "*" 45, 171, 165, 92, 16 + LTEXT "*" 46, 266, 165, 38, 16 + LTEXT "*" 47, 171, 183, 92, 16 + LTEXT "*" 48, 266, 183, 38, 16 + LTEXT "*" 49, 171, 201, 92, 16 + LTEXT "*" 50, 266, 201, 38, 16 + LTEXT "*" 51, 171, 219, 92, 16 + LTEXT "*" 52, 266, 219, 38, 16 + LTEXT "*" 53, 24, 242, 92, 16 + LTEXT "*" 54, 119, 242, 38, 16 + LTEXT "*Weapon 1:" 55, 314, 131, 75, 16 + LTEXT "*" 56, 325, 150, 155, 18 + LTEXT "*" 57, 325, 170, 155, 18 + LTEXT "*Weapon 2:" 58, 315, 191, 75, 16 + LTEXT "*" 59, 326, 210, 154, 18 + LTEXT "*" 60, 326, 230, 154, 18 + LTEXT "~Total encumbrance:" 61, 11, 265, 139, 17 + LTEXT "*" 62, 156, 265, 38, 16 + LTEXT "Defense skill reduces this during combat." 63, 199, 265, 250, 16 + LTEXT "Health" 64, 314, 50, 75, 16 + LTEXT "*" 65, 325, 69, 155, 18 + LTEXT "Spell Pts." 66, 314, 89, 75, 16 + LTEXT "*" 67, 325, 108, 155, 18 + LTEXT "0_89" 68, 176, 339, 106, 20 + LTEXT "=" 69, 11, 285, 387, 17 + LTEXT "~Skill Pts.:" 70, 382, 29, 62, 16 + LTEXT "~" 71, 445, 29, 32, 16 + } + +1020 DIALOG 10, 10, 364, 216 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_9" 1, 244, 46, 58, 20 + LTEXT "0_88" 2, 176, 46, 58, 20 + LTEXT "5_213" 3, 8, 9, 36, 36 + LTEXT "There is a stout wooden lever protruding from the ground here. Pull it?" 4, 50, 4, 253, 34 + } + +1021 DIALOG 10, 10, 367, 135 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "~Buying Food:" 2, 59, 8, 106, 17 + LTEXT "5_703" 3, 9, 8, 36, 36 + LTEXT "" 5, 103, 55, 28, 16 + LTEXT "" 7, 173, 55, 21, 16 + LTEXT "" 10, 103, 77, 63, 16 + LTEXT "0_8" 11, 200, 103, 63, 23 + LTEXT "" 13, 228, 77, 63, 16 + LTEXT "1_0" 14, 271, 103, 63, 23 + LTEXT "" 15, 120, 32, 171, 16 + LTEXT "0_26" 16, 129, 103, 63, 23 + LTEXT "~Buying:" 17, 59, 32, 55, 16 + LTEXT "~Cost:" 18, 59, 55, 39, 16 + LTEXT "~Per:" 19, 137, 55, 39, 16 + LTEXT "~food." 20, 201, 55, 39, 16 + LTEXT "~Gold:" 21, 59, 77, 39, 16 + LTEXT "~Food:" 22, 182, 77, 39, 16 + } + +1024 DIALOG 10, 10, 290, 183 +STYLE WS_POPUP | WS_DLGFRAME +{ + LTEXT "6_0", 2, 99, 130, 129, 24 + LTEXT "5_702", 3, 8, 8, 36, 36 + LTEXT "~Enter how much experience you want this character to have. Note that the character will not gain any more levels until the character earns at least 1 point more point of experience in the game. The most you can give is 10000.", 4, 49, 8, 234, 58 + LTEXT "1_63", 5, 204, 165, 75, 16 + LTEXT "Experience for each level:", 7, 49, 106, 140, 14 + LTEXT "", 8, 201, 106, 84, 14 +} + +1045 DIALOG 10, 10, 276, 84 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_5" 1, 182, 53, 58, 20 + LTEXT "0_62" 2, 114, 53, 58, 20 + LTEXT "5_710" 3, 6, 6, 36, 36 + LTEXT "This creature isn't hostile. |Attack anyway?" 4, 48, 6, 192, 40 + } + + + +1047 DIALOG 10, 10, 510, 310 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_5" 1, 416, 279, 58, 20 + LTEXT "~Alchemy:" 2, 53, 8, 71, 16 + LTEXT "~For:" 3, 53, 29, 32, 16 + LTEXT "" 4, 89, 29, 165, 16 + LTEXT "5_720" 5, 8, 8, 36, 36 + LTEXT "*(Difficulty follows in parenthesis.)" 6, 6, 283, 259, 17 + LTEXT "~#" 7, 79, 54, 22, 16 + LTEXT "~Make:" 8, 109, 54, 75, 16 + LTEXT "0_35" 9, 76, 73, 23, 20 + LTEXT "" 10, 109, 75, 160, 16 + LTEXT "0_36" 11, 76, 96, 23, 20 + LTEXT "" 12, 109, 98, 160, 16 + LTEXT "0_37" 13, 76, 119, 23, 20 + LTEXT "" 14, 109, 121, 160, 16 + LTEXT "0_38" 15, 76, 142, 23, 20 + LTEXT "" 16, 109, 144, 160, 16 + LTEXT "0_39" 17, 76, 165, 23, 20 + LTEXT "" 18, 109, 167, 160, 16 + LTEXT "0_40" 19, 76, 188, 23, 20 + LTEXT "" 20, 109, 190, 160, 16 + LTEXT "0_41" 21, 76, 211, 23, 20 + LTEXT "" 22, 109, 213, 160, 16 + LTEXT "0_42" 23, 76, 234, 23, 20 + LTEXT "" 24, 109, 236, 160, 16 + LTEXT "0_43" 25, 76, 257, 23, 20 + LTEXT "" 26, 109, 259, 160, 16 + LTEXT "0_44" 27, 278, 74, 23, 20 + LTEXT "" 28, 311, 76, 160, 16 + LTEXT "0_45" 29, 278, 97, 23, 20 + LTEXT "" 30, 311, 99, 160, 16 + LTEXT "0_46" 31, 278, 120, 23, 20 + LTEXT "" 32, 311, 122, 160, 16 + LTEXT "0_47" 33, 278, 143, 23, 20 + LTEXT "" 34, 311, 145, 160, 16 + LTEXT "0_48" 35, 278, 166, 23, 20 + LTEXT "" 36, 311, 168, 160, 16 + LTEXT "0_49" 37, 278, 189, 23, 20 + LTEXT "" 38, 311, 191, 160, 16 + LTEXT "0_50" 39, 278, 212, 23, 20 + LTEXT "" 40, 311, 214, 160, 16 + LTEXT "0_90" 41, 278, 235, 23, 20 + LTEXT "" 42, 311, 237, 160, 16 + LTEXT "0_67" 43, 448, 8, 58, 20 + } + +1048 DIALOG 10, 10, 358, 86 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "5_726" 2, 6, 6, 36, 36 + LTEXT "" 4, 54, 10, 262, 16 + LTEXT "~Gold:" 5, 53, 57, 44, 16 + LTEXT "" 6, 102, 57, 63, 16 + LTEXT "0_8" 7, 190, 54, 64, 23 + LTEXT "" 8, 102, 33, 63, 16 + LTEXT "1_5" 9, 261, 54, 63, 23 + LTEXT "~Cost:" 10, 53, 33, 44, 16 + } + +1049 DIALOG 10, 10, 338, 60 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 249, 30, 58, 20 + LTEXT "5_702" 2, 8, 8, 36, 36 + LTEXT "No room in your inventory." 3, 52, 4, 255, 18 + } + +1050 DIALOG 10, 10, 466, 326 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_0" 1, 371, 297, 56, 20 + LTEXT "5_707" 2, 6, 6, 36, 36 + LTEXT "~Select a graphic for your PC:" 3, 50, 6, 248, 16 + LTEXT "0_5" 4, 300, 297, 60, 20 + LTEXT "2_1" 5, 55, 29, 16, 17 + LTEXT "2_0" 6, 55, 74, 16, 18 + LTEXT "2_0" 7, 55, 119, 16, 18 + LTEXT "2_0" 8, 54, 164, 17, 18 + LTEXT "2_0" 9, 54, 209, 17, 18 + LTEXT "2_0" 10, 54, 254, 17, 18 + LTEXT "2_0" 11, 117, 29, 16, 17 + LTEXT "2_0" 12, 117, 74, 16, 18 + LTEXT "2_0" 13, 117, 119, 16, 18 + LTEXT "2_0" 14, 116, 164, 17, 18 + LTEXT "2_0" 15, 116, 209, 17, 18 + LTEXT "2_0" 16, 116, 254, 17, 18 + LTEXT "2_0" 17, 179, 30, 16, 17 + LTEXT "2_0" 18, 179, 75, 16, 18 + LTEXT "2_0" 19, 179, 120, 16, 18 + LTEXT "2_0" 20, 178, 165, 17, 18 + LTEXT "2_0" 21, 178, 210, 17, 18 + LTEXT "2_0" 22, 178, 255, 17, 18 + LTEXT "2_0" 23, 245, 30, 16, 17 + LTEXT "2_0" 24, 245, 75, 16, 18 + LTEXT "2_0" 25, 245, 120, 16, 18 + LTEXT "2_0" 26, 244, 165, 17, 18 + LTEXT "2_0" 27, 244, 210, 17, 18 + LTEXT "2_0" 28, 244, 255, 17, 18 + LTEXT "2_0" 29, 312, 30, 16, 17 + LTEXT "2_0" 30, 312, 75, 16, 18 + LTEXT "2_0" 31, 312, 120, 16, 18 + LTEXT "2_0" 32, 311, 165, 17, 18 + LTEXT "2_0" 33, 311, 210, 17, 18 + LTEXT "2_0" 34, 311, 255, 17, 18 + LTEXT "2_0" 35, 378, 30, 16, 17 + LTEXT "2_0" 36, 378, 75, 16, 18 + LTEXT "2_0" 37, 378, 120, 16, 18 + LTEXT "2_0" 38, 377, 165, 17, 18 + LTEXT "2_0" 39, 377, 210, 17, 18 + LTEXT "2_0" 40, 377, 255, 17, 18 + LTEXT "5_400" 41, 76, 29, 28, 35 + LTEXT "5_401" 42, 76, 74, 28, 35 + LTEXT "5_402" 43, 76, 119, 28, 35 + LTEXT "5_403" 44, 76, 164, 28, 35 + LTEXT "5_404" 45, 76, 209, 28, 35 + LTEXT "5_405" 46, 76, 254, 28, 35 + LTEXT "5_406" 47, 138, 29, 28, 35 + LTEXT "5_407" 48, 138, 74, 28, 35 + LTEXT "5_408" 49, 138, 119, 28, 35 + LTEXT "5_409" 50, 138, 164, 28, 35 + LTEXT "5_410" 51, 138, 209, 28, 35 + LTEXT "5_411" 52, 138, 254, 28, 35 + LTEXT "5_412" 53, 200, 30, 28, 35 + LTEXT "5_413" 54, 200, 75, 28, 35 + LTEXT "5_414" 55, 200, 120, 28, 35 + LTEXT "5_415" 56, 200, 165, 28, 35 + LTEXT "5_416" 57, 200, 210, 28, 35 + LTEXT "5_417" 58, 200, 255, 28, 35 + LTEXT "5_418" 59, 266, 30, 28, 35 + LTEXT "5_419" 60, 266, 75, 28, 35 + LTEXT "5_420" 61, 266, 120, 28, 35 + LTEXT "5_421" 62, 266, 165, 28, 35 + LTEXT "5_422" 63, 266, 210, 28, 35 + LTEXT "5_423" 64, 266, 255, 28, 35 + LTEXT "5_424" 65, 333, 30, 28, 35 + LTEXT "5_425" 66, 333, 75, 28, 35 + LTEXT "5_426" 67, 333, 120, 28, 35 + LTEXT "5_427" 68, 333, 165, 28, 35 + LTEXT "5_428" 69, 333, 210, 28, 35 + LTEXT "5_429" 70, 333, 255, 28, 35 + LTEXT "5_430" 71, 399, 30, 28, 35 + LTEXT "5_431" 72, 399, 75, 28, 35 + LTEXT "5_432" 73, 399, 120, 28, 35 + LTEXT "5_433" 74, 399, 165, 28, 35 + LTEXT "5_434" 75, 399, 210, 28, 35 + LTEXT "5_435" 76, 399, 255, 28, 35 + LTEXT "Click button to left of graphic to select." 77, 2, 308, 245, 16 + } + +1051 DIALOG 10, 10, 303, 121 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "6_0" 2, 118, 36, 148, 15 + LTEXT "5_707" 3, 8, 8, 36, 36 + LTEXT "~Select a name for your PC:" 4, 53, 6, 222, 20 + LTEXT "~Name:" 5, 53, 36, 58, 16 + LTEXT "" 6, 53, 63, 217, 16 + LTEXT "1_63" 7, 209, 88, 65, 22 + } + +1053 DIALOG 10, 10, 332, 116 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_65" 1, 239, 84, 58, 20 + LTEXT "0_64" 2, 172, 84, 58, 20 + LTEXT "5_707" 3, 6, 6, 36, 36 + LTEXT "You are about to consign this character to the eternal void.||Are you sure you want to do this?" 4, 48, 6, 249, 67 + } + +1054 DIALOG 10, 10, 330, 66 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_64" 1, 239, 37, 58, 20 + LTEXT "0_65" 2, 170, 37, 58, 20 + LTEXT "5_707" 3, 6, 6, 36, 36 + LTEXT "Would you like to create another PC?" 4, 48, 6, 249, 21 + } + +1061 DIALOG 10, 10, 332, 78 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_9" 1, 239, 49, 58, 20 + LTEXT "0_66" 2, 150, 49, 78, 20 + LTEXT "5_722" 3, 6, 6, 36, 36 + LTEXT "There is a glowing portal here. " 4, 48, 6, 249, 33 + } + +1062 DIALOG 10, 10, 529, 298 +STYLE WS_POPUP | WS_DLGFRAME +{ + LTEXT "1_63", 1, 434, 268, 61, 20 + LTEXT "5_716", 2, 6, 6, 36, 36 + LTEXT "Classic Blades of Exile Character Editor Beta 1 |Released under the GNU General Public License, version 2.", 3, 50, 6, 358, 34 + LTEXT "Comments and questions? Feel free to express yourself on the Irony Central Board: http://www.ironycentral.com/forum/", 5, 50, 178, 354, 32 + LTEXT "Spiderweb Software web page: http://www.spidweb.com", 6, 60, 211, 354, 53 + LTEXT "The Blades of Exile Editor was originally created by Spiderweb Software - _Where our aberrations become your reality._ ||_Blades of Exile_ and Spiderweb Software are trademarks of Spiderweb Software.", 7, 50, 91, 410, 51 + LTEXT "ORIGINAL CREDITS: | Concept, Design, Programming: Jeff Vogel | Graphics: Andrew Hunter", 8, 50, 42, 416, 47 +} + +1063 DIALOG 10, 10, 324, 58 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 246, 31, 58, 20 + LTEXT "5_723" 2, 6, 6, 36, 36 + LTEXT "This is not a Blades of Exile save file." 3, 50, 6, 254, 16 + } + +1064 DIALOG 10, 10, 322, 68 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 245, 34, 58, 20 + LTEXT "5_723" 2, 6, 6, 36, 36 + LTEXT "Loading Blades of Exile save file failed.|" 3, 50, 6, 253, 19 + } + +1065 DIALOG 10, 10, 339, 189 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_52" 1, 248, 164, 58, 20 + LTEXT "0_5" 2, 51, 164, 58, 20 + LTEXT "5_707" 3, 8, 8, 36, 36 + LTEXT "CREATING A PARTY: |You are now going to the party creation screen. You will be given a prefabricated party. To create new characters from scratch, press the Fry button by the existing characters." 4, 50, 3, 253, 76 + LTEXT "Slithzerikai and Nephilim get bonuses to their statistics, and characters with Mage and Priest Spell skill get bonuses to their spell points. These bonuses are added after character creation is completed." 5, 50, 82, 254, 75 + } + +1066 DIALOG 10, 10, 336, 64 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_84" 1, 230, 31, 80, 20 + LTEXT "0_85" 2, 122, 31, 77, 20 + LTEXT "0_5" 3, 54, 31, 58, 20 + LTEXT "5_723" 4, 9, 9, 36, 36 + LTEXT "~Do you want to save before quitting?" 5, 52, 5, 254, 18 + } + +1067 DIALOG 10, 10, 336, 78 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_84" 1, 233, 41, 80, 20 + LTEXT "0_105" 2, 125, 41, 77, 20 + LTEXT "0_5" 3, 57, 41, 58, 20 + LTEXT "5_723" 4, 9, 9, 36, 36 + LTEXT "~Do you want to save before opening a new file?" 5, 52, 5, 262, 33 + } + +1069 DIALOG 10, 10, 372, 178 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_81" 1, 272, 146, 66, 20 + LTEXT "0_82" 2, 197, 146, 65, 20 + LTEXT "0_83" 3, 122, 146, 66, 20 + LTEXT "5_2700" 4, 6, 6, 36, 36 + LTEXT "Alas, the cruel forces that are ravaging your world have claimed a new set of victims. " 5, 85, 6, 252, 44 + LTEXT "Anaximander greets the news of your demise with sadness, and then starts the search for a new group of adventurers. The plagues of monsters must be ended, if the Exiles are ever to return to the surface. Care to take another shot?" 6, 85, 51, 253, 92 + LTEXT "5_2701" 7, 42, 6, 36, 36 + LTEXT "5_2704" 8, 6, 42, 36, 36 + LTEXT "5_2705" 9, 42, 42, 36, 36 + } + +1070 DIALOG 10, 10, 320, 112 + STYLE WS_POPUP | WS_DLGFRAME + { + DEFPUSHBUTTON "Go for it!" 1, 103, 41, 41, 10, WS_GROUP + PUSHBUTTON "Exit Exile" 100, 59, 41, 42, 10, WS_GROUP + LTEXT "Unfortunately, this program requires 8-bit Color Quickdraw to run optimally. It might work with less, or it might not work at all. Do you wish to try?" 3, 10, 7, 276, 66 + } + +1071 DIALOG 10, 10, 303, 173 + STYLE WS_POPUP | WS_DLGFRAME + { + DEFPUSHBUTTON "Yes" 1, 105, 73, 31, 10, WS_GROUP + PUSHBUTTON "Exit Exile" 100, 58, 73, 42, 10, WS_GROUP + PUSHBUTTON "Play as is" 3, 6, 73, 50, 10, WS_GROUP + LTEXT "This game is best with 256 Color Quickdraw, which you have on your system. It plays acceptably well with 16 colors. With more colors, the graphics sometimes turn to static, and the game will be unstable. " 4, 8, 6, 262, 98 + LTEXT "Would you like your monitor set to 256 colors?" 5, 8, 106, 263, 31 + } + +1072 DIALOG 10, 10, 535, 415 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 441, 391, 58, 20 + LTEXT "5_724" 2, 6, 6, 36, 36 + LTEXT "There are a wide variety of magical walls and barriers which you can create and will encounter..." 3, 60, 23, 418, 27 + LTEXT "EXILE HELP: MAGIC BARRIERS" 4, 50, 6, 235, 16 + LTEXT "Wall of Fire - The weakest wall. Short lived and low damage. | |Wall of Force - Does more damage than a Wall of Fire and lasts a bit longer." 5, 51, 55, 181, 86 + LTEXT "Stinking Cloud - Lasts a short time, and curses anyone who enters." 6, 51, 253, 179, 40 + LTEXT "Web - Lasts until walked through. Slows down the victim, and interfers with attacks. Pause to clean off webs. | |Antimagic Field - Spells cannot be casts while in this, nor may they be targeted into it. It fades eventually." 7, 284, 54, 219, 104 + LTEXT "Wall of Ice - Does as much damage as a Wall of Force, but lasts much longer. | |Wall of Blades - Long lasting, and does the most damage of the wall spells." 8, 51, 154, 182, 86 + LTEXT "Fire Barrier - Permanent. Only removable by Dispel Barrier spell. Damages anyone who walks into it. Blocks quickfire. |Force Barrier - Like Fire Barrier, but cannot be moved through." 9, 284, 169, 216, 81 + LTEXT "Quickfire - The most deadly of the barriers, once created it spreads through the dungeon/town destroying everything. It can only be blocked by the two barrier spells. Antimagic fields slow it down." 10, 49, 348, 449, 41 + LTEXT "5_1709" 11, 15, 59, 28, 36 + LTEXT "5_1708" 12, 15, 108, 28, 36 + LTEXT "5_1712" 13, 15, 158, 28, 36 + LTEXT "5_1713" 14, 15, 207, 28, 36 + LTEXT "5_1711" 15, 15, 257, 28, 36 + LTEXT "5_1715" 16, 15, 352, 28, 36 + LTEXT "5_1705" 17, 250, 62, 28, 36 + LTEXT "5_1710" 18, 250, 123, 28, 36 + LTEXT "5_1716" 19, 250, 177, 28, 36 + LTEXT "Barrels,Crates - Can be pushed around. Have items in them sometimes." 20, 86, 309, 411, 28 + LTEXT "5_1707" 21, 15, 306, 28, 36 + LTEXT "5_1706" 22, 53, 306, 28, 36 + LTEXT "Sleep Wall - Walking through can put character to sleep. Very dangerous." 23, 284, 261, 215, 43 + LTEXT "5_1714" 24, 250, 265, 28, 36 + } + +1079 DIALOG 10, 10, 518, 410 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 424, 381, 58, 20 + LTEXT "5_724" 2, 8, 8, 36, 36 + LTEXT "To move, click on the terrain screen in the direction you want to move, or use the keypad. To wait, click on your party.|The buttons on the bottom act as follows:" 3, 65, 31, 422, 34 + LTEXT "EXILE III HELP: OUTDOOR COMMANDS" 4, 52, 10, 235, 16 + LTEXT "To read a sign or search something, stand adjacent to it and look at it. To enter a town/dungeon/tower/pit. etc., move onto it." 5, 69, 209, 417, 33 + LTEXT "To board a boat, move onto it. To disembark, steer it onto land. To investigate a special (specials are marked with small white circles), move onto it. Boats cannot move diagonally." 6, 69, 292, 417, 50 + LTEXT "SECRET PASSAGES: Some walls have secret passages. To find them, walk into the wall." 7, 69, 343, 416, 33 + LTEXT "TIME SAVER: Hitting 'l' and then pressing a direction on the keypad has you look at thing right next to you in that direction. This works in towns (and for talking, etc.) too." 8, 69, 243, 416, 48 + LTEXT "5_1400" 9, 118, 78, 320, 100 + } + +1080 DIALOG 10, 10, 525, 401 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 432, 388, 58, 20 + LTEXT "5_724" 2, 8, 8, 36, 36 + LTEXT "To move, click on the terrain screen in the direction you want to move, or use the keypad. To wait, click on your party.|The action buttons (and the equivalent keys) are:" 3, 62, 29, 423, 48 + LTEXT "EXILE III HELP: TOWN COMMANDS" 4, 52, 11, 235, 16 + LTEXT "To read a sign, open a chest, or search a barrel/crate/etc., stand adjacent to it and look at it. To leave town, keep moving towards the border of the map. Move into a door to open it." 5, 61, 278, 430, 48 + LTEXT "To board a boat, move onto it. To leave it, steer it onto land. |You close a door by Using it. Some doors are locked - you can pick or bash open the lock when you move into them." 6, 61, 329, 430, 51 + LTEXT "When talking, looking, or using, first click on the appropriate button, and then click on the space to act on. When looking, you can click on the terrain screen border to scroll the view." 7, 61, 227, 428, 49 + LTEXT "5_1402" 8, 107, 87, 320, 100 + } + +1081 DIALOG 10, 10, 590, 412 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 500, 403, 58, 20 + LTEXT "5_724" 2, 9, 9, 36, 36 + LTEXT "Your PCs will act one at a time. To move, click on the terrain screen in the direction you want to move, or use the keypad. To have the PC stand ready, click on him/her. |The buttons on the bottom act as follows:" 3, 66, 26, 473, 49 + LTEXT "EXILE III HELP: COMBAT COMMANDS" 4, 53, 9, 235, 16 + LTEXT "Outdoors, you can only end combat when all foes are dead.|In an outdoor combat, to flee, move everyone off the border of the battlefield. To flee in town, leave combat mode and leave town." 5, 66, 348, 476, 49 + LTEXT "Make Active - This either makes only current character active, or switches back to having entire party active.|" 6, 66, 206, 475, 35 + LTEXT "Each PC gets a base 4 action pts. Each action uses some up. Heavy armor and being webbed or slowed reduces the total, and being hasted increases it. The cost of each action is ..." 7, 23, 260, 257, 81 + LTEXT "5_1401" 8, 147, 79, 320, 100 + LTEXT "5_1300" 9, 284, 242, 275, 100 + } + +1082 DIALOG 10, 10, 504, 365 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 405, 342, 58, 20 + LTEXT "5_724" 2, 8, 8, 36, 36 + LTEXT "EXILE III HELP: PARTY STATUS SCREEN" 3, 52, 12, 235, 16 + LTEXT "This area lists the names of your party members, their health and magic points, and two buttons:" 4, 61, 29, 394, 33 + LTEXT "After each PCs name are graphics to show its status:" 5, 61, 151, 379, 16 + LTEXT "5_1200" 6, 168, 66, 75, 16 + LTEXT "To have two PCs switch places, click on their switch places buttons. To get a full description of a character, click on the '?' button." 7, 61, 102, 401, 46 + LTEXT "5_1500" 8, 73, 173, 386, 94 + LTEXT "Active PC: The character whose name is in italics is the active character. This is the PC who will cast spells selected from the cast spells menus. and who is shopping in stores. To make a PC active, click on its name or type '1'-'6." 9, 61, 276, 401, 65 + } + +1083 DIALOG 10, 10, 534, 341 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 440, 312, 58, 20 + LTEXT "~EXILE II: RUINED WORLD b1.0|" 2, 50, 6, 456, 16 + LTEXT "Exile III was created on a PowerMac 6100 using CodeWarrior, development system of the Gods. It is written in C." 3, 50, 258, 453, 34 + LTEXT "Enjoy playing!" 4, 50, 295, 274, 18 + LTEXT "5_716" 5, 6, 6, 36, 36 + LTEXT "_Exile III: Ruined World_ and Spiderweb Software are trademarks of Spiderweb Software." 6, 50, 225, 455, 31 + LTEXT "Exile III is still being worked on. So there." 7, 50, 24, 451, 64 + } + +1084 DIALOG 10, 10, 559, 375 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 468, 348, 58, 20 + LTEXT "5_724" 2, 6, 6, 36, 36 + LTEXT "~Bugs and Stuff:" 3, 50, 6, 131, 18 + LTEXT "HINTS:" 4, 50, 77, 83, 15 + LTEXT "The hint book can be had somehow. Alternately, send check (to ?) or money order to..." 5, 50, 155, 466, 48 + LTEXT "COMMENTS:| We LOVE to hear what you have to say. Comments, questions, complaints, etc. can be sent to the address on the About Exile III page. Don't send comments to the address above. They don't want them." 6, 49, 274, 477, 66 + LTEXT "THE ADDRESS: " 7, 50, 205, 86, 15 + LTEXT "" 8, 324, 212, 73, 14 + LTEXT "Payment by credit card is available. Call ???." 9, 277, 229, 227, 33 + LTEXT "" 10, 62, 222, 206, 49 + LTEXT " Alas, though we tried, we probably didn't get all the bugs and typos out of Exile III. Should you find one, a bug report form is enclosed with the game. Also, E-mail addresses for comments are available on the About Exile III page." 11, 50, 26, 475, 49 + LTEXT "" 12, 50, 95, 466, 48 + } + +1086 DIALOG 10, 10, 338, 76 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_80" 1, 246, 46, 58, 20 + LTEXT "0_79" 2, 177, 46, 58, 20 + LTEXT "You have come to a dock/bridge. Pilot under it or land?" 3, 50, 3, 254, 32 + LTEXT "5_302" 4, 6, 6, 36, 36 + } + +1088 DIALOG 10, 10, 524, 416 + STYLE WS_POPUP | WS_DLGFRAME + { + DEFPUSHBUTTON "OK" 1, 216, 193, 31, 10, WS_GROUP + LTEXT "There are two sorts of magic spells: mage spells and priest spells. There are 62 spells of each type, each with a level of one to seven." 4, 60, 23, 423, 48 + LTEXT "EXILE HELP: MAGIC" 5, 50, 6, 235, 16 + LTEXT "You can only cast mage (or priest) spells of a level as high as your Mage (or Priest) Spells skill. Casting a spell costs spell points (the amount given in the Pick Spell window). Right-clicking on a spell button gives a description." 6, 60, 71, 423, 65 + LTEXT "Mage spells cannot be cast by someone wearing bulky armor (although armor can be put on after the spells are cast). " 7, 60, 283, 417, 33 + LTEXT "You start automatically knowing most spells up to level 3. Other spells you have to track down. Some are known by sages who can teach them to you (for a price). Others must be found in dungeons and ruins." 8, 60, 218, 424, 65 + LTEXT "When you decide to cast a spell, you will be a given a list of spells with green lights next to the spells you are currently able to cast (and not those that you are, say, too low a level to cast)." 9, 60, 136, 436, 50 + LTEXT "IMPORTANT: Spell effects are cumulative. Two poison spells do more than twice the damage of one poison spell. If a fear spell doesn't work, the next one will be more likely to. Casting 3 bless spells on a PC will make him/her a powerhouse." 10, 60, 316, 424, 62 + LTEXT "WARNING: Spells cast by a PC with 1, 2 or 3 intelligence will be very weak!" 11, 60, 186, 432, 32 + } + +1089 DIALOG 10, 10, 532, 404 + STYLE WS_POPUP | WS_DLGFRAME + { + DEFPUSHBUTTON "OK" 1, 219, 187, 31, 10, WS_GROUP + LTEXT "To get anywhere in Exile, you will need to talk at great length to the people around you. To talk to someone, click on the mouth button and then on the person to talk to." 4, 60, 27, 423, 48 + LTEXT "EXILE HELP: TALKING AND SHOPS" 5, 50, 6, 235, 16 + LTEXT "In the talk window, type the thing to ask about (always a single word) and hit enter. Everyone responds to:| 'look' 'name' 'job'|Saying 'bye' ends the conversation. " 6, 60, 77, 424, 65 + LTEXT "Talking to people is how you buy things, such as food or training. Usually, just saying 'buy' works. Sometimes, however, you have to say the specific thing they sell: if Albert says _I identify things._ ask about 'identify.'" 7, 60, 263, 436, 66 + LTEXT "Some people may provide valuable hints about what others know about. For example, if someone says _You should ask Tor about supplies,_ when you meet Tor 'supplies' should be one of the first things you ask about." 8, 60, 196, 424, 65 + LTEXT "You can figure out other things to ask the people about by picking words out of what they say. If JimBob says _I love killing Nephilim,_ 'killing' and 'Nephilim' are likely bets." 9, 60, 144, 436, 50 + LTEXT "Due to finite memory, people will generally not have more to say about everything they talk about, just the important things." 10, 60, 331, 436, 34 + } + +1090 DIALOG 10, 10, 525, 418 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_63" 1, 435, 384, 58, 20 + LTEXT "5_724" 2, 9, 9, 36, 36 + LTEXT "During your adventures, you will come across mind-boggling quantities of stuff. To pick up some of it, move your party (or active PC) near it, and hit the get button (or 'g'). Then, on the Get Item window, click on the item to grab." 3, 63, 30, 423, 64 + LTEXT "EXILE III HELP: ITEM INFO SCREEN" 4, 53, 13, 235, 16 + LTEXT "Once there, to equip (i.e. use) or unequip (take off) an item, click on its name. Other buttons will appear enabling you do to other things:" 5, 63, 131, 283, 57 + LTEXT "Items from slain monsters normally appear unidentified. To identify them, take them to a sage (such as Habecker in Fort Emergence). Also, buying Item Lore skill sometimes makes monster's treasure appear already identified." 6, 63, 274, 429, 50 + LTEXT "Once obtained, items show up in this window. Type '1'-'6' or click on the numbered button to bring up a character's inventory. " 7, 63, 95, 424, 33 + LTEXT "5_1100" 8, 350, 136, 129, 132 + LTEXT "The Sell, ID, and Enchant buttons only appear when talking to a person who can do these things. Many shopkeepers will buy your items, and certain sages can identify and even enchant them." 9, 63, 189, 281, 84 + LTEXT "Finally, hitting the Jobs button (or typing '8') takes you to the jobs page, where you can see what jobs you currently have. Hitting the 'Spec' button (or typing '9') brings up whatever special items you have." 10, 63, 325, 427, 50 + } + +1091 DIALOG 10, 10, 333, 74 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_5" 1, 244, 45, 58, 20 + LTEXT "0_78" 2, 134, 45, 78, 20 + LTEXT "5_723" 3, 9, 9, 36, 36 + LTEXT "Starting over will delete the current party. Are you sure you want to do this?" 4, 53, 6, 249, 31 + } + +1092 DIALOG 10, 10, 580, 430 + STYLE WS_POPUP | WS_DLGFRAME + { + DEFPUSHBUTTON "OK" 1, 242, 201, 31, 10, WS_GROUP + LTEXT "While playing Exile, you will meet many, many beings who want to kill you, both outdoors and in dungeons. When you are attacked outdoors, a battlefield will appear. When attacked in town, press the sword button to start combat. " 4, 60, 27, 482, 65 + LTEXT "EXILE HELP: COMBAT" 5, 50, 6, 235, 16 + LTEXT "During combat, each of your characters go, one after another, then the monsters act. Move into a monster to attack it. If you press the 'Active' button, only the currently active PC will act until you press it again." 6, 60, 160, 483, 50 + LTEXT "When monsters hit you, you are damaged and lose health points. When a blow would take you below 0 health, you end up at 0 health. If you take damage when at 0 health, you die. If you take a lot of damage while at 0 health, you turn to dust." 7, 60, 93, 483, 66 + LTEXT "When you use poison during combat, you poison your melee weapon or arrows (thrown weapons cannot be poisoned). The next several monsters you hit will take a lot of extra damage over time. " 8, 60, 344, 482, 49 + LTEXT "There are five sorts of weapons: edged, bashing, and pole, which are hand-to-hand weapons, and bow and thrown missile, which are missile weapons. You can buy skill in each of the five weapon types, which makes them hit more often." 9, 60, 211, 483, 66 + LTEXT "Equipping armor makes monster's blows do less damage. However, heavy armor makes you less likely to hit. Don't wear heavy armor if your weapon skill is low. You can equip two weapons, but this makes you MUCH less likely to hit." 10, 60, 278, 483, 65 + } + +1093 DIALOG 10, 10, 332, 78 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "1_5" 1, 238, 42, 58, 20 + LTEXT "0_63" 2, 169, 42, 58, 20 + LTEXT "5_702" 3, 8, 8, 36, 36 + LTEXT "~This item will be gone forever. Still drop it?" 4, 48, 2, 248, 33 + } + +1095 DIALOG 10, 10, 573, 384 + STYLE WS_POPUP | WS_DLGFRAME + { + DEFPUSHBUTTON "OK" 1, 242, 178, 31, 10, WS_GROUP + LTEXT "SCROLLING THE SCREEN - When looking in town or combat, clicking the gray border of the view screen shifts the view around. Similarly, you can target people offscreen in combat by clicking on the terrain border." 4, 60, 27, 481, 48 + LTEXT "EXILE HELP: VALUABLE INFO" 5, 50, 6, 235, 16 + LTEXT "For every (about) 100 experience a character gets, he/she gains a level. With each level comes more health and skill points. The latter may be traded at a trainer for better skills. " 6, 60, 126, 483, 50 + LTEXT "EXPERIENCE - When you kill a monster, the character striking the death blow gets a bunch of experience, and everyone else gets a lesser amount. When a monster dies of poison, everyone splits the experience." 7, 60, 76, 482, 49 + LTEXT "STORING ITEMS - Should you get too many items to carry, there are 3 places in the game where they can be stored. You only have to find them." 8, 60, 177, 489, 33 + LTEXT "SAVING MAPS - Your maps are saved in your save files. To stop doing this (and make the save files much smaller) you can turn off Saved Maps on the Preferences screen.|HELPFUL HINTS - Many useful tips are available under the 'Library' menu." 9, 60, 211, 483, 66 + LTEXT "SEARCHING - To search a barrel, crate, desk, etc. or open a chest, stand adjacent and look at it." 10, 60, 278, 483, 35 + LTEXT "HEALTH WARNING - When a blow knocks you down to 0 health, you are warned by a coughing noise." 11, 60, 314, 482, 34 + } + +1096 DIALOG 10, 10, 298, 286 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "5_724" 2, 8, 8, 36, 36 + LTEXT "+" 3, 55, 27, 182, 16 + LTEXT "+" 4, 70, 55, 167, 16 + LTEXT "+" 5, 109, 80, 41, 16 + LTEXT "+" 6, 215, 80, 28, 16 + LTEXT "=" 7, 21, 151, 241, 93 + LTEXT "1_0" 8, 201, 254, 63, 23 + LTEXT "0_2" 9, 22, 254, 63, 23 + LTEXT "0_3" 10, 85, 254, 64, 23 + LTEXT "+" 11, 73, 105, 167, 17 + LTEXT "*Spell Info:" 12, 55, 6, 83, 16 + LTEXT "*Name:" 13, 15, 55, 48, 16 + LTEXT "*Level/Cost:" 14, 15, 80, 87, 16 + LTEXT "*Range:" 15, 156, 80, 51, 16 + LTEXT "*When:" 16, 15, 105, 49, 17 + LTEXT "~Description:" 17, 15, 128, 89, 16 + } + +1097 DIALOG 10, 10, 299, 364 + STYLE WS_POPUP | WS_DLGFRAME + { + LTEXT "5_724" 1, 8, 8, 36, 36 + LTEXT "*" 2, 191, 90, 12, 13 + LTEXT "+" 3, 106, 30, 156, 16 + LTEXT "+" 4, 133, 57, 29, 15 + LTEXT "+" 5, 218, 57, 45, 15 + LTEXT "+" 6, 96, 83, 28, 15 + LTEXT "=" 7, 21, 130, 241, 88 + LTEXT "=" 8, 21, 250, 241, 74 + LTEXT "0_2" 9, 19, 332, 63, 23 + LTEXT "0_3" 10, 82, 332, 63, 23 + LTEXT "1_0" 11, 202, 332, 63, 23 + LTEXT "~Skill Info:" 12, 53, 6, 134, 16 + LTEXT "~Cost:" 13, 15, 57, 41, 16 + LTEXT "*Skill Pts.:" 14, 59, 57, 66, 16 + LTEXT "*Gold:" 15, 172, 57, 39, 15 + LTEXT "*Max. Level:" 16, 15, 83, 73, 16 + LTEXT "~Description:" 17, 15, 106, 75, 16 + LTEXT "~Tips:" 18, 16, 229, 75, 16 + LTEXT "*Name:" 19, 53, 30, 46, 16 + } + +1098 DIALOG 10, 10, 557, 417 + STYLE WS_POPUP | WS_DLGFRAME + { + DEFPUSHBUTTON "Button" 1, 289, 83, 31, 10, WS_GROUP + LTEXT "5_712" 2, 9, 9, 36, 36 + LTEXT "~Select a Spell:" 3, 54, 6, 141, 18 + LTEXT "0_11" 4, 10, 81, 58, 20 + LTEXT "0_12" 5, 10, 105, 58, 20 + LTEXT "0_13" 6, 10, 129, 58, 20 + LTEXT "0_14" 7, 10, 153, 58, 20 + LTEXT "0_15" 8, 10, 177, 58, 20 + LTEXT "0_16" 9, 10, 201, 58, 20 + LTEXT "0_35" 10, 235, 82, 23, 23 + LTEXT "0_36" 11, 235, 106, 23, 23 + LTEXT "0_37" 12, 235, 130, 23, 23 + LTEXT "0_38" 13, 235, 154, 23, 23 + LTEXT "0_39" 14, 235, 178, 23, 23 + LTEXT "0_40" 15, 235, 202, 23, 23 + LTEXT "0_5" 16, 389, 394, 63, 25 + LTEXT "1_17" 17, 459, 394, 63, 25 + LTEXT "" 18, 88, 84, 122, 16 + LTEXT "" 19, 88, 108, 122, 16 + LTEXT "" 20, 88, 132, 122, 16 + LTEXT "" 21, 88, 156, 122, 16 + LTEXT "" 22, 88, 180, 122, 16 + LTEXT "" 23, 88, 204, 122, 16 + LTEXT "" 24, 265, 85, 32, 16 + LTEXT "" 25, 265, 109, 32, 16 + LTEXT "" 26, 265, 133, 32, 16 + LTEXT "" 27, 265, 156, 32, 16 + LTEXT "" 28, 265, 181, 32, 16 + LTEXT "" 29, 265, 205, 32, 16 + LTEXT "" 30, 304, 85, 32, 16 + LTEXT "" 31, 304, 109, 32, 16 + LTEXT "" 32, 304, 133, 32, 16 + LTEXT "" 33, 304, 156, 32, 16 + LTEXT "" 34, 304, 181, 32, 16 + LTEXT "" 35, 304, 205, 32, 16 + LTEXT "+Pick spell to cast." 36, 30, 400, 186, 16 + LTEXT "2_0" 37, 114, 247, 14, 10 + LTEXT "2_0" 38, 114, 261, 14, 10 + LTEXT "2_0" 39, 114, 275, 14, 10 + LTEXT "2_0" 40, 114, 289, 14, 10 + LTEXT "2_0" 41, 114, 303, 14, 10 + LTEXT "2_0" 42, 114, 317, 14, 10 + LTEXT "2_0" 43, 114, 331, 14, 10 + LTEXT "2_0" 44, 114, 345, 14, 10 + LTEXT "2_0" 45, 114, 359, 14, 10 + LTEXT "2_0" 46, 114, 373, 14, 10 + LTEXT "2_0" 47, 247, 247, 14, 10 + LTEXT "2_0" 48, 247, 261, 14, 10 + LTEXT "2_0" 49, 247, 275, 14, 10 + LTEXT "2_0" 50, 247, 289, 14, 10 + LTEXT "2_0" 51, 247, 303, 14, 10 + LTEXT "2_0" 52, 247, 317, 14, 10 + LTEXT "2_0" 53, 247, 331, 14, 10 + LTEXT "2_0" 54, 247, 345, 14, 10 + LTEXT "2_0" 55, 247, 359, 14, 10 + LTEXT "2_0" 56, 247, 373, 14, 10 + LTEXT "2_0" 57, 379, 247, 14, 10 + LTEXT "2_0" 58, 379, 261, 14, 10 + LTEXT "2_0" 59, 379, 275, 14, 10 + LTEXT "2_0" 60, 379, 289, 14, 10 + LTEXT "2_0" 61, 379, 303, 14, 10 + LTEXT "2_0" 62, 379, 317, 14, 10 + LTEXT "2_0" 63, 379, 331, 14, 10 + LTEXT "2_0" 64, 379, 345, 14, 10 + LTEXT "2_0" 65, 379, 359, 14, 10 + LTEXT "2_0" 66, 379, 373, 14, 10 + LTEXT "2_0" 67, 508, 247, 14, 10 + LTEXT "2_0" 68, 508, 261, 14, 10 + LTEXT "2_0" 69, 508, 275, 14, 10 + LTEXT "2_0" 70, 508, 289, 14, 10 + LTEXT "2_0" 71, 508, 303, 14, 10 + LTEXT "2_0" 72, 508, 317, 14, 10 + LTEXT "2_0" 73, 508, 331, 14, 10 + LTEXT "2_0" 74, 508, 345, 14, 10 + LTEXT "0_25" 75, 281, 394, 102, 25 + LTEXT "~Caster:" 76, 9, 60, 75, 16 + LTEXT "~Target: HP: SP: Status:" 77, 209, 60, 223, 16 + LTEXT "Keyboard: Type '1'-'6' to pick caster, Shift-'1' - '6' to select target, 'space' for Other Spells, key by spell to cast spell. Right-click spell name for description." 78, 202, 0, 290, 57 + LTEXT "0_67" 79, 506, 6, 17, 17 + LTEXT "*" 80, 10, 227, 100, 16 + LTEXT "*" 81, 132, 227, 100, 16 + LTEXT "*" 82, 266, 227, 100, 16 + LTEXT "*" 83, 396, 227, 100, 16 + } +900 DIALOG 13, 16, 334, 220 +STYLE WS_POPUP | WS_DLGFRAME +{ + LTEXT "1_63", 1, 270, 197, 58, 20 + LTEXT "5_708", 2, 8, 8, 36, 36 + LTEXT "WELCOME TO THE BLADES OF EXILE EDITOR!", 3, 52, 3, 257, 18 + LTEXT "The Blades of Exile Editor is a utility designed to make your life easier when you get stuck playing Blades of Exile. Before leaping in, however, two warnings:", 4, 52, 26, 257, 54 + LTEXT "First, always back up a save file before using the editor. If you do something wrong or take yourself out of the scenario, you may lose valuable progress.", 5, 52, 88, 257, 50 + LTEXT "Second, the Editor and the game itself use some of the same files. It is recommended that you not run both at the same time - crashes may result.", 6, 52, 147, 257, 36 +} diff --git a/Blades of Exile Char Editor/Blades of Exile Character Editor.dev b/Blades of Exile Char Editor/Blades of Exile Character Editor.dev new file mode 100644 index 00000000..ad5f607e --- /dev/null +++ b/Blades of Exile Char Editor/Blades of Exile Character Editor.dev @@ -0,0 +1,228 @@ +[Project] +FileName=Blades of Exile Character Editor.dev +Name=Blades of Exile Character Editor +UnitCount=18 +Type=0 +Ver=1 +ObjFiles= +Includes= +Libs= +PrivateResource=Blades_of_Exile_Character_Editor_private.rc +ResourceIncludes= +MakeIncludes= +Compiler= +CppCompiler= +Linker=-lwinmm_@@_ +IsCpp=1 +Icon= +ExeOutput= +ObjectOutput= +OverrideOutput=0 +OverrideOutputName=Blades of Exile Character Editor.exe +HostApplication= +Folders= +CommandLine= +UseCustomMakefile=0 +CustomMakefile= +IncludeVersionInfo=0 +SupportXPThemes=0 +CompilerSet=0 +CompilerSettings=0000000000000000000000 + +[Unit1] +FileName=BLADPCED.CPP +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit2] +FileName=BLADPCED.RC +Folder=Blades of Exile Character Editor +Compile=1 +Link=0 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit3] +FileName=DLOGTOOL.CPP +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit4] +FileName=DLOGTOOL.H +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit5] +FileName=EDACTION.CPP +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit6] +FileName=EDACTION.H +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit7] +FileName=EDFILEIO.CPP +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit8] +FileName=EDFILEIO.H +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit9] +FileName=EDITORS.CPP +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit10] +FileName=EDITORS.H +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit11] +FileName=EDSOUND.CPP +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit12] +FileName=EDSOUND.H +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit13] +FileName=GLOBAL.CPP +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit14] +FileName=GLOBAL.H +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit15] +FileName=GRAPHICS.CPP +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit16] +FileName=GRAPHICS.H +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit17] +FileName=GRAPHUTL.CPP +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit18] +FileName=GRAPHUTL.H +CompileCpp=1 +Folder=Blades of Exile Character Editor +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[VersionInfo] +Major=0 +Minor=1 +Release=1 +Build=1 +LanguageID=1033 +CharsetID=1252 +CompanyName= +FileVersion= +FileDescription=Developed using the Dev-C++ IDE +InternalName= +LegalCopyright= +LegalTrademarks= +OriginalFilename= +ProductName= +ProductVersion= +AutoIncBuildNr=0 + diff --git a/Blades of Exile Char Editor/Blades_of_Exile_Character_Editor_private.h b/Blades of Exile Char Editor/Blades_of_Exile_Character_Editor_private.h new file mode 100644 index 00000000..a07a6822 --- /dev/null +++ b/Blades of Exile Char Editor/Blades_of_Exile_Character_Editor_private.h @@ -0,0 +1,23 @@ +/* THIS FILE WILL BE OVERWRITTEN BY DEV-C++ */ +/* DO NOT EDIT ! */ + +#ifndef BLADES_OF_EXILE_CHARACTER_EDITOR_PRIVATE_H +#define BLADES_OF_EXILE_CHARACTER_EDITOR_PRIVATE_H + +/* VERSION DEFINITIONS */ +#define VER_STRING "0.1.1.1" +#define VER_MAJOR 0 +#define VER_MINOR 1 +#define VER_RELEASE 1 +#define VER_BUILD 1 +#define COMPANY_NAME "" +#define FILE_VERSION "" +#define FILE_DESCRIPTION "Developed using the Dev-C++ IDE" +#define INTERNAL_NAME "" +#define LEGAL_COPYRIGHT "" +#define LEGAL_TRADEMARKS "" +#define ORIGINAL_FILENAME "" +#define PRODUCT_NAME "" +#define PRODUCT_VERSION "" + +#endif /*BLADES_OF_EXILE_CHARACTER_EDITOR_PRIVATE_H*/ diff --git a/Blades of Exile Char Editor/Blades_of_Exile_Character_Editor_private.rc b/Blades of Exile Char Editor/Blades_of_Exile_Character_Editor_private.rc new file mode 100644 index 00000000..351b789b --- /dev/null +++ b/Blades of Exile Char Editor/Blades_of_Exile_Character_Editor_private.rc @@ -0,0 +1,5 @@ +/* THIS FILE WILL BE OVERWRITTEN BY DEV-C++ */ +/* DO NOT EDIT! */ + +#include "BLADPCED.RC" + diff --git a/Blades of Exile Char Editor/Changes_SE.txt b/Blades of Exile Char Editor/Changes_SE.txt new file mode 100644 index 00000000..0f104461 --- /dev/null +++ b/Blades of Exile Char Editor/Changes_SE.txt @@ -0,0 +1,7 @@ +Changes : + +- The editor now display the filename of the scenario you are in. +- The editor now get the list of items from the scenario you're in. If not in a scenario, bladbase.exs is used. (clicking a item with food (resp. gold) type will give a random (1-20) amount of food (resp. gold).) +- References to registration and shareware are removed. +- Status Screen now show Food, Gold and Day. +- Corrected the garbled status due to a non-alive character (Ishad Nha) \ No newline at end of file diff --git a/Blades of Exile Char Editor/DLOGTOOL.CPP b/Blades of Exile Char Editor/DLOGTOOL.CPP new file mode 100644 index 00000000..47d6f1db --- /dev/null +++ b/Blades of Exile Char Editor/DLOGTOOL.CPP @@ -0,0 +1,1598 @@ +#include + +#define ND 15 +#define NI 500 +#define NL 100 +#define NUM_DLOG_B 53 + +#include "string.h" + +#include "global.h" +#include "graphutl.h" +#include "stdio.h" +#include "edsound.h" +#include "dlogtool.h" +#include "graphics.h" + +extern Boolean play_sounds,cursor_shown,dialog_not_toast,block_erase; +extern HBITMAP mixed_gworld, pc_stats_gworld, item_stats_gworld, text_area_gworld; +extern HBITMAP storage_gworld,terrain_screen_gworld,text_bar_gworld,orig_text_bar_gworld,buttons_gworld; +extern HBITMAP party_template_gworld,items_gworld,tiny_obj_gworld,fields_gworld; +extern HBITMAP dlg_buttons_gworld,spec_scen_g; +extern HBITMAP pcs_gworld,dlogpics_gworld; +extern HFONT fantasy_font,font,italic_font,underline_font,bold_font,tiny_font,small_bold_font; +extern HWND mainPtr; +//extern HPALETTE hpal; +extern HDC main_dc; +extern HINSTANCE store_hInstance; +long CALLBACK WndProc (HWND, UINT, UINT, LONG); +extern HBRUSH bg[14]; + +// Necessary evil +extern HBITMAP anim_gworld,pcs_gworld; +extern HBITMAP map_gworld,mixed_gworld; +extern HBITMAP button_num_gworld; +extern HBITMAP terrain_screen_gworld, buttons_gworld, text_screen_gworld,text_bar_gworld,orig_text_bar_gworld; +extern HBITMAP pc_info_screen_gworld,orig_pc_info_screen_gworld,terrain_gworld, party_template_gworld; +extern HBITMAP monster_template_gworld; +extern HBITMAP startmsc_gworld; +extern short far terrain_pic[256]; +extern short ulx,uly; + +extern HACCEL accel; +extern unsigned char m_pic_index_x[200]; +extern unsigned char m_pic_index_y[200]; +extern unsigned char m_pic_index[200]; + +short current_key = 0; +short far dlg_keys[ND]; +short far dlg_types[ND]; +HWND dlgs[ND]; +HWND dlg_parent[ND]; +short far dlg_highest_item[ND]; +Boolean dlg_draw_ready[ND]; + +short far item_dlg[NI]; +short far item_number[NI]; +char far item_type[NI]; +RECT far item_rect[NI]; +short far item_flag[NI]; +char far item_active[NI]; +char far item_key[NI]; +short far item_label[NI]; +short far item_label_loc[NI]; + +char far text_long_str[10][256]; +char far text_short_str[140][35]; +char far labels[NL][25]; +Boolean far label_taken[NL]; + +HWND edit_box = NULL; +HWND store_edit_parent; // kludgy +WNDPROC edit_proc,old_edit_proc; + +HDC dlg_force_dc = NULL; // save HDCs when dealing with dlogs + +short store_free_slot,store_dlog_num; +HWND store_parent; + +short available_dlog_buttons[NUM_DLOG_B] = {0,63,64,65,1,4,5,8, + 128, + 9, + 10, // 10 + 11,12,13, + 14,15,16,17,29, 51, + 60,61,62, // 20 + 66,69,70, 71,72,73,74,79, + 80,83,86,87,88, 91,92,93,99,100, + 101,102,104, 129,130,131,132,133,134,135,136,137}; +short button_type[150] = {1,1,4,5,1,1,0,0,1,1, + 1,1,1,1,1,1,1,1,8,8, + 9,9,9,1,1,2,1,6,7,1, + 1,12,1,1,2,0,0,0,0,0, + 0,0,0,0,0,0,0,0,0,0, + 0,1,1,1,2,1,1,1,2,2, // 50 + 1,1,1,1,1,1,2,3,1,1, + 1,1,1,1,2,2,2,2,2,1, + 1,1,1,1,2,2,1,1,1,2, + 0,1,1,1,14,13,12,12,12,1, + 1,1,1,2,1,2,2,2,2,1, // 100 + 2,2,2,2,2,2,2,2,2,2, + 2,2,2,2,2,2,2,2,1,1, + 1,1,1,1,1,1,1,1,0,0, + 0,0,0,0,0,0,0,0,0,0}; +char *button_strs[150] = {"Done ","Ask"," "," ","Keep", "Cancel","+","-","Buy","Leave", + "Get","1","2","3","4","5","6","Cast"," "," ", + " "," "," ","Buy","Sell","Other Spells","Buy x10"," "," ","Save", + "Race","Train","Items","Spells","Heal Party","1","2","3","4","5", + "6","7","8","9","10","11","12","13","14","15", + /*50*/ "16","Take","Create","Delete","Race/Special","Skill","Name","Graphic","Bash Door","Pick Lock", + "Leave","Steal","Attack","OK","Yes","No","Step In"," ","Record","Climb", + "Flee","Onward","Answer","Drink","Approach","Mage Spells","Priest Spells","Advantages","New Game","Land", + "Under","Restore","Restart","Quit","Save First","Just Quit","Rest","Read","Pull","Alchemy", + "17","Push","Pray","Wait","","","Delete","Graphic","Create","Give", + /*100*/ "Destroy","Pay","Free","Next Tip","Touch", "Open File","Create/Edit","Clear Special","Edit Abilities","Choose", + "Go Back","Create New","General","One Shots","Affect PCs","If-Thens","Town Specs","Out Specs","Advanced","Weapon Abil", + "General Abil.","NonSpell Use","Spell Usable","Reagents","Missiles","Abilities","Pick Picture","Animated","Enter","Burn", + "Insert","Remove","Accept","Refuse","Open","Close","Sit","Stand","","", + "18","19","20","Invisible!","","","","","",""}; + +short far button_left_adj[150] = {0,0,0,0,0, 0,0,0,0,0, +0,0,0,0,0, 0,0,0,0,0, +0,0,0,0,0, 0,0,0,0,0, +0,0,0,0,0, 0,0,0,0,0, +0,0,0,0,0, 0,0,0,0,0, +0,0,0,0,0, 0,0,0,0,0, // 50 +0,0,0,0,0, 0,0,0,0,0, +0,0,0,0,0, 0,0,0,0,0, +0,0,0,0,0, 0,0,0,0,0, +0,0,0,0,0, 0,0,0,0,0, +0,0,0,0,0, 0,0,0,0,0, +0,0,0,0,0, 0,0,0,0,0, +0,0,0,0,0, 0,0,0,0,0, +0,0,0,0,0, 0,0,0,0,0, +0,0,0,0,0, 0,0,0,0,0}; +char button_def_key[150] = {0,0,20,21,'k', 24,0,0,0,0, + 'g','1','2','3','4', '5','6',0,0,0, + 0,0,0,0,0,' ',0,22,23,0, + 0,0,0,0,0,'1','2','3','4','5', + '6','7','8','9','a', 'b','c','d','e','f', + 'g',0,0,0,0,0,0,0,0,0, + 0,0,0,0,'y','n',0,'?','r',0, + 0,0,0,0,0,0,0,0,0, 0, + 0,0,0,0,0,0,0,0,0,0, + 'g',0,0,0,0,0,0,0,0,0, + 0,0,0,0,0,0,0,0,0,0, + 0,0,0,0,0,0,0,0,0,0, + 0,0,0,0,0,0,0,0,0,0, + 0,0,0,0,0,0,0,0,0,0, + 0,0,0,0,0,0,0,0,0,0 + }; + // specials ... 20 - <- 21 - -> 22 up 23 down 24 esc + // 25-30 ctrl 1-6 31 - return + +short button_ul_x[15] = {0,46,0,126,0, 0,126,126,126,138, 166,0,0,126,172}; +short button_ul_y[15] = {0,0,132,23,46, 69,46,69,36,36, 36,23,92,92,0}; +short button_width[15] = {23,63,102,16,63, 63,63,63,6,14, 14,63,63,63,30}; +short button_height[15] = {23,23,23,13,23, 23,23,23,6,10,10,23,40,40,30}; + +BOOL CALLBACK dummy_dialog_proc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam); +LRESULT CALLBACK fresh_edit_proc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam); + +DLGPROC d_proc; + +extern char szAppName[]; +extern char szWinName[]; + +void cd_init_dialogs() +{ + short i; + + for (i = 0; i < ND; i++) { + dlg_keys[i] = -1; + dlg_types[i] = 0; + dlgs[i] = NULL; + dlg_highest_item[i] = 0; + } + for (i = 0; i < NI; i++) { + item_dlg[i] = -1; + } + for (i = 0; i < NL; i++) { + label_taken[i] = FALSE; + } + d_proc = dummy_dialog_proc; + edit_proc = fresh_edit_proc; +} + +long CALLBACK fresh_edit_proc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) +{ + + switch (message) { + case WM_KEYDOWN: + if (wParam == VK_RETURN) + SendMessage(store_edit_parent,WM_COMMAND,9,0); + if (wParam == VK_ESCAPE) + SendMessage(store_edit_parent,WM_COMMAND,8,0); +/* if (wParam == VK_RETURN) + SendMessage(store_edit_parent,WM_KEYDOWN,wParam,lParam); + if (wParam == VK_ESCAPE) + SendMessage(store_edit_parent,WM_KEYDOWN,wParam,lParam);*/ + break; + } + return CallWindowProc((WNDPROC) old_edit_proc,hwnd,message,wParam,lParam); +} + +short cd_create_dialog_parent_num(short dlog_num,short parent) +{ + short i; + + if ((parent == 0) || (parent == 1)) + return cd_create_dialog(dlog_num,mainPtr); + i = cd_get_dlg_index(parent); + if (i < 0) + return -1; + return cd_create_dialog(dlog_num,dlgs[i]); + +} + +short cd_create_dialog(short dlog_num,HWND parent) +{ + short i,free_slot = -1; + HWND dlg; + + if (parent != NULL) { + if (IsWindowEnabled(parent) == 0) + return -1; + } + + store_dlog_num = dlog_num; + store_parent = parent; + + for (i = 0; i < ND; i++) { + if ((dlg_keys[i] >= 0) && (dlg_types[i] == dlog_num)) + return -1; + } + for (i = 0; i < ND; i++) { + if (dlg_keys[i] < 0) { + free_slot = i; + i = 500; + } + } + if (free_slot < 0) + return -2; + current_key++; + dlg_keys[free_slot] = current_key; + dlg_types[free_slot] = dlog_num; + dlg_highest_item[free_slot] = 1; + dlg_draw_ready[free_slot] = FALSE; + dlgs[free_slot] = NULL; + + // first, create dummy dlog + store_free_slot = free_slot; + dlg = CreateDialog(store_hInstance,MAKEINTRESOURCE(dlog_num),0,(DLGPROC) d_proc); + + if (dlgs[free_slot] == NULL) { + play_sound(3); + return -3; + } + center_window(dlgs[free_slot]); + + + + dlg_parent[free_slot] = parent; + + switch (dlog_num) { + case 958: SetWindowText(dlgs[free_slot],"Tip of the Day"); break; + case 959: SetWindowText(dlgs[free_slot],"Getting a Job"); break; + case 960: SetWindowText(dlgs[free_slot],"Talking Notes"); break; + case 961: SetWindowText(dlgs[free_slot],"Adventure Notes"); break; + case 962: SetWindowText(dlgs[free_slot],"Adventure Journal"); break; + case 970: case 971: case 972: case 973: SetWindowText(dlgs[free_slot],"Blades of Exile"); break; + case 987: SetWindowText(dlgs[free_slot],"Getting Items"); break; + case 988: SetWindowText(dlgs[free_slot],"Casting Simulacrum"); break; + case 989: SetWindowText(dlgs[free_slot],"Create a Party"); break; + case 991: SetWindowText(dlgs[free_slot],"Character Statistics"); break; + case 996: SetWindowText(dlgs[free_slot],"Known Alchemy"); break; + case 997: SetWindowText(dlgs[free_slot],"Getting Help"); break; + case 998: SetWindowText(dlgs[free_slot],"Item Information"); break; + case 999: SetWindowText(dlgs[free_slot],"Monster Stats"); break; + case 1012: SetWindowText(dlgs[free_slot],"How many?"); break; + case 1013: SetWindowText(dlgs[free_slot],"Race/Advantages/Disadvantages"); break; + + case 1010: SetWindowText(dlgs[free_slot],"Training a PC"); break; + case 1014: SetWindowText(dlgs[free_slot],"Reading a Sign"); break; + case 1017: SetWindowText(dlgs[free_slot],"Blades of Exile"); break; + case 1018: SetWindowText(dlgs[free_slot],"Select a PC"); break; + case 1019: SetWindowText(dlgs[free_slot],"Character Statistics"); break; + case 1020: SetWindowText(dlgs[free_slot],"In a Shop"); break; + case 1021: SetWindowText(dlgs[free_slot],"Buying Food"); break; + case 1047: SetWindowText(dlgs[free_slot],"Select Alchemy"); break; + case 1048: SetWindowText(dlgs[free_slot],"Visiting the Healer"); break; + case 1050: SetWindowText(dlgs[free_slot],"Pick PC Graphic"); break; + case 1051: SetWindowText(dlgs[free_slot],"Pick PC Name"); break; + case 1096: SetWindowText(dlgs[free_slot],"Spells Help"); break; + case 1097: SetWindowText(dlgs[free_slot],"Skills Help"); break; + case 1098: SetWindowText(dlgs[free_slot],"Cast a Spell"); break; + case 1099: SetWindowText(dlgs[free_slot],"Preferences"); break; + default: SetWindowText(dlgs[free_slot],"Blades of Exile"); break; + } + ShowWindow(dlgs[free_slot],SW_SHOW); + DestroyWindow(dlg); //Necesary? Dunno. + + if (dlg_parent[free_slot] != NULL) { + EnableWindow(dlg_parent[free_slot],FALSE); + } + dialog_not_toast = TRUE; + return 0; +} + +BOOL CALLBACK dummy_dialog_proc(HWND hDlg, UINT message, WPARAM, LPARAM) +{ + short i,j,k,free_slot = -1,free_item = -1; + int type,flag; + char item_str[256]; + Boolean str_stored = FALSE; + RECT dlg_rect; + short win_height = 0, win_width = 0; + short str_offset = 1; + + free_slot = store_free_slot; + + switch (message) { + case WM_INITDIALOG: + + // now, make a window, matching dialog + GetWindowRect(hDlg,&dlg_rect); + dlgs[store_free_slot] = CreateWindow (szWinName, + "Blades of Exile Dialog", + 0,// was visible + 0, + 0, + dlg_rect.right - dlg_rect.left, + dlg_rect.bottom - dlg_rect.top, + NULL, + NULL, + store_hInstance, + NULL); + // Now, give the window its items + for (i = 0; i < 200; i++) + if (GetDlgItem(hDlg,i) != NULL) { + GetDlgItemText(hDlg,i,item_str,256); + str_offset = 1; + dlg_highest_item[free_slot] = i; + str_stored = FALSE; + if (strlen((char *)item_str) == 0) { + sprintf((char *) item_str, "+"); + type = 3; + flag = 0; + str_stored = TRUE; + } + else if (item_str[0] == '+') { // default is framed text + type = 3; + flag = 1; + str_stored = TRUE; + } + else if (item_str[0] == '*') { + type = 3; + flag = 0; + str_stored = TRUE; + } + else if (item_str[0] == '~') { + type = 7; + flag = 0; + str_stored = TRUE; + } + else if (item_str[0] == '!') { + type = 4; + flag = 0; + str_stored = TRUE; + } + else if (item_str[0] == '=') { + type = 9; + flag = 1; + str_stored = TRUE; + } + else if (((item_str[0] >= 65) && (item_str[0] <= 122)) || (item_str[0] == '"')) { + type = 9; + flag = 0; + str_offset = 0; + str_stored = TRUE; + } + else if ((item_str[0] == '^') || (item_str[0] == '&')) { + type = (item_str[0] == '^') ? 10 : 11; + flag = 1; + //if (string_length((char *) item_str) > 55) + // flag = 2; + str_stored = TRUE; + } + else + { + //sscanf(item_str,"%d_%d",&type,&flag); + type = atoi(item_str); + flag = atoi(item_str+2); + } + + free_item = -1; + // find free item + switch (type) { + case 0: case 1: case 2: case 5: case 6: + for (j = 150; j < NI; j++) + if (item_dlg[j] < 0) { + free_item = j; + j = NI + 1; + } + break; + default: + if ((type == 9) || + ((str_stored == TRUE) && (strlen((char *) item_str) > 35))) { + for (j = 0; j < 10; j++) + if (item_dlg[j] < 0) { + free_item = j; + j = NI + 1; + } + } + else { + for (j = 10; j < 140; j++) + if (item_dlg[j] < 0) { + free_item = j; + j = NI + 1; + } + } + break; + } + + if (free_item >= 0) { + item_dlg[free_item] = store_dlog_num; + item_type[free_item] = type; + item_number[free_item] = i; + + item_rect[free_item] = get_item_rect(hDlg,i); + item_rect[free_item].top = item_rect[free_item].top / 2; + item_rect[free_item].left = item_rect[free_item].left / 2; + item_rect[free_item].bottom = item_rect[free_item].bottom / 2; + item_rect[free_item].right = item_rect[free_item].right / 2; + + if ((type != 5) && ((store_dlog_num >= 2000) || (store_dlog_num == 986))) { + item_rect[free_item].top = + (item_rect[free_item].top * 11) / 10; + item_rect[free_item].bottom = + (item_rect[free_item].bottom * 11) / 10; + } + + item_flag[free_item] = flag; + item_active[free_item] = 1; + item_label[free_item] = 0; + item_label_loc[free_item] = -1; + item_key[free_item] = 0; + + switch (type) { + case 0: case 1: + if (item_flag[free_item] != 143) { + item_rect[free_item].right = item_rect[free_item].left + button_width[button_type[flag]]; + item_rect[free_item].bottom = item_rect[free_item].top + button_height[button_type[flag]]; + + item_key[free_item] = button_def_key[flag]; + if (type == 1) + item_key[free_item] = 31; + } + break; + case 2: + item_rect[free_item].right = item_rect[free_item].left + 14; + item_rect[free_item].bottom = item_rect[free_item].top + 10; + item_key[free_item] = 255; + break; + case 3: case 4: case 7: case 8: case 9: case 10: case 11: + sprintf(((free_item < 10) ? text_long_str[free_item] : text_short_str[free_item - 10]),""); + if (str_stored == TRUE) { + if (free_item < 10) { + sprintf(text_long_str[free_item],"%s", + (char *) (item_str + str_offset)); + for (k = 0; k < 256; k++) { + if (text_long_str[free_item][k] == '|') + text_long_str[free_item][k] = 13; + if (text_long_str[free_item][k] == '_') + text_long_str[free_item][k] = '"'; + } + // give text a little extra room + //if ((store_dlog_num >= 2000) || (store_dlog_num == 986)) + // item_rect[free_item].right += 20; + } + else { + sprintf(text_short_str[free_item - 10],"%-34s", + (char *) (item_str + str_offset)); + for (k = 0; k < 35; k++) { + if (text_short_str[free_item][k] == '|') + text_short_str[free_item][k] = 13; + if (text_short_str[free_item][k] == '_') + text_short_str[free_item][k] = '"'; + } + } + } + item_key[free_item] = 255; + break; + case 6: + edit_box = CreateWindow("edit",NULL,WS_CHILD | WS_BORDER | WS_VISIBLE, + item_rect[free_item].left,item_rect[free_item].top, + item_rect[free_item].right - item_rect[free_item].left, + max(22,item_rect[free_item].bottom - item_rect[free_item].top), + dlgs[free_slot],(HMENU) 150,store_hInstance,NULL); + store_edit_parent = dlgs[free_slot]; + old_edit_proc = (WNDPROC) GetWindowLong(edit_box,GWL_WNDPROC); + SetWindowLong(edit_box,GWL_WNDPROC,(LONG) edit_proc); + break; + } + win_height = max(win_height, item_rect[free_item].bottom + 28); + win_width = max(win_width, item_rect[free_item].right + 11); + + } + + } + MoveWindow(dlgs[free_slot],0,0,win_width,win_height,FALSE); + EndDialog(hDlg, 0); + return TRUE; + } + return TRUE; + } + +void cd_set_edit_focus() +{ if (edit_box != NULL) + SetFocus(edit_box); +} + +short cd_kill_dialog(short dlog_num,short parent_message) +{ + short i,which_dlg = -1; + + for (i = 0; i < ND; i++) + if ((dlg_keys[i] >= 0) && (dlg_types[i] == dlog_num)) + which_dlg = i; + if (which_dlg < 0) + return -1; + + for (i = 0; i < NI; i++) + if (item_dlg[i] == dlog_num) { + if (item_type[i] == 6) { + DestroyWindow(edit_box); + edit_box = NULL; + } + if (item_label[i] > 0) + label_taken[item_label_loc[i]] = FALSE; + item_dlg[i] = -1; + } + + if (dlg_parent[which_dlg] != NULL) { + EnableWindow(dlg_parent[which_dlg],TRUE); + + SetFocus(dlg_parent[which_dlg]); + SetWindowPos(dlg_parent[which_dlg],HWND_TOP,0,0,100,100, + SWP_NOMOVE | SWP_NOSIZE | SWP_NOREDRAW); + cd_set_edit_focus(); + } + + if (parent_message > 0) + SendMessage(dlg_parent[which_dlg],WM_COMMAND,parent_message,0); + +DestroyWindow(dlgs[which_dlg]); + dlg_keys[which_dlg] = -1; + dialog_not_toast = TRUE; + block_erase = TRUE; + return 0; +} + +short cd_process_click(HWND window,POINT the_point, WPARAM wparam, LPARAM,short *item) +{ + short i,which_dlg,dlg_num,item_id; + short dlog_key; + + if ((which_dlg = cd_find_dlog(window,&dlg_num,&dlog_key)) < 0) + return -1; + + + for (i = 0; i < dlg_highest_item[which_dlg] + 1; i++) + if ((item_id = cd_get_item_id(dlg_num,i)) >= 0) { + if ((PtInRect(&item_rect[item_id],the_point)) && (item_active[item_id] > 0) + && ((item_type[item_id] < 3) || (item_type[item_id] == 8) + || (item_type[item_id] == 10)|| (item_type[item_id] == 11))) { + *item = i; + if (MK_CONTROL & wparam) + *item += 100; + if (item_type[item_id] != 8) + cd_press_button(dlg_num,i); + return dlg_num; + } + } + return -1; +} + +short cd_process_syskeystroke(HWND window, WPARAM wparam, LPARAM, short *item) +{ + short i,which_dlg,dlg_num,dlg_key,item_id; + char char_hit; + + + if ((which_dlg = cd_find_dlog(window,&dlg_num,&dlg_key)) < 0) + return -1; + // specials ... 20 - <- 21 - -> 22 up 23 down 24 esc + // 25-30 ctrl 1-6 + + switch (wparam) { + case VK_ESCAPE: + char_hit = 24; + break; + case VK_LEFT: + char_hit = 20; + break; + case VK_UP: + char_hit = 22; + break; + case VK_RIGHT: + char_hit = 21; + break; + case VK_DOWN: + char_hit = 23; + break; + case VK_RETURN: + char_hit = 31; + break; + default: + return -1; + } + + for (i = 0; i < dlg_highest_item[which_dlg] + 1; i++) + if ((item_id = cd_get_item_id(dlg_num,i)) >= 0) { + if ((item_key[item_id] == char_hit) && (item_active[item_id] > 0) + && ((item_type[item_id] < 3) || (item_type[item_id] == 8))) { + *item = i; + if (item_type[item_id] != 8) + cd_press_button(dlg_num,i); + return dlg_num; + } + } + // kludgy. If you get an escape and is isn't processed, make it an enter + if (wparam == VK_ESCAPE) { + char_hit = 31; + for (i = 0; i < dlg_highest_item[which_dlg] + 1; i++) + if ((item_id = cd_get_item_id(dlg_num,i)) >= 0) { + if ((item_key[item_id] == char_hit) && (item_active[item_id] > 0) + && ((item_type[item_id] < 3) || (item_type[item_id] == 8))) { + *item = i; + if (item_type[item_id] != 8) + cd_press_button(dlg_num,i); + return dlg_num; + } + } + } + + return -1; +} + +short cd_process_keystroke(HWND window, WPARAM wparam, LPARAM, short *item) +{ + short i,which_dlg,dlg_num,dlg_key,item_id; + char char_hit; + + if ((which_dlg = cd_find_dlog(window,&dlg_num,&dlg_key)) < 0) + return -1; + // specials ... 20 - <- 21 - -> 22 up 23 down 24 esc + // 25-30 ctrl 1-6 + + char_hit = (char) wparam; + + for (i = 0; i < dlg_highest_item[which_dlg] + 1; i++) + if ((item_id = cd_get_item_id(dlg_num,i)) >= 0) { + if ((item_key[item_id] == char_hit) && (item_active[item_id] > 0) + && ((item_type[item_id] < 3) || (item_type[item_id] == 8))) { + *item = i; + if (item_type[item_id] != 8) + cd_press_button(dlg_num,i); + return dlg_num; + } + } + return -1; +} + +void cd_init_button(short dlog_num,short item_num, short button_num, short status) +{ + short dlg_index,item_index; + + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return; + if (item_type[item_index] > 1) { + play_sound(0); + return; + } + item_flag[item_index] = button_num; + item_active[item_index] = status; + item_rect[item_index].right = item_rect[item_index].left + button_width[button_num]; + item_rect[item_index].bottom = item_rect[item_index].top + button_width[button_num]; + item_key[item_index] = button_def_key[button_num]; + cd_draw_item(dlog_num,item_num); +} + +void cd_attach_key(short dlog_num,short item_num,char key) +{ + short dlg_index,item_index; + + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return; + + if ((item_type[item_index] > 2) && (item_type[item_index] != 8)) { + play_sound(0); + return; + } + item_key[item_index] = key; +} + +void cd_set_pict(short dlog_num, short item_num, short pict_num) +{ + short dlg_index,item_index; + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return; + if (item_type[item_index] != 5) { + play_sound(0); + return; + } + item_flag[item_index] = pict_num; + if (pict_num == -1) + cd_erase_item(dlog_num,item_num); + else cd_draw_item(dlog_num,item_num); +} + +void cd_activate_item(short dlog_num, short item_num, short status) +{ + short dlg_index,item_index; + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return; + + item_active[item_index] = status; + cd_draw_item(dlog_num,item_num); +} + +short cd_get_active(short dlog_num, short item_num) +{ + short dlg_index,item_index; + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return -1; + + return item_active[item_index]; +} + + +void cd_get_item_text(short dlog_num, short item_num, char *str) +{ + short dlg_index,item_index; + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return ; + if (item_type[item_index] == 6) { + //print_nums(0,0,GetWindowText(edit_box,str,255)); + if (edit_box != NULL) + GetWindowText(edit_box,str,255); + else sprintf(str,""); + //add_string_to_buf(str); + return; + } + if (item_index >= 150) { + play_sound(0); + return; + } + if (item_index < 10) + sprintf(str,"%s",text_long_str[item_index]); + else sprintf(str,"%s",text_short_str[item_index - 10]); +} + +void cd_get_text_edit_str(short, char *str) +{ + if (edit_box != NULL) + GetWindowText(edit_box,str,255); + else str[0] = 0; +} +// NOTE!!! Expects a c string +void cd_set_text_edit_str(short, char *str) +{ + if (edit_box != NULL) + SetWindowText(edit_box,str); +} +void cdsin(short dlog_num, short item_num, short num) +{ + cd_set_item_num( dlog_num, item_num, num); +} +void csit(short dlog_num, short item_num, char *str) +{ +cd_set_item_text( dlog_num, item_num, str); +} +void csp(short dlog_num, short item_num, short pict_num) +{ + cd_set_pict( dlog_num, item_num, pict_num); +} + + +void cd_set_item_text(short dlog_num, short item_num, char *str) +{ + short k,dlg_index,item_index; + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return ; + if (item_type[item_index] == 6) { + if (edit_box != NULL) + SetWindowText(edit_box,str); + return; + } + if (item_index >= 150) { + play_sound(0); + return; + } + if (item_index < 10) { + sprintf(text_long_str[item_index],"%s",str); + for (k = 0; k < 256; k++) { + if (text_long_str[item_index][k] == '|') + text_long_str[item_index][k] = 13; + if (text_long_str[item_index][k] == '_') + text_long_str[item_index][k] = '"'; + } + + } + else sprintf(text_short_str[item_index - 10],"%-34s",str); + cd_draw_item( dlog_num,item_num); +} + +void cd_set_item_num(short dlog_num, short item_num, short num) +{ + short dlg_index,item_index; + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return ; + if (item_index >= 150) { + play_sound(0); + return; + } + if (item_index < 10) + sprintf(text_long_str[item_index],"%d",num); + else sprintf(text_short_str[item_index - 10],"%d",num); + cd_draw_item( dlog_num,item_num); +} + +void cd_set_flag(short dlog_num,short item_num,short flag) +{ + short dlg_index,item_index; + + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return; + + item_flag[item_index] = flag; + cd_draw_item(dlog_num,item_num); +} + +void cd_set_led(short dlog_num,short item_num,short state) +{ + short dlg_index,item_index; + + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return; + + if (item_type[item_index] != 2) { + play_sound(0); + return; + } + item_flag[item_index] = state; + cd_draw_item(dlog_num,item_num); +} + +short cd_get_led(short dlog_num,short item_num) +{ + short dlg_index,item_index; + + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return 0; + + if (item_type[item_index] != 2) { + play_sound(0); + return 0; + } + return item_flag[item_index]; +} + + +void cd_text_frame(short dlog_num,short item_num,short frame) +{ + short dlg_index,item_index; + + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return; + + if (item_index >= 150) { + play_sound(0); + return; + } + item_flag[item_index] = frame; + cd_draw_item(dlog_num,item_num); +} + +void cd_add_label(short dlog_num, short item_num, char *label, short label_flag) +{ + short dlg_index,item_index,label_loc = -1; + short i; + + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return; + + if (item_label_loc[item_index] < 0) { + item_label[item_index] = label_flag; + for (i = 0; i < 100; i++) + if (label_taken[i] == FALSE) { + label_loc = i; + label_taken[i] = TRUE; + i = 100; + } + if (label_loc < 0) { + play_sound(0); + return; + } + item_label_loc[item_index] = label_loc; + } + else cd_erase_item(dlog_num,item_num + 100); + label_loc = item_label_loc[item_index]; + sprintf((char *) labels[label_loc],"%-24s",label); + if (item_active[item_index] > 0) + cd_draw_item(dlog_num,item_num); +} + +void cd_take_label(short dlog_num, short item_num) +{ + short dlg_index,item_index; + + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return; + item_label[item_index] = 0; + label_taken[item_label_loc[item_index]] = FALSE; +} + +void cd_key_label(short dlog_num, short item_num,short loc) +{ + short dlg_index,item_index; + char str[10]; + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return; + sprintf((char *) str," "); + str[0] = item_key[item_index]; + cd_add_label(dlog_num,item_num, str, 7 + loc * 100); +} + +void cd_draw_item(short dlog_num,short item_num) +{ + short dlg_index,item_index,store_label; + HDC win_dc; + COLORREF colors[4] = {RGB(0,0,0),RGB(255,0,0),RGB(0,0,102),RGB(255,255,255)}; + //UINT c[4]; + RECT from_rect,to_rect; + HFONT old_font; + + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return; + if (dlg_draw_ready[dlg_index] == FALSE) + return; + + /*c[0] = GetNearestPaletteIndex(hpal,colors[0]); + c[1] = GetNearestPaletteIndex(hpal,colors[1]); + c[2] = GetNearestPaletteIndex(hpal,colors[2]); + c[3] = GetNearestPaletteIndex(hpal,colors[3]);*/ + win_dc = cd_get_dlog_dc(dlg_index); + old_font = (HFONT) SelectObject(win_dc,small_bold_font); + dlg_force_dc = win_dc; + + if (item_active[item_index] == 0) { + cd_erase_item(dlog_num,item_num); + cd_erase_item(dlog_num,item_num + 100); + } + else { + switch (item_type[item_index]) { + case 0: case 1: case 10: case 11: + if (item_flag[item_index] == 143) + break; + from_rect.top = button_ul_y[button_type[item_flag[item_index]]]; + from_rect.left = button_ul_x[button_type[item_flag[item_index]]]; + from_rect.bottom = from_rect.top + button_height[button_type[item_flag[item_index]]]; + from_rect.right = from_rect.left + button_width[button_type[item_flag[item_index]]]; + rect_draw_some_item(dlg_buttons_gworld,from_rect,(HBITMAP)win_dc,item_rect[item_index],0,2); + + SelectObject(win_dc,bold_font); + SetTextColor(win_dc,colors[2]); + if (item_type[item_index] < 2) + OffsetRect(&item_rect[item_index],-1 * button_left_adj[item_flag[item_index]],0); + if (item_type[item_index] < 2) { + char_win_draw_string(win_dc,item_rect[item_index], + (char *) (button_strs[item_flag[item_index]]),1,8); + } + else { + char_win_draw_string(win_dc,item_rect[item_index], + (char *) ((item_index < 10) ? text_long_str[item_index] : + text_short_str[item_index - 10]),1,8); + } + if (item_type[item_index] < 2) + OffsetRect(&item_rect[item_index],button_left_adj[item_flag[item_index]],0); + SetTextColor(win_dc,colors[0]); + + break; + + case 2: + switch (item_flag[item_index]) { + case 0: from_rect.left = 166; from_rect.top = 36; break; + case 1: from_rect.left = 152; from_rect.top = 36; break; + case 2: from_rect.left = 138; from_rect.top = 36; break; + } + from_rect.right = from_rect.left + 14; + from_rect.bottom = from_rect.top + 10; + rect_draw_some_item( dlg_buttons_gworld,from_rect,(HBITMAP) win_dc,item_rect[item_index],0,2); break; + break; + + case 3: case 4: case 7: case 8: case 9: + cd_erase_item(dlog_num,item_num); + SetTextColor(win_dc,colors[3]); + if ((item_type[item_index] == 3) || (item_type[item_index] == 9)) + SelectObject(win_dc,small_bold_font); + if (item_type[item_index] == 4) + SelectObject(win_dc,tiny_font); + if (item_type[item_index] == 7) + SelectObject(win_dc,bold_font); + if (item_flag[item_index] % 10 == 1) + cd_frame_item(dlog_num,item_num,2); + if (item_flag[item_index] >= 10) { + SetTextColor(win_dc,colors[1]); + } + + if (item_rect[item_index].bottom - item_rect[item_index].top < 20) { + item_rect[item_index].left += 3; + DrawText(win_dc,(char *) ((item_index < 10) ? text_long_str[item_index] : + text_short_str[item_index - 10]), -1, &item_rect[item_index], + DT_LEFT | DT_SINGLELINE | DT_VCENTER | DT_NOCLIP); + item_rect[item_index].left -= 3; + } + else { + InflateRect(&item_rect[item_index],-4,-4); + DrawText(win_dc,(char *) ((item_index < 10) ? text_long_str[item_index] : + text_short_str[item_index - 10]), -1, &item_rect[item_index], + DT_LEFT | DT_WORDBREAK | DT_NOCLIP); + InflateRect(&item_rect[item_index],4,4); + } + SetTextColor(win_dc,colors[0]); + break; + case 5: + if (item_flag[item_index] == -1) + cd_erase_item(dlog_num,item_num); + else draw_dialog_graphic(dlgs[dlg_index], item_rect[item_index], + item_flag[item_index],(item_flag[item_index] >= 2000) ? FALSE : TRUE,0); + break; + } + } + + if (item_label[item_index] != 0) { + store_label = item_label[item_index]; + if (store_label >= 1000) { + store_label -= 1000; + SelectObject(win_dc,bold_font); + } + else SelectObject(win_dc,tiny_font); + to_rect = item_rect[item_index]; + switch (store_label / 100) { + case 0: + to_rect.right = to_rect.left; + to_rect.left -= 2 * (store_label % 100); + break; + case 1: + to_rect.bottom = to_rect.top; + to_rect.top -= 2 * (store_label % 100); + break; + case 2: + to_rect.left = to_rect.right; + to_rect.right += 2 * (store_label % 100); + break; + case 3: + to_rect.top = to_rect.bottom; + to_rect.bottom += 2 * (store_label % 100); + break; + } + + if (to_rect.bottom - to_rect.top < 14) { + to_rect.bottom += (14 - (to_rect.bottom - to_rect.top)) / 2 + 1; + to_rect.top -= (14 - (to_rect.bottom - to_rect.top)) / 2 + 1; + } + //cd_erase_rect(dlog_num,to_rect); + if (item_active[item_index] != 0) { + SetTextColor(win_dc,colors[3]); + + DrawText(win_dc, (char *) labels[item_label_loc[item_index]], + -1, &to_rect, DT_LEFT | DT_SINGLELINE | DT_VCENTER); + SetTextColor(win_dc,colors[0]); + + } + } + + + SelectObject(win_dc,old_font); + cd_kill_dc(dlg_index,win_dc); + dlg_force_dc = NULL; + } + +void cd_initial_draw(short dlog_num) +{ + short i,which_dlg = -1; + + for (i = 0; i < ND; i++) + if ((dlg_keys[i] >= 0) && (dlg_types[i] == dlog_num)) + which_dlg = i; + if (which_dlg < 0) + return; + dlg_draw_ready[which_dlg] = TRUE; + + cd_erase_item(dlog_num, 0); + cd_draw(dlog_num); +} + +void cd_draw(short dlog_num) +{ + short i,which_dlg = -1; + + for (i = 0; i < ND; i++) + if ((dlg_keys[i] >= 0) && (dlg_types[i] == dlog_num)) + which_dlg = i; + if (which_dlg < 0) + return; + + for (i = 0; i < dlg_highest_item[which_dlg] + 1; i++) { + cd_draw_item(dlog_num,i); + } +} + +void cd_redraw(HWND window) +{ + short which_dlg,dlg_num,dlg_key; + + if ((which_dlg = cd_find_dlog(window,&dlg_num,&dlg_key)) < 0) + return; + dlg_draw_ready[which_dlg] = TRUE; + cd_initial_draw(dlg_num); +} + +void cd_frame_item(short dlog_num, short item_num, short width) +{ + short dlg_index,item_index; + + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return; + frame_dlog_rect(dlgs[dlg_index], item_rect[item_index], width); +} + +void cd_erase_item(short dlog_num, short item_num) +// if item_num is 0, nail whole window +// item_num + 100 just erase label +{ + short i,dlg_index,item_index,store_label; + RECT to_fry; + HDC win_dc; + Boolean just_label = FALSE; + + if (item_num >= 100) { + item_num -= 100; + just_label = TRUE; + } + + if (item_num == 0) { + for (i = 0; i < ND; i++) + if ((dlg_keys[i] >= 0) && (dlg_types[i] == dlog_num)) + dlg_index = i; + GetWindowRect(dlgs[dlg_index],&to_fry); + OffsetRect(&to_fry,-1 * to_fry.left,-1 * to_fry.top); + } + else { + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return; + to_fry = item_rect[item_index]; + if (just_label == TRUE) { + if (item_label[item_index] != 0) { + store_label = item_label[item_index]; + if (store_label >= 1000) + store_label -= 1000; + + switch (store_label / 100) { + case 0: + to_fry.right = to_fry.left; + to_fry.left -= 2 * (store_label % 100); + break; + case 1: + to_fry.bottom = to_fry.top; + to_fry.top -= 2 * (store_label % 100); + break; + case 2: + to_fry.left = to_fry.right; + to_fry.right += 2 * (store_label % 100); + break; + case 3: + to_fry.top = to_fry.bottom; + to_fry.bottom += 2 * (store_label % 100); + break; + } + if ((i = 12 - (to_fry.bottom - to_fry.top)) > 0) { + // adjust rect ... but doesn't work for bold letters + to_fry.bottom += i / 2; + to_fry.bottom++; // extra pixel to get dangly letters + to_fry.top -= i / 2; + } + } + } + InflateRect(&to_fry,1,1); + + } + if (dlg_draw_ready[dlg_index] == FALSE) + return; + win_dc = cd_get_dlog_dc(dlg_index); + paint_pattern((HBITMAP)win_dc,2,to_fry,0); + cd_kill_dc(dlg_index,win_dc); +} + +void cd_erase_rect(short dlog_num,RECT to_fry) +{ + short dlg_index; + HDC win_dc; + + if ((dlg_index = cd_get_dlg_index(dlog_num)) < 0) + return; + if (dlg_draw_ready[dlg_index] == FALSE) + return; + + win_dc = cd_get_dlog_dc(dlg_index); + paint_pattern((HBITMAP)win_dc,2,to_fry,0); + cd_kill_dc(dlg_index,win_dc); +} + +void cd_press_button(short dlog_num, short item_num) +{ + short dlg_index,item_index; + long dummy; + HDC win_dc; + RECT from_rect; + COLORREF colors[3] = {RGB(0,0,0),RGB(0,0,112),RGB(0,255,255)}; + //UINT c[3]; + + if (cd_get_indices(dlog_num,item_num,&dlg_index,&item_index) < 0) + return; + // no press action for redio buttons + if ((item_type[item_index] == 2) || (item_flag[item_index] == 143)) { + play_sound(34); + return; + } + + /*c[0] = GetNearestPaletteIndex(hpal,colors[0]); + c[1] = GetNearestPaletteIndex(hpal,colors[1]); + c[2] = GetNearestPaletteIndex(hpal,colors[2]);*/ + win_dc = cd_get_dlog_dc(dlg_index); + + from_rect.top = button_ul_y[button_type[item_flag[item_index]]]; + from_rect.left = button_ul_x[button_type[item_flag[item_index]]]; + from_rect.bottom = from_rect.top + button_height[button_type[item_flag[item_index]]]; + from_rect.right = from_rect.left + button_width[button_type[item_flag[item_index]]]; + OffsetRect(&from_rect,button_width[button_type[item_flag[item_index]]],0); + + rect_draw_some_item(dlg_buttons_gworld,from_rect,(HBITMAP) win_dc,item_rect[item_index],0,2); + + SelectObject(win_dc,bold_font); + SetTextColor(win_dc,colors[2]); + if (item_type[item_index] < 2) + OffsetRect(&item_rect[item_index],-1 * button_left_adj[item_flag[item_index]],0); + if (item_type[item_index] < 2) { + char_win_draw_string(win_dc,item_rect[item_index], + (char *) (button_strs[item_flag[item_index]]),1,8); + } + else { + char_win_draw_string(win_dc,item_rect[item_index], + (char *) ((item_index < 10) ? text_long_str[item_index] : + text_short_str[item_index - 10]),1,8); + } + if (item_type[item_index] < 2) + OffsetRect(&item_rect[item_index],button_left_adj[item_flag[item_index]],0); + + if (play_sounds == TRUE) { + play_sound(37); + Delay(6,&dummy); + } + else Delay(10,&dummy); + + OffsetRect(&from_rect,-1 * button_width[button_type[item_flag[item_index]]],0); + rect_draw_some_item(dlg_buttons_gworld,from_rect,(HBITMAP)win_dc,item_rect[item_index],0,2); + + SelectObject(win_dc,bold_font); + SetTextColor(win_dc,colors[1]); + if (item_type[item_index] < 2) + OffsetRect(&item_rect[item_index],-1 * button_left_adj[item_flag[item_index]],0); + if (item_type[item_index] < 2) { + char_win_draw_string(win_dc,item_rect[item_index], + (char *) (button_strs[item_flag[item_index]]),1,8); + } + else { + char_win_draw_string(win_dc,item_rect[item_index], + (char *) ((item_index < 10) ? text_long_str[item_index] : + text_short_str[item_index - 10]),1,8); + } + if (item_type[item_index] < 2) + OffsetRect(&item_rect[item_index],button_left_adj[item_flag[item_index]],0); + + SelectObject(win_dc,font); + SetTextColor(win_dc,colors[0]); + + cd_kill_dc(dlg_index,win_dc); + } + +// LOW LEVEL + +short cd_get_indices(short dlg_num, short item_num, short *dlg_index, short *item_index) +{ + if ((*dlg_index = cd_get_dlg_index(dlg_num)) < 0) { + return -1; + } + if ((*item_index = cd_get_item_id(dlg_num,item_num)) < 0) { + return -1; + } + return 0; + } + +short cd_get_dlg_index(short dlog_num) +{ + short i; + + for (i = 0; i < ND; i++) + if ((dlg_keys[i] >= 0) && (dlg_types[i] == dlog_num)) + return i; + return -1; +} + +short cd_find_dlog(HWND window, short *dlg_num, short *dlg_key) +{ + short i; + for (i = 0; i < ND; i++) + if ((dlg_keys[i] >= 0) && (dlgs[i] == window)) { + *dlg_num = dlg_types[i]; + *dlg_key = dlg_keys[i]; + return i; + } + return -1; +} + +short cd_get_item_id(short dlg_num, short item_num) +{ + short i; + + for (i = 0; i < NI; i++) + if ((item_dlg[i] == dlg_num) && (item_number[i] == item_num)) + return i; + return -1; +} + +HDC cd_get_dlog_dc(short which_slot) +{ + HDC win_dc; + + win_dc = GetDC(dlgs[which_slot]); + + //SelectPalette(win_dc,hpal,0); + SetBkMode(win_dc,TRANSPARENT); + return win_dc; + } + +void cd_kill_dc(short which_slot,HDC hdc) +{ + fry_dc(dlgs[which_slot],hdc); +} + +// External graphics tools (huh huh huh ... tool ... huh huh huh) + +void center_window(HWND window) +{ + RECT main_rect,wind_rect; + short width,height; + + cursor_shown = TRUE; + showcursor(TRUE); + + GetWindowRect(GetDesktopWindow(),&main_rect); + GetWindowRect(window,&wind_rect); + width = wind_rect.right - wind_rect.left; + height = wind_rect.bottom - wind_rect.top; + MoveWindow(window,((main_rect.right - main_rect.left) - width) / 2, + ((main_rect.bottom - main_rect.top) - height) / 2,width,height,TRUE); + +} + +RECT get_item_rect(HWND hDlg, short item_num) +{ + HWND item; + RECT big_rect,small_rect; + + item = GetDlgItem(hDlg, item_num); + GetWindowRect(hDlg,&big_rect); + GetWindowRect(item,&small_rect); + OffsetRect(&small_rect, -1 * big_rect.left - 7, -1 * big_rect.top - 7); + small_rect.right += 2; + small_rect.bottom += 2; + return small_rect; +} + + +void frame_dlog_rect(HWND hDlg, RECT rect, short val) +{ + HDC hdc; + HPEN dpen,lpen,old_pen; + COLORREF x = RGB(0,204,255),y = RGB(0,204,255);//y = RGB(119,119,119); + //UINT c; + Boolean keep_dc = FALSE; + + InflateRect(&rect,val,val); + + if (hDlg == mainPtr) { + keep_dc = TRUE; + hdc = main_dc; + OffsetRect(&rect,ulx,uly); + } + else if (dlg_force_dc != NULL) { + hdc = dlg_force_dc; + keep_dc = TRUE; + } + else hdc = GetDC(hDlg); + if (hdc == NULL) { + play_sound(0); + return; + } + //SelectPalette(hdc,hpal,0); + //c = GetNearestPaletteIndex(hpal,x); + lpen = CreatePen(PS_SOLID,1,x); + //c = GetNearestPaletteIndex(hpal,y); + dpen = CreatePen(PS_SOLID,1,y); + old_pen = (HPEN) SelectObject(hdc,dpen); + MoveToEx(hdc,rect.left,rect.top, NULL); + LineTo(hdc,rect.right,rect.top); + SelectObject(hdc,lpen); + LineTo(hdc,rect.right,rect.bottom); + LineTo(hdc,rect.left,rect.bottom); + SelectObject(hdc,dpen); + LineTo(hdc,rect.left,rect.top); + SelectObject(hdc,old_pen); + if (keep_dc == FALSE) + fry_dc(hDlg,hdc); + DeleteObject(dpen); + DeleteObject(lpen); +} + +void draw_dialog_graphic(HWND hDlg, RECT rect, short which_g, Boolean do_frame,short win_or_gworld) +// win_or_gworld: 0 - window 1 - an HBITMAP +// 1 means hDlg is actually an HBITMAP variable! +// 0 - 300 number of terrain graphic +// 400 + x - monster graphic num +// 600 + x item graphic +// 700 + x dlog graphic +// 800 + x pc graphic +// 900 + x B&W graphic +// 950 null item +// 1000 + x Talking face +// 1100 - item info help +// 1200 - pc screen help +// 1300 - combat ap +// 1400-1402 - button help +// 1500 - stat symbols help +// 1600 + x - B&W maps +// 1700 + x - anim graphic +{ + RECT from2 = {0,0,36,36}; + RECT from_rect = {0,0,28, 36}; + RECT pc_info_from = {0,127,106,157}; + RECT item_info_from = {174,0,312,112}; + RECT button_help_from = {0,0,320,100}; + RECT large_scen_from = {0,0,64,64}; + + HBITMAP from_gworld; + short draw_dest = 2; + HDC hdc; + + + + if (win_or_gworld == 1) + draw_dest = 0; + + if (which_g < 0) + return; + + if (which_g >= 3000) + do_frame = FALSE; + which_g = which_g % 3000; + + if (win_or_gworld == 0) { + if (dlg_force_dc != NULL) + hdc = dlg_force_dc; + else hdc = GetDC(hDlg); + //SelectPalette(hdc,hpal,0); + } + if (which_g == 950) { // Empty. Maybe clear space. + if (win_or_gworld == 0) { + paint_pattern((HBITMAP)hdc,2,rect,0); + } + if (dlg_force_dc == NULL) + fry_dc(hDlg, hdc); + return; + } + + switch (which_g / 100) { + + case 7: // dialog + which_g -= 700; + from_gworld = dlogpics_gworld; + OffsetRect(&from2,36 * (which_g % 4),36 * (which_g / 4)); + rect_draw_some_item(from_gworld,from2,(HBITMAP) ((win_or_gworld == 1) ? (HBITMAP)hDlg: (HBITMAP)hdc) + ,rect,0,draw_dest); + break; + case 11: // item info help + from_rect = item_info_from; + rect.right = rect.left + from_rect.right - from_rect.left; + rect.bottom = rect.top + from_rect.bottom - from_rect.top; + rect_draw_some_item(mixed_gworld,from_rect,(HBITMAP) ((win_or_gworld == 1) ? (HBITMAP)hDlg: (HBITMAP)hdc) + ,rect,0,draw_dest); + break; + case 12: // item info help + from_rect = pc_info_from; + rect.right = rect.left + pc_info_from.right - pc_info_from.left; + rect.bottom = rect.top + pc_info_from.bottom - pc_info_from.top; + rect_draw_some_item(mixed_gworld,from_rect,(HBITMAP) ((win_or_gworld == 1) ? (HBITMAP)hDlg: (HBITMAP)hdc) + ,rect,0,draw_dest); + break; + case 14: // button help + which_g -= 1400; + if (which_g >= 10) { + from_gworld = load_pict(900 + which_g,hdc); + from_rect = large_scen_from; + OffsetRect(&from_rect,64 * (which_g % 10),0); + rect_draw_some_item(from_gworld,from_rect,(HBITMAP) ((win_or_gworld == 1) ? (HBITMAP)hDlg: (HBITMAP)hdc) + ,rect,0,draw_dest); + DeleteObject(from_gworld); + break; + } + from_gworld = load_pict(1401,hdc); + from_rect = button_help_from; + rect.top += 10; + rect.right = rect.left + from_rect.right; + rect.bottom = rect.top + from_rect.bottom; + OffsetRect(&from_rect,0,100 * which_g); + rect_draw_some_item(from_gworld,from_rect,(HBITMAP) ((win_or_gworld == 1) ? (HBITMAP)hDlg: (HBITMAP)hdc) + ,rect,0,draw_dest); + DeleteObject(from_gworld); + break; + + + case 16: + which_g -= 1600; + from_gworld = load_pict(851,hdc); + from_rect.right = 32; + from_rect.bottom = 32; + OffsetRect(&from_rect,32 * (which_g % 5),32 * (which_g / 5)); + rect.right = rect.left + 32; + rect.bottom = rect.top + 32; + rect_draw_some_item(from_gworld,from_rect,(HBITMAP) ((win_or_gworld == 1) ? (HBITMAP) (hDlg): (HBITMAP) hdc) + ,rect,0,draw_dest); + DeleteObject(from_gworld); + break; + + + + } + + if ((win_or_gworld == 0) && (dlg_force_dc == NULL)) + fry_dc(hDlg, hdc); + if ((win_or_gworld == 0) && (do_frame == TRUE)){ + rect.bottom--; rect.right--; + frame_dlog_rect(hDlg,rect,3); + } +} + +void showcursor(Boolean a) +{ + short i; + i = ShowCursor(a); + if (a == FALSE) + while (i >= 0) + i = ShowCursor(FALSE); + if (a == TRUE) + while (i < 0) + i = ShowCursor(TRUE); + } + +void ModalDialog() +{ + MSG msg; + + while ((dialog_not_toast == TRUE) && (GetMessage(&msg,NULL,0,0))) { + if (!TranslateAccelerator(mainPtr, accel, &msg)) { + TranslateMessage(&msg); + DispatchMessage(&msg); + } + } +} + +RECT calc_rect(short i, short j) +{ + RECT base_rect = {0,0,28,36}; + + OffsetRect(&base_rect,i * 28, j * 36); + return base_rect; +} diff --git a/Blades of Exile Char Editor/DLOGTOOL.H b/Blades of Exile Char Editor/DLOGTOOL.H new file mode 100644 index 00000000..1e73e689 --- /dev/null +++ b/Blades of Exile Char Editor/DLOGTOOL.H @@ -0,0 +1,52 @@ +void cd_set_flag(short dlog_num,short item_num,short flag); +void cd_erase_rect(short dlog_num,RECT to_fry); +short cd_get_led(short dlog_num,short item_num); +void frame_di(HWND hDlg, short item_num, short val); +void cd_kill_dc(short which_slot,HDC hdc); +HDC cd_get_dlog_dc(short which_slot); +short cd_get_active(short dlog_num, short item_num); +short cd_create_dialog_parent_num(short dlog_num,short parent); +void cd_set_edit_focus(); +void cd_init_dialogs(); +short cd_create_dialog(short dlog_num,HWND parent) ; +short cd_kill_dialog(short dlog_num,short parent_message); +short cd_process_click(HWND window,POINT the_point, UINT wparam, LONG lparam,short *item); +short cd_process_syskeystroke(HWND window,UINT wparam, LONG lparam,short *item); +short cd_process_keystroke(HWND window,UINT wparam, LONG lparam,short *item); +void cd_init_button(short dlog_num,short item_num, short button_num, short status); +void cd_attach_key(short dlog_num,short item_num,char key); +void cd_set_pict(short dlog_num, short item_num, short pict_num); +void cd_activate_item(short dlog_num, short item_num, short status); +void cd_get_item_text(short dlog_num, short item_num, char *str); +void cd_set_item_text(short dlog_num, short item_num, char *str); +void cd_set_item_num(short dlog_num, short item_num, short num); +void cd_set_led(short dlog_num,short item_num,short state); +void cd_text_frame(short dlog_num,short item_num,short frame); +void cd_add_label(short dlog_num, short item_num, char *label, short label_flag); +void cd_take_label(short dlog_num, short item_num); +void cd_key_label(short dlog_num, short item_num,short loc); +void cd_draw_item(short dlog_num,short item_num); +void cd_initial_draw(short dlog_num); +void cd_draw(short dlog_num); +void cd_redraw(HWND window); +void cd_frame_item(short dlog_num, short item_num, short width); +void cd_erase_item(short dlog_num, short item_num); +void cd_press_button(short dlog_num, short item_num); +short cd_get_indices(short dlg_num, short item_num, short *dlg_index, short *item_index); +short cd_get_dlg_index(short dlog_num); +short cd_find_dlog(HWND window, short *dlg_num, short *dlg_key); +short cd_get_item_id(short dlg_num, short item_num); +void center_window(HWND window); +RECT get_item_rect(HWND hDlg, short item_num); +void frame_dlog_rect(HWND hDlg, RECT rect, short val); +void draw_dialog_graphic(HWND hDlg, RECT rect, short which_g, Boolean do_frame,short win_or_gworld) ; +void showcursor(Boolean a); + +void cd_get_text_edit_str(short dlog_num, char *str); +void cd_set_text_edit_str(short dlog_num, char *str); +void cdsin(short dlog_num, short item_num, short num); +void csit(short dlog_num, short item_num, char *str); +void csp(short dlog_num, short item_num, short pict_num); +void ModalDialog(); + +RECT calc_rect(short i, short j); diff --git a/Blades of Exile Char Editor/EDACTION.CPP b/Blades of Exile Char Editor/EDACTION.CPP new file mode 100644 index 00000000..c07d0483 --- /dev/null +++ b/Blades of Exile Char Editor/EDACTION.CPP @@ -0,0 +1,656 @@ +#include + +#include "stdio.h" + +#include "graphics.h" +#include "global.h" +#include "editors.h" +#include "edfileio.h" +#include "edaction.h" +#include "edsound.h" +#include "dlogtool.h" +#include "graphutl.h" + +/* Adventure globals */ +extern party_record_type far party; +extern pc_record_type far adven[6]; +extern outdoor_record_type far outdoors[2][2]; +extern current_town_type far c_town; +extern big_tr_type far t_d; +extern town_item_list far t_i; +extern unsigned char far out[96][96] ; +extern unsigned char far out_e[96][96]; +extern setup_save_type far setup_save; +extern stored_items_list_type far stored_items[3]; +extern stored_town_maps_type far maps; +extern stored_outdoor_maps_type far o_maps; +extern pascal Boolean cd_event_filter(); + +extern Boolean dialog_not_toast; + +extern HWND mainPtr; +extern Boolean file_in_mem; +extern short current_cursor,dialog_answer; + +extern HBITMAP pc_gworld; +extern HCURSOR sword_curs; +extern Boolean diff_depth_ok; +extern RECT edit_rect[5][2]; + + +short which_pc_displayed,store_pc_trait_mode,store_which_to_edit; +extern short current_active_pc; +char empty_string[256] = " "; +extern RECT pc_area_buttons[6][4],name_rect; // 0 - whole 1 - pic 2 - name 3 - stat strs 4,5 - later +extern RECT item_string_rects[24][4]; // 0 - name 1 - drop 2 - id 3 - + +short store_trait_mode,store_train_pc; + +extern short ulx,uly; +// Variables for spending xp + Boolean talk_done = FALSE; + long val_for_text; + Boolean keep_change = FALSE; + short store_skills[20],store_h,store_sp,i,which_skill,store_skp = 10000,store_g = 10000; + + +short skill_cost[20] = {3,3,3,2,2,2, 1,2,2,6, + 5, 1,2,4,2,1, 4,2,5,0}; +short skill_max[20] = {20,20,20,20,20,20,20,20,20,7, + 7,20,20,10,20,20,20,20,20}; +short skill_g_cost[20] = {50,50,50,40,40,40,30,50,40,250, + 250,25,100,200,30,20,100,80,0,0}; +short skill_bonus[21] = {-3,-3,-2,-1,0,0,1,1,1,2, + 2,2,3,3,3,3,4,4,4,5,5}; +pc_record_type *store_xp_pc; + +//extern Rect pc_area_buttons[6][6] ; // 0 - whole 1 - pic 2 - name 3 - stat strs 4,5 - later +//extern Rect item_string_rects[24][4]; // 0 - name 1 - drop 2 - id 3 - +Boolean handle_action(POINT the_point, UINT wparam, LONG lparam ) +//short mode; // ignore, +{ + short i; + + + short choice = 4; + + Boolean to_return = FALSE; + Boolean ctrl_key = FALSE; + Boolean right_button = FALSE; + + if (lparam != -1) { + the_point.x -= ulx; + the_point.y -= uly; + } + if (lparam == -2) + right_button = TRUE; + if (MK_CONTROL & wparam) + ctrl_key = TRUE; + + if (file_in_mem == FALSE) + return FALSE; + + + for (i = 0; i < 6; i++) + if ((PtInRect(&pc_area_buttons[i][0],the_point) == TRUE) && + (adven[i].main_status > 0)) { + do_button_action(0,i); + current_active_pc = i; + display_party(6,1); + draw_items(1); + } + for (i = 0; i < 5; i++) + if ((PtInRect(&edit_rect[i][0],the_point) == TRUE) && + (adven[current_active_pc].main_status > 0)) { + do_button_action(0,i + 10); + switch(i) { + case 0: + display_pc(current_active_pc,0,0); + break; + case 1: + display_pc(current_active_pc,1,0); + break; + case 2: + pick_race_abil(&adven[current_active_pc],0,0); + break; + case 3: + spend_xp(current_active_pc,1,0); + break; + case 4: + edit_xp(&adven[current_active_pc]); + + break; + } + } + for (i = 0; i < 24; i++) + if ((PtInRect(&item_string_rects[i][1],the_point) == TRUE) && // drop item + (adven[current_active_pc].items[i].variety > 0)) { // variety = 0 no item in slot/ non 0 item exists + flash_rect(item_string_rects[i][1]); + take_item(current_active_pc,i); + draw_items(1); + } + for (i = 0; i < 24; i++) + if ((PtInRect(&item_string_rects[i][2],the_point) == TRUE) && // identify item + (adven[current_active_pc].items[i].variety > 0)) { + flash_rect(item_string_rects[i][2]); + adven[current_active_pc].items[i].item_properties = adven[current_active_pc].items[i].item_properties | 1; + draw_items(1); + } + + return to_return; +} + +void flash_rect(RECT to_flash) +{ + + long dummy; + HDC hdc; + + hdc = GetDC(mainPtr); + SetViewportOrgEx( hdc,ulx,uly, NULL); + InvertRect (hdc,&to_flash); + play_sound(37); + Delay(5,&dummy); + InvertRect (hdc,&to_flash); + fry_dc(mainPtr,hdc); +} + +void edit_gold_or_food_event_filter (short) +{ + char get_text[256]; + + int tmp; + + cd_get_text_edit_str((store_which_to_edit == 0) ? 1012 : 947,(char *) get_text); + dialog_answer = 0; + sscanf((char *) get_text,"%d",&tmp); + dialog_answer = tmp; + dialog_not_toast = FALSE; +} + +void edit_gold_or_food(short which_to_edit) +//0 - gold 1 - food +{ + char sign_text[256]; + + store_which_to_edit = which_to_edit; + + make_cursor_sword(); + + cd_create_dialog((which_to_edit == 0) ? 1012 : 947,mainPtr); + + sprintf((char *) sign_text,"%d",(short) ((which_to_edit == 0) ? party.gold : party.food)); + cd_set_text_edit_str((which_to_edit == 0) ? 1012 : 947,(char *) sign_text); + + cd_set_edit_focus(); + while (dialog_not_toast) + ModalDialog(); + + cd_kill_dialog((which_to_edit == 0) ? 1012 : 947,0); + + if (dialog_answer < 0) + dialog_answer = -1; + else dialog_answer = minmax(0,25000,dialog_answer); + + if (dialog_answer >= 0) { + if (which_to_edit == 0) + party.gold = dialog_answer; + else party.food = dialog_answer; + } +} + +void edit_day_event_filter (short) +{ + char get_text[256]; + int tmp; + + cd_get_text_edit_str(917,(char *) get_text); + sscanf((char *) get_text,"%d",&tmp); + dialog_answer = tmp; + dialog_not_toast = FALSE; +} + +void edit_day() +{ + + + char sign_text[256]; + + + + make_cursor_sword(); + + cd_create_dialog(917,mainPtr); + + sprintf((char *) sign_text,"%d",(short) ( ((party.age) / 3700) + 1)); + cd_set_text_edit_str(917,(char *) sign_text); + + cd_set_edit_focus(); + while (dialog_not_toast) + ModalDialog(); + + + cd_kill_dialog(917,0); + + dialog_answer = minmax(0,500,dialog_answer); + + party.age = (long) (3700) * (long) (dialog_answer); +} + + +void put_pc_graphics() +{ + short i; + + for (i = 3; i < 65; i++) { + if (((store_trait_mode == 0) && (adven[which_pc_displayed].mage_spells[i - 3] == TRUE)) || + ((store_trait_mode == 1) && (adven[which_pc_displayed].priest_spells[i - 3] == TRUE))) + cd_set_led(991,i,1); + else cd_set_led(991,i,0); + } + + cd_set_item_text(991,69,adven[which_pc_displayed].name); +} +Boolean display_pc_event_filter (short item_hit) +{ + short pc_num; + + pc_num = which_pc_displayed; + switch (item_hit) { + case 1: case 65: + dialog_not_toast = FALSE; + break; + + case 66: + do { + pc_num = (pc_num == 0) ? 5 : pc_num - 1; + } while (adven[pc_num].main_status == 0); + which_pc_displayed = pc_num; + put_pc_graphics(); + break; + case 67: + do { + pc_num = (pc_num == 5) ? 0 : pc_num + 1; + } while (adven[pc_num].main_status == 0); + which_pc_displayed = pc_num; + put_pc_graphics(); + break; + + default: + if (store_trait_mode == 0) + adven[which_pc_displayed].mage_spells[item_hit - 3] = + 1 - adven[which_pc_displayed].mage_spells[item_hit - 3]; + else + adven[which_pc_displayed].priest_spells[item_hit - 3] = + 1 - adven[which_pc_displayed].priest_spells[item_hit - 3]; + put_pc_graphics(); + break; + } + return FALSE; +} + +void display_pc(short pc_num,short mode,short) +{ + short i; + char label_str[256]; + + if (adven[pc_num].main_status == 0) { + for (pc_num = 0; pc_num < 6; pc_num++) + if (adven[pc_num].main_status == 1) + break; + } + which_pc_displayed = pc_num; + store_trait_mode = mode; + + make_cursor_sword(); + + cd_create_dialog_parent_num(991,0); + + for (i = 3; i < 65; i++) { + get_str(label_str,(mode == 0) ? 7 : 8,(i - 3) * 2 + 1); + cd_add_label(991,i,(char *)label_str,46); + } + put_pc_graphics(); + + cd_set_pict(991,2,714 + mode); + while (dialog_not_toast) + ModalDialog(); + + cd_kill_dialog(991,0); +} + + +Boolean display_alchemy_event_filter (short item_hit) +{ + short i; + + switch (item_hit) { + case 1: case 3: + dialog_not_toast = FALSE; + break; + default: + party.alchemy[item_hit - 4] = 1 - party.alchemy[item_hit - 4]; + break; + + } + for (i = 0; i < 20; i++) { + if (party.alchemy[i] > 0) + cd_set_led(996,i + 4,1); + else cd_set_led(996,i + 4,0); + } + return FALSE; +} + +void display_alchemy() +{ + short i; + char *alch_names[] = {"Weak Curing Potion (1)","Weak Healing Potion (1)","Weak Poison (1)", + "Weak Speed Potion (3)","Medium Poison (3)", + "Medium Heal Potion (4)","Strong Curing (5)","Medium Speed Potion (5)", + "Graymold Salve (7)","Weak Power Potion (9)", + "Potion of Clarity (9)","Strong Poison (10)","Strong Heal Potion (12)","Killer Poison (12)", + "Resurrection Balm (9)","Medium Power Potion (14)","Knowledge Brew (19)", + "Strong Strength (10)","Bliss (18)","Strong Power (20)" + }; + + make_cursor_sword(); + + cd_create_dialog_parent_num(996,0); + + + for (i = 0; i < 20; i++) { + cd_add_label(996,i + 4,alch_names[i],1083); + if (party.alchemy[i] > 0) + cd_set_led(996,i + 4,1); + else cd_set_led(996,i + 4,0); + } + + while (dialog_not_toast) + ModalDialog(); + + cd_kill_dialog(996,0); + dialog_not_toast = TRUE; + +} + +void do_xp_keep(short pc_num,short) +{ + for (i = 0; i < 20; i++) + adven[pc_num].skills[i] = store_skills[i]; + adven[pc_num].cur_health += store_h - adven[pc_num].max_health; + adven[pc_num].max_health = store_h; + adven[pc_num].cur_sp += store_sp - adven[pc_num].max_sp; + adven[pc_num].max_sp = store_sp; + +} + +void draw_xp_skills() +{ + short i; + for (i = 0; i < 19; i++) { + if ((store_skp >= skill_cost[i]) && (store_g >= skill_g_cost[i])) + cd_text_frame(1010,54 + i,11); + else cd_text_frame(1010,54 + i,1); + cd_set_item_num(1010,54 + i,store_skills[i]); + } + + if ((store_skp >= 1) && (store_g >= 10)) + cd_text_frame(1010,52,11); + else cd_text_frame(1010,52,1); + cd_set_item_num(1010,52,store_h); + if ((store_skp >= 1) && (store_g >= 15)) + cd_text_frame(1010,53,11); + else cd_text_frame(1010,53,1); + cd_set_item_num(1010,53,store_sp); +} + + +void do_xp_draw() + +{ + + + char get_text[256]; + short pc_num; + + pc_num = store_train_pc; + + sprintf((char *) get_text, "%s",(char *) adven[pc_num].name); + + + cd_set_item_text (1010, 51,get_text); + + for (i = 0; i < 20; i++) + store_skills[i] = adven[pc_num].skills[i]; + store_h = adven[pc_num].max_health; + store_sp = adven[pc_num].max_sp; + store_g = 12000; + store_skp = 10000; + + draw_xp_skills(); + + update_gold_skills(); +} + +Boolean spend_xp_event_filter (short item_hit) +{ + short pc_num; + + Boolean talk_done = FALSE; + + pc_num = store_train_pc; + + switch (item_hit) { + case 73: + dialog_answer = 0; + talk_done = TRUE; + break; + + + + case 3: case 4: + if ((store_h >= 250) && (item_hit == 4)) + play_sound(0); + else { + if (item_hit == 3) { + store_g += 10; + store_h -= 2; + store_skp += 1; + } + else { + if ((store_g < 10) || (store_skp < 1)) { + + play_sound(0); + } + else { + store_g -= 10; + store_h += 2; + store_skp -= 1; + } + } + + update_gold_skills(); + cd_set_item_num(1010,52,store_h); + draw_xp_skills(); + + } + break; + + case 5: case 6: + if ((store_sp >= 150) && (item_hit == 6)) + play_sound(0); + else { + if (item_hit == 5) { + store_g += 15; + store_sp -= 1; + store_skp += 1; + } + else { + if ((store_g < 15) || (store_skp < 1)) { + + play_sound(0); + } + else { + store_sp += 1; + store_g -= 15; + store_skp -= 1; + } + } + + update_gold_skills(); + cd_set_item_num(1010,53,store_sp); + draw_xp_skills(); + } + break; + + case 48: + do_xp_keep(pc_num,0); + dialog_answer = 1; + talk_done = TRUE; + break; + + case 49: + + do_xp_keep(pc_num,0); + do { + pc_num = (pc_num == 0) ? 5 : pc_num - 1; + } while (adven[pc_num].main_status != 1); + store_train_pc = pc_num; + do_xp_draw(); + break; + + case 50: + + do_xp_keep(pc_num,0); + do { + pc_num = (pc_num == 5) ? 0 : pc_num + 1; + } while (adven[pc_num].main_status != 1); + store_train_pc = pc_num; + do_xp_draw(); + break; + + case 100: + break; + + default: + if (item_hit >= 100) { + } + else { + which_skill = (item_hit - 7) / 2; + + if (((store_skills[which_skill] >= skill_max[which_skill]) && ((item_hit - 7) % 2 == 1)) || + ((store_skills[which_skill] == 0) && ((item_hit - 7) % 2 == 0) && (which_skill > 2)) || + ((store_skills[which_skill] == 1) && ((item_hit - 7) % 2 == 0) && (which_skill <= 2))) + play_sound(0); + else { + if ((item_hit - 7) % 2 == 0) { + store_g += skill_g_cost[which_skill]; + store_skills[which_skill] -= 1; + store_skp += skill_cost[which_skill]; + } + else { + if ((store_g < skill_g_cost[which_skill]) || (store_skp < skill_cost[which_skill])) { + + play_sound(0); + } + else { + store_skills[which_skill] += 1; + store_g -= skill_g_cost[which_skill]; + store_skp -= skill_cost[which_skill]; + } + } + + update_gold_skills(); + cd_set_item_num(1010,54 + which_skill,store_skills[which_skill]); + draw_xp_skills(); + } + } + break; + } + + store_train_pc = pc_num; + if (talk_done == TRUE) { + dialog_not_toast = FALSE; + } + return FALSE; +} +void update_gold_skills() +{ + csit(1010,47,"Lots!"); + csit(1010,46,"Lots!"); +} +Boolean spend_xp(short pc_num, short, short parent) +//short mode; // 0 - create 1 - train +// returns 1 if cancelled +{ + char get_text[256],text2[256]; + + + store_train_pc = pc_num; + + make_cursor_sword(); + + cd_create_dialog_parent_num(1010,parent); + sprintf((char *) get_text,"Health (%d/%d)",1,10); + cd_add_label(1010,52,(char *) get_text,1075); + sprintf((char *) get_text,"Spell Pts. (%d/%d)",1,15); + //cd_add_label(1010,5,get_text,1040); + cd_add_label(1010,53,(char *) get_text,1075); + for (i = 54; i < 73; i++) { + get_str(text2,9,1 + 2 * (i - 54)); + sprintf((char *) get_text,"%s (%d/%d)",text2,skill_cost[i - 54],skill_g_cost[i - 54]); + cd_add_label(1010,i,(char *) get_text,(i < 63) ? 1075 : 1069); + } + do_xp_draw(); + + dialog_answer = 0; + + while (dialog_not_toast) + ModalDialog(); + + + cd_kill_dialog(1010,0); + + return dialog_answer; +} + +void edit_xp_event_filter (short) +{ + char get_text[256]; + int tmp; + + cd_get_text_edit_str(1024,(char *) get_text); + sscanf((char *) get_text,"%d",&tmp); + dialog_answer = tmp; + dialog_not_toast = FALSE; +} + +void edit_xp(pc_record_type *pc) +{ + + short item_hit; + char sign_text[256]; + + + store_xp_pc = pc; + + make_cursor_sword(); + + cd_create_dialog(1024,mainPtr); + + sprintf((char *) sign_text,"%d",(short)pc->experience); + cd_set_text_edit_str(1024,(char *) sign_text); + item_hit = get_tnl(store_xp_pc); + cdsin(1024,8,item_hit); + + while (dialog_not_toast) + ModalDialog(); + + cd_kill_dialog(1024,0); + + if (dialog_answer < 0) + dialog_answer = dialog_answer * -1; + dialog_answer = minmax(0,10000,dialog_answer); + + pc->experience = dialog_answer; +} diff --git a/Blades of Exile Char Editor/EDACTION.H b/Blades of Exile Char Editor/EDACTION.H new file mode 100644 index 00000000..88b67f50 --- /dev/null +++ b/Blades of Exile Char Editor/EDACTION.H @@ -0,0 +1,20 @@ +Boolean handle_action(POINT the_point, UINT wparam, LONG lparam ); +void flash_rect(RECT to_flash); +void edit_gold_or_food_event_filter (short item_hit); +void edit_gold_or_food(short which_to_edit); +void put_pc_graphics(); +Boolean display_pc_event_filter (short item_hit); +void display_pc(short pc_num,short mode,short parent); +Boolean display_alchemy_event_filter (short item_hit); +void display_alchemy(); +void do_xp_keep(short pc_num,short mode); +void draw_xp_skills(); +void do_xp_draw(); +Boolean spend_xp_event_filter (short item_hit); +void update_gold_skills(); +Boolean spend_xp(short pc_num, short mode, short parent); +void edit_day(); +void edit_day_event_filter (short item_hit); +void edit_xp_event_filter (short item_hit); +void edit_xp(pc_record_type *pc); + diff --git a/Blades of Exile Char Editor/EDFILEIO.CPP b/Blades of Exile Char Editor/EDFILEIO.CPP new file mode 100644 index 00000000..1e4b8709 --- /dev/null +++ b/Blades of Exile Char Editor/EDFILEIO.CPP @@ -0,0 +1,1233 @@ +#include +#include + +#include +#include "stdio.h" + +#include "global.h" +#include "edfileio.h" +#include "graphics.h" +#include "edsound.h" +#include "editors.h" + + +/* Adventure globals */ +extern party_record_type far party; +extern pc_record_type far adven[6]; +extern outdoor_record_type far outdoors[2][2]; +extern current_town_type far c_town; +extern big_tr_type far t_d; +extern town_item_list far t_i; +extern unsigned char misc_i[64][64],sfx[64][64]; +extern unsigned char far out[96][96]; +extern unsigned char far out_e[96][96]; +extern setup_save_type far setup_save; +extern stored_items_list_type far stored_items[3]; +extern stored_town_maps_type far maps; +extern stored_outdoor_maps_type far o_maps; + +extern scen_item_data_type far scen_item_list; +extern char file_path_name[256]; + +extern Boolean play_sounds,sys_7_avail,party_in_scen; +extern short current_active_pc; +extern HWND mainPtr; + +extern Boolean file_in_mem; + + +typedef struct { + char expl[96][96]; + } out_info_type; + +extern short store_flags[3]; + +// Big waste! +out_info_type far store_map; +char last_load_file[63] = "blades.sav"; +char szFileName [128] = "blades.sav"; +char szTitleName [128] = "blades.sav"; +OPENFILENAME ofn; +extern stored_town_maps_type far town_maps,town_maps2; + +short give_intro_hint = 1; +short display_mode = 0; + short store_size; + +void Get_Path(char* path){ + +char file_path[256]=""; // initialization +GetModuleFileName(NULL,file_path,256); // get path to the executable + +int i=255; // initialize the first while loop +while(file_path[i] != '\\') + { + i--; // find the last '\' in the path to the executable + } // in order to get rid of 'blades of exile.exe' + + +int j=0; // initialize the second loop + +for(j=0;j 0) { + current_active_pc = i; + i = 6; + } + + file_in_mem = TRUE; + party_in_scen = in_scen; + + load_items_list(); + + redraw_screen(); +} + +void load_items_list(){ //LOAD SCENARIO ITEMS LIST + + HANDLE scen_file_id; + DWORD len, dwScenByteRead; + + scenario_data_type far scenario; + char scen_name[256]=""; + + if(party_in_scen) + sprintf(scen_name,"scenarios/%s",party.scen_name); + else + sprintf(scen_name,"bladbase.exs"); + + scen_file_id = CreateFile(scen_name, GENERIC_READ, FILE_SHARE_READ, NULL, + OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL); + if (scen_file_id == INVALID_HANDLE_VALUE) + { + MessageBox(mainPtr,"Couldn't open the scenario file !", + "File Error",MB_OK | MB_ICONEXCLAMATION); + return; + } + + if (ReadFile(scen_file_id, &scenario, sizeof(scenario_data_type), &dwScenByteRead, NULL) == FALSE) + { + CloseHandle(scen_file_id); +MessageBox(mainPtr,"Invalid scenario file !", + "File Error",MB_OK | MB_ICONEXCLAMATION); + return; + } + + len = sizeof(scen_item_data_type); // item data + + if (ReadFile(scen_file_id, &scen_item_list, sizeof(scen_item_data_type), &dwScenByteRead, NULL) == FALSE) + { + CloseHandle(scen_file_id); +MessageBox(mainPtr,"Couldn't read the scenario item list !", + "File Error",MB_OK | MB_ICONEXCLAMATION); + return; + } + + CloseHandle(scen_file_id); + +}//END SCENARIO ITEMS LIST LOADING + + +void save_file(short mode) +//short mode; // 0 - normal 1 - save as +{ + HANDLE file_id; + UINT error; + + short i,j; + + DWORD len,store_len,count, bytes, dwByteRead; + flag_type flag; + flag_type *store; + party_record_type *party_ptr; + setup_save_type *setup_ptr; + pc_record_type *pc_ptr; + + + current_town_type *town_ptr; + big_tr_type *town_data_ptr; + town_item_list *item_ptr; + stored_items_list_type *items_ptr; + stored_town_maps_type *maps_ptr; + stored_outdoor_maps_type *o_maps_ptr; + + char *party_encryptor; + + Boolean town_save = FALSE,in_scen = FALSE,save_maps = FALSE; + + mode = 1; + if (file_in_mem == FALSE) + return; + + if (store_flags[0] == 1342) + town_save = TRUE; + else town_save = FALSE; + if (store_flags[1] == 100) + in_scen = TRUE; + else in_scen = FALSE; + if (store_flags[2] == 5567) { + save_maps = TRUE; + } + else save_maps = FALSE; + + ofn.hwndOwner = mainPtr; + ofn.lpstrFile = szFileName; + ofn.lpstrFileTitle = szTitleName; + ofn.Flags = OFN_OVERWRITEPROMPT; + + if (mode == 1) { + if (GetSaveFileName(&ofn) == 0) + return; + } + + file_id = CreateFile(szFileName, GENERIC_WRITE, 0, NULL, + CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL); + if (file_id == INVALID_HANDLE_VALUE) return; + + store = &flag; + + len = sizeof(flag_type); + + flag.i = store_flags[0]; + if (WriteFile(file_id, store, sizeof(flag_type), &bytes, NULL) == FALSE) + { + CloseHandle(file_id); + return; + } + flag.i = store_flags[1]; + if (WriteFile(file_id, store, sizeof(flag_type), &bytes, NULL) == FALSE) + { + CloseHandle(file_id); + return; + } + flag.i = store_flags[2]; + if (WriteFile(file_id, store, sizeof(flag_type), &bytes, NULL) == FALSE) + { + CloseHandle(file_id); + return; + } + + // SAVE PARTY + party_ptr = &party; + len = sizeof(party_record_type); + + store_len = len; + party_encryptor = (char *) party_ptr; + for (count = 0; count < store_len; count++) + party_encryptor[count] ^= 0x5C; + + WriteFile(file_id, &party.age, 4, &dwByteRead, NULL); + WriteFile(file_id, &party.gold, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.food, 2, &dwByteRead, NULL); + WriteFile(file_id, party.stuff_done, 310*10, &dwByteRead, NULL); + WriteFile(file_id, party.item_taken, 200*8, &dwByteRead, NULL); + WriteFile(file_id, &party.light_level, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.outdoor_corner.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.outdoor_corner.y, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.i_w_c.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.i_w_c.y, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.p_loc.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.p_loc.y, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.loc_in_sec.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.loc_in_sec.y, 1, &dwByteRead, NULL); + + for (i = 0; i < 30; i++) + { + WriteFile(file_id, &party.boats[i].boat_loc.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.boats[i].boat_loc.y, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.boats[i].boat_loc_in_sec.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.boats[i].boat_loc_in_sec.y, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.boats[i].boat_sector.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.boats[i].boat_sector.y, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.boats[i].which_town, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.boats[i].exists, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.boats[i].property, 1, &dwByteRead, NULL); + } + for (i = 0; i < 30; i++) + { + WriteFile(file_id, &party.horses[i].horse_loc.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.horses[i].horse_loc.y, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.horses[i].horse_loc_in_sec.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.horses[i].horse_loc_in_sec.y, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.horses[i].horse_sector.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.horses[i].horse_sector.y, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.horses[i].which_town, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.horses[i].exists, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.horses[i].property, 1, &dwByteRead, NULL); + } + for (i = 0; i < 4; i++) + { + for (j = 0; j < 60; j++) + { + WriteFile(file_id, &party.creature_save[i].dudes[j].active, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].attitude, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].number, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_loc.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_loc.y, 1, &dwByteRead, NULL); + { + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.m_num, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.level, 1, &dwByteRead, NULL); + WriteFile(file_id, party.creature_save[i].dudes[j].m_d.m_name, 26, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.health, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.m_health, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.mp, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.max_mp, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.armor, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.skill, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.a, 2*3, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.a1_type, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.a23_type, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.m_type, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.speed, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.ap, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.mu, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.cl, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.breath, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.breath_type, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.treasure, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.spec_skill, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.poison, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.morale, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.m_morale, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.corpse_item, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.corpse_item_chance, 2, &dwByteRead, NULL); + WriteFile(file_id, party.creature_save[i].dudes[j].m_d.status, 2*15, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.direction, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.immunities, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.x_width, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.y_width, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.radiate_1, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.radiate_2, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.default_attitude, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.summon_type, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.default_facial_pic, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.res1, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.res2, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.res3, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].m_d.picture_num, 2, &dwByteRead, NULL); + } + WriteFile(file_id, &party.creature_save[i].dudes[j].mobile, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].summoned, 2, &dwByteRead, NULL); + { + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.number, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.start_attitude, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.start_loc.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.start_loc.y, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.mobile, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.time_flag, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.extra1, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.extra2, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.spec1, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.spec2, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.spec_enc_code, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.time_code, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.monster_time, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.personality, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.special_on_kill, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].dudes[j].monst_start.facial_pic, 2, &dwByteRead, NULL); + } + } + + WriteFile(file_id, &party.creature_save[i].which_town, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.creature_save[i].friendly, 2, &dwByteRead, NULL); + } + + WriteFile(file_id, &party.in_boat, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.in_horse, 2, &dwByteRead, NULL); + for (i = 0; i < 10; i++) + { + WriteFile(file_id, &party.out_c[i].exists, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.out_c[i].direction, 2, &dwByteRead, NULL); + { + WriteFile(file_id, party.out_c[i].what_monst.monst, 7, &dwByteRead, NULL); + WriteFile(file_id, party.out_c[i].what_monst.friendly, 3, &dwByteRead, NULL); + WriteFile(file_id, &party.out_c[i].what_monst.spec_on_meet, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.out_c[i].what_monst.spec_on_win, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.out_c[i].what_monst.spec_on_flee, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.out_c[i].what_monst.cant_flee, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.out_c[i].what_monst.end_spec1, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.out_c[i].what_monst.end_spec1, 2, &dwByteRead, NULL); + } + WriteFile(file_id, &party.out_c[i].which_sector.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.out_c[i].which_sector.y, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.out_c[i].m_loc.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.out_c[i].m_loc.y, 1, &dwByteRead, NULL); + } + for (i = 0; i < 5; i++) + for (j = 0; j < 10; j++) + { + WriteFile(file_id, &party.magic_store_items[i][j].variety, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].item_level, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].awkward, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].bonus, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].protection, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].charges, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].type, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].magic_use_type, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].graphic_num, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].ability, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].ability_strength, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].type_flag, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].is_special, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].a, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].value, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].weight, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].special_class, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].item_loc.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].item_loc.y, 1, &dwByteRead, NULL); + WriteFile(file_id, party.magic_store_items[i][j].full_name, 25, &dwByteRead, NULL); + WriteFile(file_id, party.magic_store_items[i][j].name, 15, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].treas_class, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].item_properties, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].reserved1, 1, &dwByteRead, NULL); + WriteFile(file_id, &party.magic_store_items[i][j].reserved2, 1, &dwByteRead, NULL); + } + WriteFile(file_id, &party.imprisoned_monst, 2*4, &dwByteRead, NULL); + WriteFile(file_id, party.m_seen, 256, &dwByteRead, NULL); + WriteFile(file_id, party.journal_str, 50, &dwByteRead, NULL); + WriteFile(file_id, party.journal_day, 2*50, &dwByteRead, NULL); + WriteFile(file_id, party.special_notes_str, 2*140*2, &dwByteRead, NULL); + for (i = 0; i < 120; i++) + { + WriteFile(file_id, &party.talk_save[i].personality, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.talk_save[i].town_num, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.talk_save[i].str1, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.talk_save[i].str2, 2, &dwByteRead, NULL); + } + WriteFile(file_id, &party.direction, 2, &dwByteRead, NULL); + WriteFile(file_id, &party.at_which_save_slot, 2, &dwByteRead, NULL); + WriteFile(file_id, party.alchemy, 20, &dwByteRead, NULL); + WriteFile(file_id, party.can_find_town, 200, &dwByteRead, NULL); + WriteFile(file_id, party.key_times, 2*100, &dwByteRead, NULL); + WriteFile(file_id, party.party_event_timers, 2*30, &dwByteRead, NULL); + WriteFile(file_id, party.global_or_town, 2*30, &dwByteRead, NULL); + WriteFile(file_id, party.node_to_call, 2*30, &dwByteRead, NULL); + WriteFile(file_id, party.spec_items, 50, &dwByteRead, NULL); + WriteFile(file_id, party.help_received, 120, &dwByteRead, NULL); + WriteFile(file_id, party.m_killed, 2*200, &dwByteRead, NULL); + WriteFile(file_id, &party.total_m_killed, 4, &dwByteRead, NULL); + WriteFile(file_id, &party.total_dam_done, 4, &dwByteRead, NULL); + WriteFile(file_id, &party.total_xp_gained, 4, &dwByteRead, NULL); + WriteFile(file_id, &party.total_dam_taken, 4, &dwByteRead, NULL); + WriteFile(file_id, party.scen_name, 256, &dwByteRead, NULL); + + for (count = 0; count < store_len; count++) + party_encryptor[count] ^= 0x5C; + + // SAVE SETUP + setup_ptr = &setup_save; + len = sizeof(setup_save_type); + if (WriteFile(file_id, setup_ptr, sizeof(setup_save_type), &bytes, NULL) == FALSE) + { + CloseHandle(file_id); + return; + } + + // SAVE PCS + store_len = sizeof(pc_record_type); + for (i = 0; i < 6; i++) { + pc_ptr = &adven[i]; + + len = store_len; + party_encryptor = (char *) pc_ptr; + for (count = 0; count < store_len; count++) + party_encryptor[count] ^= 0x6B; + if (WriteFile(file_id, pc_ptr, sizeof(pc_record_type), &bytes, NULL) == FALSE) + { + CloseHandle(file_id); + for (count = 0; count < store_len; count++) + party_encryptor[count] ^= 0x6B; + MessageBeep(MB_OK); + return; + } + for (count = 0; count < store_len; count++) + party_encryptor[count] ^= 0x6B; + } + + if (party_in_scen == TRUE) { + + // SAVE OUT DATA + len = sizeof(out_info_type); + if (WriteFile(file_id, out_e, sizeof(out_info_type), &bytes, NULL) == FALSE) + { + CloseHandle(file_id); + return; + } + + if (town_save == TRUE) { + town_ptr = &c_town; + + { + WriteFile(file_id, &c_town.town_num, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.difficulty, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.town, sizeof(town_record_type), &dwByteRead, NULL); + WriteFile(file_id, c_town.explored, 64 * 64, &dwByteRead, NULL); + WriteFile(file_id, &c_town.hostile, 1, &dwByteRead, NULL); + { + for (j = 0; j < 60; j++) + { + WriteFile(file_id, &c_town.monst.dudes[j].active, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].attitude, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].number, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_loc.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_loc.y, 1, &dwByteRead, NULL); + { + WriteFile(file_id, &c_town.monst.dudes[j].m_d.m_num, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.level, 1, &dwByteRead, NULL); + WriteFile(file_id, c_town.monst.dudes[j].m_d.m_name, 26, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.health, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.m_health, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.mp, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.max_mp, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.armor, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.skill, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.a, 2*3, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.a1_type, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.a23_type, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.m_type, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.speed, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.ap, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.mu, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.cl, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.breath, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.breath_type, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.treasure, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.spec_skill, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.poison, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.morale, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.m_morale, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.corpse_item, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.corpse_item_chance, 2, &dwByteRead, NULL); + WriteFile(file_id, c_town.monst.dudes[j].m_d.status, 2*15, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.direction, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.immunities, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.x_width, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.y_width, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.radiate_1, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.radiate_2, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.default_attitude, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.summon_type, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.default_facial_pic, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.res1, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.res2, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.res3, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].m_d.picture_num, 2, &dwByteRead, NULL); + } + WriteFile(file_id, &c_town.monst.dudes[j].mobile, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].summoned, 2, &dwByteRead, NULL); + { + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.number, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.start_attitude, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.start_loc.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.start_loc.y, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.mobile, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.time_flag, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.extra1, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.extra2, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.spec1, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.spec2, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.spec_enc_code, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.time_code, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.monster_time, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.personality, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.special_on_kill, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.dudes[j].monst_start.facial_pic, 2, &dwByteRead, NULL); + } + } + WriteFile(file_id, &c_town.monst.which_town, 2, &dwByteRead, NULL); + WriteFile(file_id, &c_town.monst.friendly, 2, &dwByteRead, NULL); + } + + WriteFile(file_id, &c_town.in_boat, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.p_loc.x, 1, &dwByteRead, NULL); + WriteFile(file_id, &c_town.p_loc.y, 1, &dwByteRead, NULL); + } + + town_data_ptr = &t_d; + len = sizeof(big_tr_type); + if (WriteFile(file_id, town_data_ptr, sizeof(big_tr_type), &bytes, NULL) == FALSE) + { + CloseHandle(file_id); + return; + } + item_ptr = &t_i; + len = sizeof(town_item_list); + if (WriteFile(file_id, item_ptr, sizeof(town_item_list), &bytes, NULL) == FALSE) + { + CloseHandle(file_id); + return; + } + } + + // Save stored items + for (i = 0; i < 3; i++) { + items_ptr = &stored_items[i]; + len = (long) sizeof(stored_items_list_type); + if (WriteFile(file_id, item_ptr, sizeof(stored_items_list_type), &bytes, NULL) == FALSE) + { + CloseHandle(file_id); + return; + } + } + + // If saving maps, save maps + if (save_maps == TRUE) { + maps_ptr = &(town_maps); + len = (long) sizeof(stored_town_maps_type); + if (WriteFile(file_id, maps_ptr, sizeof(stored_town_maps_type), &bytes, NULL) == FALSE) + { + CloseHandle(file_id); + return; + } + maps_ptr = &(town_maps2); + len = (long) sizeof(stored_town_maps_type); + if (WriteFile(file_id, maps_ptr, sizeof(stored_town_maps_type), &bytes, NULL) == FALSE) + { + CloseHandle(file_id); + return; + } + + o_maps_ptr = &o_maps; + len = (long) sizeof(stored_outdoor_maps_type); + if (WriteFile(file_id, o_maps_ptr, sizeof(stored_outdoor_maps_type), &bytes, NULL) == FALSE) + { + CloseHandle(file_id); + return; + } + } + + // SAVE SFX and MISC_I + len = (long) (64 * 64); + if (WriteFile(file_id, sfx, (64 * 64), &bytes, NULL) == FALSE) + { + CloseHandle(file_id); + return; + } + if (WriteFile(file_id, misc_i, (64 * 64), &bytes, NULL) == FALSE) + { + CloseHandle(file_id); + return; + } + } + + CloseHandle(file_id); +} + + +void leave_town() +{ + store_flags[0] = 5790; +} + + +void remove_party_from_scen() +{ + store_flags[1] = 200; + party_in_scen = FALSE; +} + + + +long do_waterfall(long flag) +{ + long k = 0; + + k = flag; + k = k * k; + k = k + 50; + k = k % 3000; + k = k * 81; + k = k % 10000; + k = k + 10000; + + return k; + +} + +long init_data(long flag) +{ + long k = 0; + + k = flag; + k = k * k; + k = k + 50; + k = k % 3000; + k = k * 81; + k = k % 10000; + k = k + 10000; + + return k; +} + +void build_data_file(short mode) // to do be rewrite to use ini file +//mode; // 0 - make first time file 1 - customize 2 - new write +{ + return; +} + +short FSWrite(HFILE file,long *len,char *buffer) +{ + long error = 0; + + if ((error = _lwrite(file, (char *) buffer, (UINT) (*len))) == HFILE_ERROR) + return -1; + return 0; +} + +short FSRead(HFILE file,long *len,char *buffer) +{ + long error = 0; + + if ((error = _lread(file, (char *) buffer, (UINT) (*len))) == HFILE_ERROR) + return -1; + return 0; + +} + +short FSClose(HFILE file) +{ + _lclose(file); + return 0; +} + +short SetFPos(HFILE file, short mode, long len) +{ + long error = 0; + + switch (mode) { + case 1: error = _llseek(file,len,0); break; + case 2: error = _llseek(file,len,2); break; + case 3: error = _llseek(file,len,1); break; + } + + if (error == HFILE_ERROR) + return -1; + return 0; +} diff --git a/Blades of Exile Char Editor/EDFILEIO.H b/Blades of Exile Char Editor/EDFILEIO.H new file mode 100644 index 00000000..f80e4d5f --- /dev/null +++ b/Blades of Exile Char Editor/EDFILEIO.H @@ -0,0 +1,14 @@ +void file_initialize(); +void save_file(short mode); +void load_file(); +void leave_town(); +long do_waterfall(long flag); +long init_data(long flag); +void build_data_file(short mode); +short FSWrite(HFILE file,long *len,char *buffer); +short FSRead(HFILE file,long *len,char *buffer); +short FSClose(HFILE file); +short SetFPos(HFILE file, short mode, long len); +void remove_party_from_scen(); +void Get_Path(char* path); +void load_items_list(); diff --git a/Blades of Exile Char Editor/EDITORS.CPP b/Blades of Exile Char Editor/EDITORS.CPP new file mode 100644 index 00000000..43fbde93 --- /dev/null +++ b/Blades of Exile Char Editor/EDITORS.CPP @@ -0,0 +1,406 @@ +#include + + +#include "graphics.h" +#include "global.h" +#include "editors.h" +#include "dlogtool.h" + +/* Adventure globals */ +extern party_record_type far party; +extern pc_record_type far adven[6]; +extern outdoor_record_type far outdoors[2][2]; +extern current_town_type far c_town; +extern big_tr_type far t_d; +extern town_item_list far t_i; +extern unsigned char far out[96][96]; +extern unsigned char far out_e[96][96]; +extern setup_save_type far setup_save; +extern stored_items_list_type far stored_items[3]; +extern stored_town_maps_type far maps; +extern stored_outdoor_maps_type far o_maps; +extern short dialog_answer; + +extern short store_flags[3]; +extern Boolean dialog_not_toast; + +extern short current_active_pc; + +extern HWND mainPtr; +extern short current_cursor; + +extern HCURSOR sword_curs; +extern Boolean diff_depth_ok,current_file_has_maps; + +Boolean equippable[18] = {FALSE,TRUE,TRUE,FALSE,TRUE,TRUE,TRUE,FALSE,FALSE,TRUE,TRUE,TRUE, + TRUE,TRUE,TRUE,FALSE,FALSE,TRUE}; +short num_hands_to_use[18] = {0,1,2,0,1,1,1,0,0,1,1,0,0,0,0,0,0,0}; +short num_that_can_equip[18] = {0,2,1,0,1,1,1,0,0,2,1,1,1,2,1,0,0,1}; +short selected,item_max = 0; +Boolean choice_active[6]; + + + +extern short store_trait_mode; +pc_record_type *store_pc; +HBITMAP button_num_gworld; + +FARPROC dlog_proc1; +HWND test_dlog3; +short answer_given; +HWND store_focus; +extern HANDLE store_hInstance; + +void combine_things(short pc_num) +{ + + short i,j,test; + + for (i = 0; i < 24; i++) { + if ((adven[pc_num].items[i].variety > 0) && + (adven[pc_num].items[i].type_flag > 0) && (adven[pc_num].items[i].item_properties & 254 != 0)) { + for (j = i + 1; j < 24; j++) + if ((adven[pc_num].items[j].variety > 0) && + (adven[pc_num].items[j].type_flag == adven[pc_num].items[i].type_flag) + && (adven[pc_num].items[j].item_properties & 254 != 0)) { + test = (short) (adven[pc_num].items[i].charges) + (short) (adven[pc_num].items[j].charges); + if (test > 125) { + adven[pc_num].items[i].charges = 125; + } + else adven[pc_num].items[i].charges += adven[pc_num].items[j].charges; + if (adven[pc_num].equip[j] == TRUE) { + adven[pc_num].equip[i] = TRUE; + adven[pc_num].equip[j] = FALSE; + } + take_item(pc_num,j); + } + } + if ((adven[pc_num].items[i].variety > 0) && (adven[pc_num].items[i].charges < 0)) + adven[pc_num].items[i].charges = 1; + } +} + +Boolean give_to_pc(short pc_num,item_record_type item, short) +{ + short free_space; + + + if (item.variety == 0) + return TRUE; + if (((free_space = pc_has_space(pc_num)) == 24 ) || (adven[pc_num].main_status != 1)) + return FALSE; + else { + adven[pc_num].items[free_space] = item; + combine_things(pc_num); + return TRUE; + } + return FALSE; +} + +Boolean give_to_party(item_record_type item,short print_result) +{ + short i = 0; + + while (i < 6) { + if (give_to_pc(i,item,print_result) == TRUE) + return TRUE; + i++; + } + return FALSE; +} + +void give_gold(short amount, Boolean) +{ + party.gold += amount; +} + +Boolean take_gold(short amount,Boolean) +{ + if (party.gold < amount) + return FALSE; + party.gold -= amount; + return TRUE; +} + + +short pc_has_space(short pc_num) +{ + short i = 0; + + while (i < 24) { + if (adven[pc_num].items[i].variety == 0) + return i; + i++; + } + return 24; +} + + +void take_item(short pc_num,short which_item) +//short pc_num,which_item; // if which_item > 20, don't update stat win, item is which_item - 20 +{ + short i; + + + if ((adven[pc_num].weap_poisoned == which_item) && (adven[pc_num].status[0] > 0)) { +// add_string_to_buf(" Poison lost. "); + adven[pc_num].status[0] = 0; + } + if ((adven[pc_num].weap_poisoned > which_item) && (adven[pc_num].status[0] > 0)) + adven[pc_num].weap_poisoned--; + + for (i = which_item; i < 23; i++) { + adven[pc_num].items[i] = adven[pc_num].items[i + 1]; + adven[pc_num].equip[i] = adven[pc_num].equip[i + 1]; + } + adven[pc_num].items[23].variety = 0; + adven[pc_num].equip[23] = FALSE; + +} + + +void fancy_choice_dialog_event_filter (short item_hit) +{ + dialog_not_toast = FALSE; + dialog_answer = item_hit; +} + +short fancy_choice_dialog(short which_dlog,short parent) +// ignore parent in Mac version +{ + short i,store_dialog_answer; + + + store_dialog_answer = dialog_answer; + make_cursor_sword(); + + cd_create_dialog_parent_num(which_dlog,parent); + + + while (dialog_not_toast) + ModalDialog(); + + cd_kill_dialog(which_dlog,0); + + i = dialog_answer; + dialog_answer = store_dialog_answer; + + return i; +} + +void select_pc_event_filter (short item_hit) +{ + dialog_not_toast = FALSE; + if (item_hit == 16) + dialog_answer = 6; + else dialog_answer = item_hit - 3; +} + +short char_select_pc(short active_only,short free_inv_only,char *title) +//active_only; // 0 - no 1 - yes 2 - disarm trap +{ + short i; + + make_cursor_sword(); + + cd_create_dialog(1018,mainPtr); + + if (active_only == 2) + csit(1018,15,"Select PC to disarm trap:"); + else csit( 1018,15,title); + + for (i = 0; i < 6; i++) { + if ((adven[i].main_status == 0) || + ((active_only == TRUE) && (adven[i].main_status > 1)) || + ((free_inv_only == 1) && (pc_has_space(i) == 24)) || (adven[i].main_status == 5)) { + cd_activate_item(1018, 3 + i, 0); + } + if (adven[i].main_status != 0) { + csit(1018,9 + i,adven[i].name); + } + else cd_activate_item(1018, 9 + i, 0); + } + + while (dialog_not_toast) + ModalDialog(); + + cd_kill_dialog(1018,0); + + return dialog_answer; +} + +short select_pc(short active_only,short free_inv_only) +//active_only; // 0 - no 1 - yes 2 - disarm trap +{ + if (active_only == 2) + return char_select_pc(active_only,free_inv_only,"Trap! Who will disarm?"); + else return char_select_pc(active_only,free_inv_only,"Select a character:"); +} + + +BOOL CALLBACK choice_dialog_proc + (HWND hDlg, UINT message, WPARAM wParam, LPARAM) { + + + + + + + test_dlog3 = hDlg; + + switch (message) { + case WM_INITDIALOG: + center_window(hDlg); + + return TRUE; + case WM_PAINT: + + return FALSE; + + case WM_COMMAND: + answer_given = (short) LOWORD(wParam); + if (answer_given == 100) + answer_given = 2; + EndDialog(hDlg, 0); + return TRUE; + } + return FALSE; + } + +short choice_dialog(short,short num) +{ + + + store_focus = GetFocus(); + dlog_proc1 = (FARPROC) choice_dialog_proc; + if (dlog_proc1 == NULL) { + return 1; + } + DialogBox((HINSTANCE) store_hInstance, MAKEINTRESOURCE(num), store_focus, (DLGPROC) dlog_proc1); + + DestroyWindow(test_dlog3); + SetFocus(store_focus); + return answer_given; +} + + + +short party_total_level() +{ + short i,j = 0; + + for (i = 0; i < 6; i++) + if (adven[i].main_status == 1) + j += adven[i].level; + return j; +} + + + +short luck_total() +{ + short i = 0; + + for (i = 0; i < 6; i++) + if (adven[i].main_status == 1) + i += adven[i].skills[18]; + return i; +} + +void display_traits_graphics() +{ + short i,store; + + for (i = 0; i < 3; i++) { + cd_set_led(1013,4 + i,(store_pc->race == i) ? 1 : 0); + } + for (i = 0; i < 10; i++) { + cd_set_led(1013,7 + i,(store_pc->traits[i] > 0) ? 1 : 0); + } + for (i = 0; i < 5; i++) { + cd_set_led(1013,36 + i,(store_pc->traits[10 + i] > 0) ? 1 : 0); + } + + store = get_tnl(store_pc); + cdsin(1013,18,store); +} + +void pick_race_abil_event_filter(short item_hit) +{ + char abil_str[256]; + pc_record_type *pc; + + pc = store_pc; + switch (item_hit) { + case 3: + dialog_not_toast = FALSE; + break; + case 4: case 5: case 6: + if (store_trait_mode == 0) + pc->race = item_hit - 4; + display_traits_graphics(); + get_str(abil_str,5,12 + item_hit); + csit(1013,19,(char *) abil_str); + break; + case 36: case 37: case 38: case 39: case 40: + if (store_trait_mode != 1) + pc->traits[item_hit - 36 + 10] = (pc->traits[item_hit - 36 + 10] == TRUE) ? FALSE : TRUE; + display_traits_graphics(); + get_str(abil_str,5,item_hit - 36 + 11); + csit(1013,19,(char *) abil_str); + break; + default: + if (item_hit >= 100) + return; + if (store_trait_mode != 1) + pc->traits[item_hit - 7] = (pc->traits[item_hit - 7] == TRUE) ? FALSE : TRUE; + display_traits_graphics(); + get_str(abil_str,5,item_hit - 6); + csit(1013,19,(char *) abil_str); + break; + } + +} + +void pick_race_abil(pc_record_type *pc,short mode,short parent_num) +//mode; // 0 - edit 1 - just display 2 - can't change race +{ + char *start_str1 = "Click on advantage button for description."; + char *start_str2 = "Click on advantage button to add/lose."; + + + mode = 0; + store_trait_mode = mode; + store_pc = pc; + make_cursor_sword(); + + cd_create_dialog_parent_num(1013,parent_num); + + display_traits_graphics(); + if (mode == 1) + csit(1013,19,start_str1); + else csit(1013,19,start_str2); + + while (dialog_not_toast) + ModalDialog(); + + cd_kill_dialog(1013,0); + dialog_not_toast = TRUE; +} + + +short get_tnl(pc_record_type *pc) +{ + short tnl = 100,i,store_per = 100; + short rp[3] = {0,12,20}; + short ap[15] = {10,20,8,10,4, 6,10,7,12,15, -10,-8,-8,-20,-8}; + + tnl = (tnl * (100 + rp[pc->race])) / 100; + for (i = 0; i < 15; i++) + if (pc->traits[i] == TRUE) + store_per = store_per + ap[i]; + + tnl = (tnl * store_per) / 100; + + return tnl; +} diff --git a/Blades of Exile Char Editor/EDITORS.H b/Blades of Exile Char Editor/EDITORS.H new file mode 100644 index 00000000..8561e4d7 --- /dev/null +++ b/Blades of Exile Char Editor/EDITORS.H @@ -0,0 +1,22 @@ +Boolean give_to_pc(short pc_num,item_record_type item, short print_result); +Boolean give_to_party(item_record_type item,short print_result); +void give_gold(short amount,Boolean print_result); +Boolean take_gold(short amount,Boolean print_result); +short pc_has_space(short pc_num); +void take_item(short pc_num,short which_item); +void fancy_choice_dialog_event_filter (short item_hit); +short fancy_choice_dialog(short which_dlog,short parent); +void select_pc_event_filter (short item_hit); +short char_select_pc(short active_only,short free_inv_only,char *title); +short select_pc(short active_only,short free_inv_only); +short choice_dialog(short pic,short num); +Boolean give_spec_items_event_filter (short item_hit); +void give_spec_items(); +short party_total_level(); +short luck_total(); +void display_traits_graphics(); +void pick_race_abil_event_filter(short item_hit); +void pick_race_abil(pc_record_type *pc,short mode,short parent_num); +short get_tnl(pc_record_type *pc); +void reset_boats(); +void combine_things(short pc_num); diff --git a/Blades of Exile Char Editor/EDSOUND.CPP b/Blades of Exile Char Editor/EDSOUND.CPP new file mode 100644 index 00000000..6c698b51 --- /dev/null +++ b/Blades of Exile Char Editor/EDSOUND.CPP @@ -0,0 +1,313 @@ +#include "math.h" +#include +#include + +#include "stdio.h" + +#include "global.h" +#include "edsound.h" + +#define NUM_SOUNDS 100 + +HGLOBAL sound_handles[NUM_SOUNDS]; +char * snds[NUM_SOUNDS]; + +extern HINSTANCE store_hInstance; + +extern Boolean play_sounds,in_startup_mode; +extern HWND mainPtr; +extern Boolean gInBackground; +extern party_record_type far party; +extern Boolean cat,cow,chicken,dog,sheep,monsters_going; +extern short num_chirps_played,overall_mode; + +short last_played = 10000; +short error_beeps = 0; +short store_last_sound_played = 0; + +Boolean far always_asynch[100] = {FALSE,FALSE,FALSE,FALSE,FALSE, + TRUE,TRUE,FALSE,FALSE,FALSE, + TRUE,FALSE,FALSE,FALSE,FALSE, // 10 + FALSE,FALSE,FALSE,FALSE,FALSE, + FALSE,FALSE,TRUE,FALSE,TRUE, // 20 + TRUE,FALSE,FALSE,FALSE,FALSE, + FALSE,FALSE,FALSE,FALSE,TRUE, // 30 + FALSE,FALSE,TRUE,FALSE,TRUE, + FALSE,TRUE,TRUE,TRUE,TRUE, // 40 + TRUE,TRUE,TRUE,TRUE,TRUE, + TRUE,FALSE,FALSE,TRUE,FALSE, // 50 + TRUE,FALSE,FALSE,FALSE,FALSE, + FALSE,TRUE,FALSE,FALSE,FALSE, // 60 + FALSE,FALSE,FALSE,FALSE,FALSE, + FALSE,FALSE,FALSE,FALSE,FALSE, // 70 + FALSE,TRUE,TRUE,TRUE,TRUE, + TRUE,TRUE,TRUE,TRUE,FALSE, // 80 + TRUE,FALSE,FALSE,FALSE,FALSE, + FALSE,TRUE,FALSE,FALSE,FALSE, // 90 + FALSE,FALSE,FALSE,FALSE,FALSE}; +Boolean far load_when_play[100] = { +0,0,1,1,1,0,0,1,1,1, +0,0,0,1,0,1,1,1,1,1, +1,1,0,1,1,1,1,0,1,1, +1,1,1,1,0,1,1,0,1,1, +1,1,1,1,1,1,1,0,0,0, +0,1,1,0,1,0,1,1,1,1, // 50 +1,0,1,1,1,1,1,1,1,0, +0,0,0,0,0,0,0,0,0,0, // 70 +1,1,1,1,1,0,0,0,0,0, +1,0,1,1,1,1,1,1,1,0 +}; + +short far can_ignore[100] = { +0,0,0,0,0,5,3,0,0,0, +5,5,5,0,5,0,0,0,0,0, +0,0,5,0,0,0,0,0,0,2, +2,2,0,0,0,0,0,0,0,0, +0,0,0,0,0,0,0,1,1,1, +1,0,0,5,0,1,0,0,0,0, // 50 +0,0,0,0,5,0,0,0,0,0, +0,0,0,0,0, 0,5,5,5,5, // 70 +4,4,4,4,0,0,0,0,0,0, +0,5,5,0,0,0,0,0,0,0}; +// 1 - polite asych, 1 or 2 or 3- lose easily when pref is set for fewer snds +// 3 can be async +// 4 - nostop asynch ... when 4, this sound is NOSTOP, i.e. when played, is played +// asynch, and refuses all other sounds. Sounds that come in are ignored, and +// disappear into the ether +// 5 - finally, bold asynch ... when 5, this sound is NOSTOP, i.e. when played, is played +// asynch, and refuses all other sounds. When a sound is played on top of this, game +// hangs on until sound is done, and then and only then plays later sound. + + +short num_devs; +Boolean sounds_fucked = FALSE; +long intro_music_start_time = -1; + +void load_sounds () +{ + short i,t,err; + HRSRC h; + char snd_name[20]; + WAVEOUTCAPS wavecaps; + + t = waveOutGetNumDevs(); + if (t == 0) { + sounds_fucked = TRUE; + return; + } + err = waveOutGetDevCaps(0,&wavecaps,sizeof(WAVEOUTCAPS)); +if (err != 0) { + sounds_fucked = TRUE; + switch (err) { + case MMSYSERR_BADDEVICEID: + MessageBox(mainPtr,"Cannot initialize sounds - No sound device detected. Game can still be played, but quietly.", + "Sound Error",MB_OK | MB_ICONEXCLAMATION); + return; + case MMSYSERR_NODRIVER: + MessageBox(mainPtr,"Cannot initialize sounds - No driver installed. Game can still be played, but quietly.", + "Sound Error",MB_OK | MB_ICONEXCLAMATION); + return; + case MMSYSERR_NOMEM : + MessageBox(mainPtr,"Cannot initialize sounds - can't find enough memory. Game can still be played, but quietly.", + "Sound Error",MB_OK | MB_ICONEXCLAMATION); + return; + case MMSYSERR_ALLOCATED: + MessageBox(mainPtr,"Cannot initialize sounds - sound card already allocated. Game can still be played, but quietly.", + "Sound Error",MB_OK | MB_ICONEXCLAMATION); + return; + case MMSYSERR_ERROR: + MessageBox(mainPtr,"Cannot initialize sounds - internal error. Game can still be played, but quietly.", + "Sound Error",MB_OK | MB_ICONEXCLAMATION); + return; + default: + MessageBox(mainPtr,"Cannot initialize sounds - unidentified error. Game can still be played, but quietly.", + "Sound Error",MB_OK | MB_ICONEXCLAMATION); + return; + + } + + } + + for (i = 0; i < NUM_SOUNDS; i++) { + sound_handles[i] = NULL; + load_when_play[i] = TRUE; + if (load_when_play[i] == FALSE) { + sprintf((char *)snd_name,"#%d",i + 1); + h = FindResource(store_hInstance,snd_name,"#100"); + + sound_handles[i] = LoadResource(store_hInstance,h); + snds[i] = (char*) LockResource(sound_handles[i]); + } + } + +} + +void play_sound(short which) // if < 0, play asynch +{ + if (PSD[304][9] > 0) + return; + if (in_startup_mode == TRUE) { + // put some in foreground check here + } + if (play_sounds == TRUE) + force_play_sound(which); +} + + +void force_play_sound(short which) +{ + short i,num_fails = 0; + char snd_name[30]; + Boolean asyn = FALSE,a_sound_did_get_played = FALSE; + Boolean check_sound; + HRSRC h; + + if ((sounds_fucked == TRUE) || (play_sounds == FALSE)) + return; + if (which < 0) { + asyn = TRUE; + which = which * -1; + } + + if (which >= 100) + return; + + if ((always_asynch[which] == TRUE) && + ((can_ignore[which] == 1) || (can_ignore[which] >= 3))) + asyn = TRUE; + if ((can_ignore[which] > 0) && (can_ignore[which] < 5) && (party.stuff_done[305][5] == 1)) + return; + if ((can_ignore[which] != 1) && (can_ignore[which] < 3)) + asyn = FALSE; + if ((party.stuff_done[305][5] == 1) && (can_ignore[which] < 5)) + asyn = FALSE; + + if ((load_when_play[which] == TRUE) && (sound_handles[which] == NULL)) { + asyn = FALSE; + sprintf((char *)snd_name,"#%d",which + 1); + h = FindResource(store_hInstance,snd_name,"#100"); + + sound_handles[which] = LoadResource(store_hInstance,h); + snds[which] = (char*) LockResource(sound_handles[which]); + + } + + if (store_last_sound_played == 6) { + sndPlaySound(NULL,0); + } + + if (asyn == TRUE) { + if (can_ignore[which] >= 4) + check_sound = sndPlaySound(snds[which],SND_ASYNC | SND_MEMORY | SND_NOSTOP); + else check_sound = sndPlaySound(snds[which],SND_ASYNC | SND_MEMORY); + + while (check_sound == FALSE) { + + if (can_ignore[store_last_sound_played] == 4) {// then sound goes away + return; + } + + + num_fails++; + if (num_fails < 40) + sound_pause(25); + else { + MessageBox(mainPtr,"Cannot play sounds - Sounds stuck error a. Game can still be played, but quietly.", + "Sound Error",MB_OK | MB_ICONEXCLAMATION); + //print_nums(111,which,num_fails); + //sounds_fucked = TRUE; + return; + } + //ASB ("Asynch clearing buffer!!!"); + //check_sound = sndPlaySound(snds[99],SND_SYNC | SND_MEMORY); + sndPlaySound(NULL,0); + + if (can_ignore[which] >= 4) + check_sound = sndPlaySound(snds[which],SND_ASYNC | SND_MEMORY | SND_NOSTOP); + else check_sound = sndPlaySound(snds[which],SND_ASYNC | SND_MEMORY); + } + a_sound_did_get_played = TRUE; + } + else { + if (can_ignore[which] >= 4) + check_sound = sndPlaySound(snds[which],SND_SYNC | SND_MEMORY | SND_NOSTOP); + else check_sound = sndPlaySound(snds[which],SND_SYNC | SND_MEMORY); + while (check_sound == FALSE) { + if (can_ignore[store_last_sound_played] == 4) {// then sound goes away + //ASB("Sound overruled by asynch sound."); + return; + } + + + num_fails++; + if (num_fails < 40) + sound_pause(25); + else { + MessageBox(mainPtr,"Cannot play sounds - Sounds stuck error b. Game can still be played, but quietly.", + "Sound Error",MB_OK | MB_ICONEXCLAMATION); + //print_nums(222,which,num_fails); + //sounds_fucked = TRUE; + return; + } + //ASB ("Asynch clearing buffer!!!"); + //check_sound = sndPlaySound(snds[99],SND_SYNC | SND_MEMORY); + sndPlaySound(NULL,0); + + if (can_ignore[which] >= 4) + check_sound = sndPlaySound(snds[which],SND_SYNC | SND_MEMORY | SND_NOSTOP); + else check_sound = sndPlaySound(snds[which],SND_SYNC | SND_MEMORY); + } + a_sound_did_get_played = TRUE; + } + + store_last_sound_played = which; + + if ((load_when_play[which] == TRUE) && (asyn == FALSE)) { + // deleted a seemingly extraneous LoadResource here + + + sound_handles[which] = NULL; + } + for (i = 0; i < NUM_SOUNDS; i++) + if ((load_when_play[which] == TRUE) && (sound_handles[which] != NULL) + && (a_sound_did_get_played == TRUE) && (i != which)){ + // deleted a seemingly extraneous LoadResource here + + + sound_handles[i] = NULL; + } + +} + +void kill_sound() +{ + sndPlaySound(NULL,0); +} +void one_sound(short which) +{ + if (which == last_played) + return; + play_sound(which); + last_played = which; +} + +void clear_sound_memory() +{ + last_played = 100; +} + +void flip_sound() +{ + play_sounds = (play_sounds == TRUE) ? FALSE : TRUE; +} + + +void sound_pause(long len) { + long t1,t2; + + t1 = (long) GetCurrentTime(); + t2 = t1; + while (t2 - t1 < len) { + t2 = (long)GetCurrentTime(); + } +} diff --git a/Blades of Exile Char Editor/EDSOUND.H b/Blades of Exile Char Editor/EDSOUND.H new file mode 100644 index 00000000..3629f07e --- /dev/null +++ b/Blades of Exile Char Editor/EDSOUND.H @@ -0,0 +1,7 @@ +void load_sounds (); +void play_sound(short which) ; // if < 0, play asynch +void force_play_sound(short which); +void one_sound(short which); +void clear_sound_memory(); +void sound_pause(long len); +void flip_sound(); diff --git a/Blades of Exile Char Editor/GLOBAL.CPP b/Blades of Exile Char Editor/GLOBAL.CPP new file mode 100644 index 00000000..2a057499 --- /dev/null +++ b/Blades of Exile Char Editor/GLOBAL.CPP @@ -0,0 +1,151 @@ +#include +#include "global.h" +#include "math.h" +#include + +extern short give_delays; + +RECT RECT16::rect32() +{ + RECT tmp; + tmp.left = left; + tmp.top = top; + tmp.right = right; + tmp.bottom = bottom; + return tmp; +} + +RECT16::RECT16 (const RECT & tmp) +{ + left = tmp.left; + top = tmp.top; + right = tmp.right; + bottom = tmp.bottom; +} + +RECT16 & RECT16::operator=(const RECT & tmp) +{ + left = tmp.left; + top = tmp.top; + right = tmp.right; + bottom = tmp.bottom; + return (*this); +} + +POINT MAKEPOINT(LONG lParam) +{ + POINT point; + + point.x = LOWORD(lParam); + point.y = HIWORD(lParam); + + return point; +} + +short get_ran (short times,short min,short max) +{ + short store; + short i, to_ret = 0; + + if ((max - min + 1) == 0) + return 0; + for (i = 1; i < times + 1; i++) { + store = rand() % (max - min + 1); + to_ret = to_ret + min + store; + } + return to_ret; +} + +Boolean same_point(location p1,location p2) +{ + if ((p1.x == p2.x) & (p1.y == p2.y)) + return TRUE; + else return FALSE; +} + +short move_to_zero(short val) +{ + if (val < 0) + return val + 1; + if (val > 0) + return val - 1; + return val; +} + +/* +short max(short a,short b) +{ + if (a > b) + return a; + else return b; +} + +short min(short a,short b) +{ + if (a < b) + return a; + else return b; +}*/ + +short minmax(short min,short max,short k) +{ + if (k < min) + return min; + if (k > max) + return max; + return k; +} + +short s_pow(short x,short y) +{ + return (short) pow((double) x, (double) y); +} + +short a_v(short x) +{ + if (x < 0) + return (-1 * x); + else return x; +} +short ex_abs(short x) +{ + if (x < 0) + return (-1 * x); + else return x; +} + +void Delay(short val,long *) +{ + long then,now,wait_val; + + wait_val = (long) val; + wait_val = wait_val * 16; + then = (long)GetCurrentTime(); + now = then; + while (now - then < wait_val) { + now = (long) GetCurrentTime(); + } +} + +void pause(short length) +{ + long dummy,len; + + len = (long) length; + + if (give_delays == 0) + Delay(len, &dummy); +} + +void beep() +{ + long dummy; + + MessageBeep(MB_OK); + Delay(30,&dummy); + } + +void SysBeep(short) +{ + MessageBeep(MB_OK); +} diff --git a/Blades of Exile Char Editor/GLOBAL.H b/Blades of Exile Char Editor/GLOBAL.H new file mode 100644 index 00000000..c0685190 --- /dev/null +++ b/Blades of Exile Char Editor/GLOBAL.H @@ -0,0 +1,463 @@ + +#define T_M 60 + +#define NUM_TOWN_ITEMS 115 + +#define SLEEP_TICKS 0L +#define MOUSE_REGION 0L +#define DRAG_EDGE 15 + +#define DISPLAY_LEFT 23 +#define DISPLAY_TOP 23 +#define BITMAP_WIDTH 28 +#define BITMAP_HEIGHT 36 + +#define STORED_GRAPHICS 240 + +#define PC_WIN_UL_X 291 +#define PC_WIN_UL_Y 5 +#define ITEM_WIN_UL_X 291 +#define ITEM_WIN_UL_Y 130 +#define TEXT_WIN_UL_X 291 +#define TEXT_WIN_UL_Y 283 +#define NUM_BUTTONS 15 +#define PSD party.stuff_done +#define DES display_enc_string +#define FCD fancy_choice_dialog +#define D2ES display_2_enc_string +#define NUM_MONST_G 173 + +#define DOOR_LIGHT can_enter = run_trap(7,&PSD[c_town.town_num][which],4220,0); break; +#define DOOR_HEAVY can_enter = run_trap(7,&PSD[c_town.town_num][which],4220,20); break; +#define DOOR_ALARM can_enter = run_trap(7,&PSD[c_town.town_num][which],4220,11); break; +#define DRESSER_LIGHT can_enter = run_trap(7,&PSD[c_town.town_num][which],4221,0); break; +#define DRESSER_HEAVY can_enter = run_trap(7,&PSD[c_town.town_num][which],4221,20); break; +#define DRESSER_ALARM can_enter = run_trap(7,&PSD[c_town.town_num][which],4221,11); break; +#define FLOOR_LIGHT can_enter = run_trap(7,&PSD[c_town.town_num][which],4222,0); break; +#define FLOOR_HEAVY can_enter = run_trap(7,&PSD[c_town.town_num][which],4222,20); break; +#define FLOOR_ALARM can_enter = run_trap(7,&PSD[c_town.town_num][which],4222,11); break; +#define CHEST_LIGHT can_enter = run_trap(7,&PSD[c_town.town_num][which],3450,0); break; +#define CHEST_HEAVY can_enter = run_trap(7,&PSD[c_town.town_num][which],3450,20); break; +#define CHEST_ALARM can_enter = run_trap(7,&PSD[c_town.town_num][which],3450,11); break; + +#define CDGT cd_retrieve_text_edit_str +#define CDGN cd_retrieve_text_edit_num +#define CDST cd_set_text_edit_str +#define CDSN cd_set_text_edit_num + +#define huge + +struct RECT16 +{ + short left; + short top; + short right; + short bottom; + + RECT rect32(); + RECT16 () {} + RECT16 (const RECT & ); + RECT16 & operator=(const RECT &); +}; + +extern POINT MAKEPOINT(LONG lparam); + +typedef unsigned char BYTE; +typedef char Boolean; + +typedef struct { + char x,y; + } location; +typedef struct { + short x,y;} shortloc; + +typedef struct { + short type,sd1,sd2,pic,m1,m2,ex1a,ex1b,ex2a,ex2b,jumpto; + } special_node_type; + +typedef struct { + short personality,type; + char link1[4],link2[4]; + short extras[4]; + } talking_node_type; + +typedef struct { + unsigned char strlens[200]; + talking_node_type talk_nodes[60]; + } talking_record_type; + +typedef struct { + short picture; + unsigned char blockage,flag1,flag2,special,trans_to_what,fly_over,boat_over; + unsigned char block_horse,light_radius,step_sound,shortcut_key,res1,res2,res3; + } terrain_type_type; + +typedef struct { + unsigned char monst[4]; + } wandering_type; + +typedef struct { + unsigned char monst[7]; + unsigned char friendly[3]; + short spec_on_meet,spec_on_win,spec_on_flee,cant_flee; + short end_spec1,end_spec2; +} out_wandering_type; + +typedef struct { + unsigned char terrain[48][48]; + location special_locs[18]; + unsigned char special_id[18]; + location exit_locs[8]; + char exit_dests[8]; + location sign_locs[8]; + out_wandering_type wandering[4],special_enc[4]; + location wandering_locs[4]; + RECT16 info_rect[8]; + unsigned char strlens[180]; + special_node_type specials[60]; + } outdoor_record_type; + +typedef struct { + unsigned char number; + unsigned char start_attitude; + location start_loc; + unsigned char mobile; + unsigned char time_flag; + unsigned char extra1,extra2; + short spec1, spec2; + char spec_enc_code,time_code; + short monster_time,personality; + short special_on_kill,facial_pic; + + } creature_start_type; + + +typedef struct { + short variety, item_level; + char awkward, bonus, protection, charges, type; + unsigned char graphic_num,ability, type_flag, is_special; + short value; + Boolean identified, magic; + unsigned char weight, description_flag; + char full_name[25], name[15]; + unsigned char reserved1,reserved2; + unsigned char magic_use_type, ability_strength, treas_class, real_abil; +} short_item_record_type; + + +typedef struct { + short variety, item_level; + char awkward, bonus, protection, charges, type, magic_use_type; + unsigned char graphic_num,ability, ability_strength,type_flag, is_special,a; + short value; + unsigned char weight, special_class; + location item_loc; + char full_name[25], name[15]; + unsigned char treas_class,item_properties,reserved1,reserved2; +} item_record_type; + +typedef struct { + location item_loc; + short item_code,ability; + unsigned char charges,always_there,property,contained; + } preset_item_type; + +typedef struct { + location field_loc; + short field_type; + } preset_field_type; + +typedef struct { + short town_chop_time,town_chop_key; + wandering_type wandering[4]; + location wandering_locs[4]; + location special_locs[50]; + unsigned char spec_id[50]; + location sign_locs[15]; + short lighting; + location start_locs[4]; + location exit_locs[4]; + short exit_specs[4]; + RECT16 in_town_rect; + preset_item_type preset_items[64]; + short max_num_monst; + preset_field_type preset_fields[50]; + short spec_on_entry,spec_on_entry_if_dead; + short timer_spec_times[8]; + short timer_specs[8]; + unsigned char strlens[180]; + special_node_type specials[100]; + unsigned char specials1,specials2,res1,res2; + short difficulty; + } town_record_type; + + + +typedef struct { + unsigned char terrain[64][64]; + RECT16 room_rect[16]; + creature_start_type creatures[60]; + unsigned char lighting[8][64]; + } big_tr_type; + +typedef struct { + unsigned char terrain[48][48]; + RECT16 room_rect[16]; + creature_start_type creatures[40]; + unsigned char lighting[6][48]; + } ave_tr_type; + +typedef struct { + unsigned char terrain[32][32]; + RECT16 room_rect[16]; + creature_start_type creatures[30]; + unsigned char lighting[4][32]; + } tiny_tr_type; + +typedef struct { + short block_type; + short block_destroy_time; + char block_alignment; + char block_key_time; + location block_loc; + } city_block_type; + +typedef struct { + RECT16 what_rect; + unsigned char ter_type; + unsigned char hollow; + } city_ter_rect_type; + +typedef struct { + creature_start_type creatures[30]; + city_block_type city_block[15]; + city_ter_rect_type city_ter_rect[10]; + } template_town_type; + +typedef struct { + item_record_type scen_items[400]; + char monst_names[256][20]; + char ter_names[256][30]; + } scen_item_data_type; + +typedef struct { + short ter_type,item_num[10],item_odds[10],property; + } item_storage_shortcut_type; + +typedef struct { + unsigned char m_num,level,m_name[26]; + short health,m_health,mp,max_mp; + unsigned char armor,skill; + short a[3]; + unsigned char a1_type,a23_type,m_type,speed,ap,mu,cl,breath,breath_type,treasure,spec_skill,poison; + short morale,m_morale; + short corpse_item,corpse_item_chance; + short status[15]; + unsigned char direction,immunities,x_width,y_width,radiate_1,radiate_2; + unsigned char default_attitude,summon_type,default_facial_pic,res1,res2,res3; + short picture_num; + + } monster_record_type; + +typedef struct { + short active,attitude; + unsigned char number; + location m_loc; + monster_record_type m_d; + Boolean mobile; + short summoned; + creature_start_type monst_start; + } creature_data_type; + + +typedef struct { + location horse_loc,horse_loc_in_sec,horse_sector; + short which_town; + Boolean exists,property; + } horse_record_type; +typedef struct { + location boat_loc,boat_loc_in_sec,boat_sector; + short which_town; + Boolean exists,property; +} boat_record_type; + +typedef struct { + unsigned char flag1, flag2, flag3, flag4; + unsigned char ver[3],min_run_ver,prog_make_ver[3],num_towns; + unsigned char out_width,out_height,difficulty,intro_pic,default_ground; + } scen_header_type; + + typedef struct { + unsigned char flag1, flag2, flag3, flag4; + unsigned char ver[3],min_run_ver,prog_make_ver[3],num_towns; + unsigned char out_width,out_height,difficulty,intro_pic,default_ground; + unsigned char town_size[200]; + unsigned char town_hidden[200],a; + short flag_a; + short intro_mess_pic,intro_mess_len; + location where_start,out_sec_start,out_start; + short which_town_start; + short flag_b; + short town_data_size[200][5]; + short town_to_add_to[10]; + short flag_to_add_to_town[10][2]; + short flag_c; + short out_data_size[100][2]; + RECT16 store_item_rects[3]; + short store_item_towns[3]; + short flag_e; + short special_items[50]; + short special_item_special[50]; + short rating,uses_custom_graphics; + short flag_f; + monster_record_type scen_monsters[256]; + boat_record_type scen_boats[30]; + horse_record_type scen_horses[30]; + short flag_g; + terrain_type_type ter_types[256]; + short scenario_timer_times[20]; + short scenario_timer_specs[20]; + short flag_h; + special_node_type scen_specials[256]; + item_storage_shortcut_type storage_shortcuts[10]; + short flag_d; + unsigned char scen_str_len[300]; + short flag_i; + location last_out_edited; + short last_town_edited; + + } scenario_data_type; + +// for game +typedef struct { + short personality; + short town_num; + short str1,str2; + } talk_save_type; + +typedef struct { + creature_data_type dudes[60]; + short which_town; + short friendly; + } creature_list_type; + +typedef struct { + short town_num, difficulty; + town_record_type town; + char explored[64][64]; + Boolean hostile; + creature_list_type monst; + Boolean in_boat; + location p_loc; + } current_town_type; + +typedef struct { + Boolean exists; + short direction; + out_wandering_type what_monst; + location which_sector,m_loc; + } outdoor_creature_type; + +typedef struct { + long age; + short gold,food; + unsigned char stuff_done[310][10],item_taken[200][8]; + short light_level; + location outdoor_corner,i_w_c,p_loc,loc_in_sec; + boat_record_type boats[30]; + horse_record_type horses[30]; + creature_list_type creature_save[4]; + short in_boat,in_horse; + outdoor_creature_type out_c[10]; + item_record_type magic_store_items[5][10]; + short imprisoned_monst[4]; + char m_seen[256]; + char journal_str[50]; + short journal_day[50]; + short special_notes_str[140][2]; + talk_save_type talk_save[120]; + short direction,at_which_save_slot; + char alchemy[20]; + Boolean can_find_town[200]; + short key_times[100]; + short party_event_timers[30]; + short global_or_town[30]; + short node_to_call[30]; + char spec_items[50],help_received[120]; + short m_killed[200]; + long total_m_killed,total_dam_done,total_xp_gained,total_dam_taken; + char scen_name[256]; + } party_record_type; + +typedef struct { + char town_maps[100][8][64]; + } stored_town_maps_type; +typedef struct { + char town_strs[180][256]; + } piles_of_stuff_dumping_type; +typedef struct { + char scen_header_strs[25][3][80]; + char scen_names[25][256]; + scen_item_data_type scen_item_list; + } piles_of_stuff_dumping_type2; +typedef struct { + char far talk_strs[170][256]; + } piles_of_stuff_dumping_type3; +typedef struct { + char out_strs[9][256]; + } outdoor_strs_type; +typedef struct { + outdoor_strs_type far outdoor_text[2][2]; + } piles_of_stuff_dumping_type4; +typedef struct { +char far scen_strs[160][256]; + } piles_of_stuff_dumping_type5; + +typedef struct { + short main_status; + char name[20]; + short skills[30]; + short max_health,cur_health,max_sp,cur_sp,experience,skill_pts,level; + short status[15]; + item_record_type items[24]; + Boolean equip[24]; + Boolean priest_spells[62],mage_spells[62]; + short which_graphic,weap_poisoned; + Boolean advan[15],traits[15]; + short race,exp_adj,direction; + } pc_record_type; + +typedef struct { + unsigned char setup[4][64][64]; + } setup_save_type; + +typedef struct { + item_record_type items[NUM_TOWN_ITEMS]; + } town_item_list; + +typedef struct {short i;} flag_type; + +typedef struct {unsigned char pattern[9][9];} effect_pat_type; + +typedef struct { + item_record_type items[NUM_TOWN_ITEMS]; + } stored_items_list_type; + +typedef struct { + char outdoor_maps[100][6][48]; + } stored_outdoor_maps_type; + + +short s_pow(short x,short y); +short a_v(short x); +short ex_abs(short x); +short get_ran (short times,short min,short max); +Boolean same_point(location p1,location p2); +void pause(short length); +short minmax(short min,short max,short k); +/*short min(short a,short b); +short max(short a,short b);*/ +short move_to_zero(short val); +void Delay(short val,long *dummy); +void alter_rect(RECT *r) ; +Boolean sd_legit(short a, short b); diff --git a/Blades of Exile Char Editor/GRAPHICS.CPP b/Blades of Exile Char Editor/GRAPHICS.CPP new file mode 100644 index 00000000..9bc3a39d --- /dev/null +++ b/Blades of Exile Char Editor/GRAPHICS.CPP @@ -0,0 +1,1010 @@ +#include + +#include "stdio.h" +#include "string.h" +#include "global.h" +#include "graphics.h" +#include "edsound.h" +#include "dlogtool.h" +#include "graphutl.h" + + +extern short store_size; + +/* Adventure globals */ +extern party_record_type far party; +extern pc_record_type far adven[6]; +extern outdoor_record_type far outdoors[2][2]; +extern current_town_type far c_town; +extern big_tr_type far t_d; +extern town_item_list far t_i; +extern unsigned char far out[96][96]; +extern unsigned char far out_e[96][96]; +extern setup_save_type far setup_save; +extern stored_items_list_type far stored_items[3]; +extern stored_town_maps_type far maps; +extern stored_outdoor_maps_type far o_maps; + +extern HWND mainPtr; +extern Boolean play_sounds,file_in_mem; + +extern short store_flags[3]; +extern HBITMAP button_num_gworld; +extern short current_active_pc,ulx,uly; +extern Boolean dialog_not_toast,party_in_scen; + +extern HFONT font,italic_font,underline_font,bold_font,tiny_font,small_bold_font; +extern HCURSOR arrow_curs[3][3], sword_curs, boot_curs, key_curs, target_curs,talk_curs,look_curs; +//extern HPALETTE hpal; +extern HDC main_dc,main_dc2,main_dc3; +HBITMAP title_gworld,pc_gworld,dlogpics_gworld,buttons_gworld; +HBITMAP dlg_buttons_gworld,mixed_gworld,dialog_pattern_gworld,pattern_gworld; +RECT whole_win_rect; + RECT title_from = {41,0,380,70}; +extern RECT pc_area_buttons[6][4] ; // 0 - whole 1 - pic 2 - name 3 - stat strs 4,5 - later +extern RECT item_string_rects[24][4]; // 0 - name 1 - drop 2 - id 3 - +extern RECT pc_info_rect; // Frame that holds a pc's basic info and items +extern RECT name_rect; +extern RECT pc_race_rect; +extern RECT info_area_rect; +extern RECT hp_sp_rect; +extern RECT skill_rect; +extern RECT pc_skills_rect[19]; +extern RECT status_rect; +extern RECT pc_status_rect[10]; +extern RECT traits_rect; +extern RECT pc_traits_rect[16]; +extern RECT edit_rect[5][2]; +extern HINSTANCE store_hInstance; + +short store_str1a; +short store_str1b; +short store_str2a; +short store_str2b; +short store_which_string_dlog; +short store_page_on,store_num_i; + RECT frame_rect = {0,0,605,440}; +RECT ed_buttons_from[2] = {{0,0,57,57},{57,0,114,57}}; +short current_pressed_button = -1; + +void init_main_buttons() +{ + + short i; + + short indent = 0, indent2 = 0; + RECT base_rect; + RECT active_area_rect = {0,0,590,440}; + + + GetClientRect(mainPtr,&whole_win_rect); + ulx = (whole_win_rect.right - 600) / 2; + uly = (whole_win_rect.bottom - 440) / 2; + + pc_info_rect= active_area_rect; + InflateRect(&pc_info_rect,-100,-100); + pc_info_rect.bottom+=52; + pc_info_rect.top-=25; + pc_info_rect.right+=5; + name_rect.left = pc_info_rect.left; + name_rect.right = pc_info_rect.left + 100; + name_rect.bottom = pc_info_rect.top + 15; + name_rect.top = pc_info_rect.top; + + //Initialize pc_area_buttons + pc_area_buttons[0][0].top=pc_info_rect.top; + pc_area_buttons[0][0].bottom=pc_area_buttons[0][0].top + 57 ; + + for(i = 0; i < 6; i++) + { + pc_area_buttons[i][0].left = 20; + pc_area_buttons[i][0].right = pc_area_buttons[0][0].left + 57; + pc_area_buttons[i][2].left = 20; + pc_area_buttons[i][2].right = pc_area_buttons[i][2].left + 56; + pc_area_buttons[i][3].left = 20; + pc_area_buttons[i][3].right = pc_area_buttons[i][3].left + 56; + pc_area_buttons[i][1].left = 34; + pc_area_buttons[i][1].right = pc_area_buttons[i][1].left + 28; + + pc_area_buttons[i][0].top = pc_area_buttons[0][0].top + 60*i; + pc_area_buttons[i][0].bottom = pc_area_buttons[0][0].bottom + 60*i; + + pc_area_buttons[i][1].top = pc_area_buttons[i][0].top+3; + pc_area_buttons[i][1].bottom = pc_area_buttons[i][2].top = pc_area_buttons[i][0].bottom - 18; + pc_area_buttons[i][2].bottom = pc_area_buttons[i][3].top = pc_area_buttons[i][0].bottom - 9; + pc_area_buttons[i][3].bottom = pc_area_buttons[i][0].bottom; + OffsetRect(&pc_area_buttons[i][2],0,4); + OffsetRect(&pc_area_buttons[i][3],0,-2); + } + + //Initialize the edit_rect buttons + edit_rect[0][0].top = pc_info_rect.top; + for(i = 0; i < 5; i++) { + if(i >= 2) + indent = 7; + else + indent = 0; + if( i == 4) + indent2 = 1; + edit_rect[i][0].top = edit_rect[0][0].top + 66*i; + edit_rect[i][0].bottom = edit_rect[i][0].top + 53; + edit_rect[i][0].left = 510; + edit_rect[i][0].right = edit_rect[i][0].left + 53; + edit_rect[i][1].top = edit_rect[i][0].top + 7 + indent; + edit_rect[i][1].bottom = edit_rect[i][0].bottom - 11 - indent; + edit_rect[i][1].right = edit_rect[i][0].right - 8 +indent2; + edit_rect[i][1].left = edit_rect[i][0].left + 10 + indent2; + } + + //Initialize pc_race_rect + pc_race_rect.top = pc_info_rect.top; + pc_race_rect.bottom = name_rect.bottom; + pc_race_rect.left = name_rect.right; + pc_race_rect.right = pc_info_rect.left + (pc_info_rect.right - pc_info_rect.left)/2; + + //initialize info_area_rect + info_area_rect.top = pc_info_rect.top; + info_area_rect.left = pc_info_rect.left; + info_area_rect.right = pc_race_rect.right; + info_area_rect.bottom = pc_info_rect.bottom; + + // Initialize hp_sp_rect + hp_sp_rect.top = name_rect.bottom + 1; + hp_sp_rect.left = pc_info_rect.left + 1; + hp_sp_rect.right = pc_race_rect.right - 30; + hp_sp_rect.bottom = hp_sp_rect.top + 12; + for (i = 0; i < 6; i++) { + pc_area_buttons[i][3].left = hp_sp_rect.right - 32; + pc_area_buttons[i][3].right = pc_area_buttons[i][3].left + 77; + pc_area_buttons[i][3].top = hp_sp_rect.top + 1; + pc_area_buttons[i][3].bottom = hp_sp_rect.bottom + 1; + } + + // Initialize skill_rect + skill_rect.top = hp_sp_rect.bottom + 2; + skill_rect.left = pc_info_rect.left + 1; + skill_rect.right = pc_race_rect.right; + skill_rect.bottom = skill_rect.top + 12; + + //Initialize skills_rect + base_rect.top = skill_rect.bottom + 1; + base_rect.left = skill_rect.left + 1; + base_rect.right = name_rect.right - 1; + base_rect.bottom = base_rect.top + (pc_info_rect.bottom - skill_rect.bottom)/30; + + for (i = 0; i < 19; i++) { + pc_skills_rect[i] = base_rect; + OffsetRect(&pc_skills_rect[i], (i / 10) * ((name_rect.right)-(name_rect.left)), (i % 10) * (pc_info_rect.bottom - name_rect.bottom)/30); + } + + //Initialize status_rect + status_rect.top = pc_skills_rect[9].bottom + 5; + status_rect.left = pc_info_rect.left + 1; + status_rect.right = pc_race_rect.right; + status_rect.bottom = status_rect.top + 12; + //Initialize pc_status_rect + base_rect.top = status_rect.bottom + 1; + base_rect.left = status_rect.left + 1; + base_rect.right = name_rect.right - 1; + base_rect.bottom = base_rect.top + (pc_info_rect.bottom - status_rect.bottom)/15; + for (i = 0; i < 10; i++) { + pc_status_rect[i] = base_rect; + OffsetRect(&pc_status_rect[i], (i / 5) * ((name_rect.right)-(name_rect.left)), (i % 5) * (pc_info_rect.bottom - status_rect.bottom)/15); + } + //Initialize traits_rect + traits_rect.top = pc_status_rect[4].bottom + 5; + traits_rect.left = pc_info_rect.left + 1; + traits_rect.right = pc_race_rect.right; + traits_rect.bottom = traits_rect.top + 12; + //Initialize pc_traits_rect + base_rect.top = traits_rect.bottom - 1; + base_rect.left = traits_rect.left + 1; + base_rect.right = name_rect.right - 1; + base_rect.bottom = base_rect.top + 10; + for (i = 0; i < 16; i++) { + pc_traits_rect[i] = base_rect; + OffsetRect(&pc_traits_rect[i], (i / 7) * ((name_rect.right)-(name_rect.left)), (i % 7) * 10); + } + + + item_string_rects[0][0].top = pc_info_rect.top + 3; + item_string_rects[0][0].left = pc_info_rect.left + (pc_info_rect.right - pc_info_rect.left)/2; + item_string_rects[0][0].right = pc_info_rect.right; + item_string_rects[0][0].bottom = item_string_rects[0][0].top + 12; + for (i = 1; i < 24; i++) { + item_string_rects[i][0] = item_string_rects[0][0]; + OffsetRect(&item_string_rects[i][0],0,13 * i); + } + for (i = 0; i < 24; i++) { + item_string_rects[i][1] = item_string_rects[i][0]; + item_string_rects[i][1].right -= 14; + item_string_rects[i][1].left = item_string_rects[i][1].right - 14; + item_string_rects[i][2] = item_string_rects[i][0]; + item_string_rects[i][2].left = item_string_rects[i][2].right - 14; + } + for (i = 0; i < 24; i++) { + item_string_rects[i][0].left += 2; + item_string_rects[i][0].bottom++; + } + + name_rect.left -= 2; + pc_info_rect.left -= 2; + info_area_rect.left -= 2; + +} + +void Set_up_win () +{ + + + main_dc = GetDC(mainPtr); + + dlg_buttons_gworld = load_pict(2000,main_dc); + title_gworld = load_pict(5000,main_dc); + //SelectPalette(main_dc,hpal,0); + SelectObject(main_dc,font); + SetBkMode(main_dc,TRANSPARENT); + main_dc2 = CreateCompatibleDC(main_dc); + SetMapMode(main_dc2,GetMapMode((HDC) mainPtr)); + //SelectPalette(main_dc2,hpal,0); + main_dc3 = CreateCompatibleDC(main_dc); + SetMapMode(main_dc3,GetMapMode((HDC) mainPtr)); + //SelectPalette(main_dc3,hpal,0); + + mixed_gworld = load_pict(903,main_dc); + + pc_gworld = load_pict(902,main_dc); + dlogpics_gworld = load_pict(850,main_dc); + + buttons_gworld = load_pict(5001,main_dc); + pattern_gworld = CreateCompatibleBitmap(main_dc,192,256); + dialog_pattern_gworld = CreateCompatibleBitmap(main_dc,192,256); +} + +void lose_graphics() +{ + DeleteObject(title_gworld); + DeleteObject(pc_gworld); + DeleteObject(mixed_gworld); + DeleteObject(dlogpics_gworld); + DeleteObject(dlg_buttons_gworld); + DeleteObject(pattern_gworld); + DeleteObject(dialog_pattern_gworld); + //DeleteObject(hpal); + DeleteDC(main_dc); + DeleteDC(main_dc2); + DeleteDC(main_dc3); + DeleteObject(font); + DeleteObject(underline_font); + DeleteObject(italic_font); + DeleteObject(bold_font); + + DeleteObject(sword_curs); +} + +void redraw_screen() +{ + draw_main_screen(); + display_party(6,1); + draw_items(1); +} + +void draw_main_screen() +{ + RECT source_rect, dest_rec,dest_rect; + RECT reg_rect; + char temp_str[256]; + RECT top_pic_from = {3,16,41,54}; + + + paint_pattern(NULL,3,whole_win_rect,3); + + dest_rec = source_rect = title_from; + OffsetRect(&dest_rec,20,6); + + rect_draw_some_item (title_gworld,source_rect, title_gworld,dest_rec, 1,1); + dest_rec = top_pic_from; + OffsetRect(&dest_rec,20,6); + rect_draw_some_item (title_gworld,top_pic_from, title_gworld,dest_rec, 0,1); + + dest_rect = dest_rec; + dest_rect.top = dest_rect.bottom; + dest_rect.bottom = dest_rect.top + 50; + dest_rect.right += 40; + dest_rect.left -=5; + SelectObject(main_dc,bold_font); + char_win_draw_string(main_dc,dest_rect,"Your party:",0,10); + + dest_rec = whole_win_rect; + InflateRect(&dest_rec,-10,-10); + + if ((ulx >= 5) && (uly >= 5) && + (whole_win_rect.right - 30 > frame_rect.right)) + frame_dlog_rect(mainPtr,frame_rect,0); + + frame_dlog_rect(mainPtr,pc_info_rect,0); // draw the frame + + dest_rect = pc_area_buttons[5][0]; + dest_rect.right = whole_win_rect.right - 30; //What is this for? Commenting it out has no effect. + dest_rect.left += 60; + OffsetRect(&dest_rect,0,21); + if (file_in_mem == TRUE) + char_win_draw_string(main_dc,dest_rect,"Click on character to edit it.",0,10); + else char_win_draw_string(main_dc,dest_rect,"Select Open from File menu.",0,10); + OffsetRect(&dest_rect,0,12); + if (file_in_mem == TRUE) + char_win_draw_string(main_dc,dest_rect,"Press 'I' button to identify item, and 'D' button to drop item.",0,10); + OffsetRect(&dest_rect,0,16); + if (file_in_mem == TRUE) + char_win_draw_string(main_dc,dest_rect,"Back up save file before editing it!",0,10); + OffsetRect(&dest_rect,275,0); + char_win_draw_string(main_dc,dest_rect,"Released under the GNU GPL, Version 2",0,10); + + reg_rect.right = pc_info_rect.right + 100; + reg_rect.left = reg_rect.right - 170; + reg_rect.top = pc_info_rect.top - 70; + reg_rect.bottom = pc_info_rect.top; + +} + +void do_button_action(short,short which_button) +{ + long dummy; + + current_pressed_button = which_button; + display_party(6,0); + play_sound(34); + Delay(10,&dummy); + current_pressed_button = -1; + display_party(6,0); +} + + +//extern Rect pc_area_buttons[6][6] ; // 0 - whole 1 - pic 2 - name 3 - stat strs 4,5 - later +//extern Rect item_string_rects[24][4]; // 0 - name 1 - drop 2 - id 3 - +void draw_items(short clear_first) +//short clear_first; // 0 - redraw over, 1 - don't redraw over +{ + short i; + char to_draw[256]; + RECT d_from = {28,12,42,24},i_from = {42,12,56,24},dest_rect; + + if (file_in_mem == FALSE) + return; + + dest_rect = item_string_rects[0][0]; + dest_rect.bottom += 3; + OffsetRect(&dest_rect,0,-14); + + if (clear_first == 1) { + for (i = 0; i < 24; i++) + paint_pattern(NULL,1,item_string_rects[i][0],3); + paint_pattern(NULL,1,dest_rect,3); + } + + // frame_dlog_rect(mainPtr,frame_rect,0); + if (adven[current_active_pc].main_status != 1){ + frame_dlog_rect(mainPtr,pc_info_rect,0); // re draw entire frame + frame_dlog_rect(mainPtr,info_area_rect,0); // draw the frame + frame_dlog_rect(mainPtr,pc_race_rect,0); // draw the frame + return; // If PC is dead, it has no items + } + for (i = 0; i < 24; i++) // Loop through items and draw each + if (adven[current_active_pc].items[i].variety > 0) { // i.e. does item exist + sprintf((char *) to_draw, ""); + if (adven[current_active_pc].items[i].item_properties % 2 == 0) + sprintf((char *) to_draw, "%d. %s ",i + 1,adven[current_active_pc].items[i].name); + else if (adven[current_active_pc].items[i].charges > 0) + sprintf((char *) to_draw, "%d. %s (%d)",i + 1,adven[current_active_pc].items[i].full_name, + adven[current_active_pc].items[i].charges); + else sprintf((char *) to_draw, "%d. %s ",i + 1,adven[current_active_pc].items[i].full_name); + + char_win_draw_string(main_dc,item_string_rects[i][0],(char *) to_draw,0,10); + + //Draw id/drop buttons + rect_draw_some_item(mixed_gworld,d_from,mixed_gworld,item_string_rects[i][1],1,1); + rect_draw_some_item(mixed_gworld,i_from,mixed_gworld,item_string_rects[i][2],1,1); + } + frame_dlog_rect(mainPtr,pc_info_rect,0); // re draw entire frame + frame_dlog_rect(mainPtr,name_rect,0); // draw the frame + frame_dlog_rect(mainPtr,pc_race_rect,0); // draw the frame + frame_dlog_rect(mainPtr,info_area_rect,0); // draw the frame + +} + +void display_party(short,short clear_first) +//short mode; // 0 - 5 this pc, 6 - all +//short clear_first; // 0 - redraw over, 1 - don't redraw over +{ + short i; + char to_draw[256],skill_value[256]; + + RECT from_base = {0,0,28,36},from_rect; + COLORREF colors[4] = {RGB(0,0,0),RGB(255,0,0),RGB(0,0,102),RGB(255,255,255)}; + //UINT c[4]; + + + short k,string_num, cur_rect=0; + RECT no_party_rect,temp_rect; + + /*c[0] = GetNearestPaletteIndex(hpal,colors[0]); + c[1] = GetNearestPaletteIndex(hpal,colors[1]); + c[2] = GetNearestPaletteIndex(hpal,colors[2]); + c[3] = GetNearestPaletteIndex(hpal,colors[3]);*/ + if (clear_first == 1) { // first erase what's already there + for (i = 0; i < 6; i++) + paint_pattern(NULL,1,pc_area_buttons[i][0],3); + paint_pattern(NULL,1,name_rect,3); + paint_pattern(NULL,1,pc_race_rect,3); + paint_pattern(NULL,1,info_area_rect,3); + frame_dlog_rect(mainPtr,pc_info_rect,0); // re-draw the frame + } + + + SelectObject(main_dc,bold_font); + if (file_in_mem == FALSE) { + no_party_rect=pc_info_rect; + no_party_rect.top+=5; + no_party_rect.left+=5; + char_win_draw_string(main_dc,no_party_rect,"No party loaded.",0,10); + } + else { + + from_rect = title_from; //draw gold, food and day variables + from_rect.top = from_rect.bottom-10; + from_rect.left += 50; + char GFD[256]; + sprintf(GFD,"Food: %d Gold: %d Day: %d",party.food,party.gold,(party.age/3700)+1); + char_win_draw_string(main_dc,from_rect,GFD,0,10); + + from_rect = pc_info_rect; + from_rect.top = from_rect.bottom - 14; + from_rect.left += 3; + if (party_in_scen == FALSE) + char_win_draw_string(main_dc,from_rect,"Party not in a scenario.",0,10); + else { + char buf[256]; + sprintf(buf,"Party is in : %s.",party.scen_name); + char_win_draw_string(main_dc,from_rect,buf,0,10); + } + + for (i = 0; i < 6; i++) { + if (i == current_active_pc) + SetTextColor(main_dc,colors[1]); + else SetTextColor(main_dc,colors[0]); + + from_rect = (current_pressed_button == i) ? ed_buttons_from[1] : ed_buttons_from[0]; + + if ((current_pressed_button < 0) || (current_pressed_button == i)) + rect_draw_some_item(buttons_gworld,from_rect,buttons_gworld,pc_area_buttons[i][0],0,1); + SetTextColor(main_dc,colors[0]); + + // pc_record_type adven[6] is the records that contains characters + // main_status determins 0 - not exist, 1 - alive, OK, 2 - dead, 3 - stoned, 4 - dust + if (adven[i].main_status != 0) { // PC exists? + from_rect = from_base; + // draw PC graphic + OffsetRect(&from_rect,56 * (adven[i].which_graphic / 8),36 * (adven[i].which_graphic % 8)); + rect_draw_some_item(pc_gworld,from_rect,pc_gworld,pc_area_buttons[i][1],0,1); + frame_dlog_rect(mainPtr,pc_area_buttons[i][1],0); // re-draw the frame + + //frame_dlog_rect((GrafPtr) mainPtr,pc_area_buttons[i][1],0); + // draw name + //TextSize(9); + if( (strlen(adven[i].name)) >= 0) { + //TextFace(0); + SelectObject(main_dc,font); + sprintf((char *) to_draw, "%-s", (char *) adven[i].name); + //TextSize(6); + } + else { + sprintf((char *) to_draw, "%-s", (char *) adven[i].name); + } + + if (i == current_active_pc) + SetTextColor(main_dc,colors[1]); + else SetTextColor(main_dc,colors[3]); + win_draw_string(main_dc,pc_area_buttons[i][2],to_draw,1,10); + SelectObject(main_dc,bold_font); + + + if (i == current_active_pc){ + sprintf((char *) to_draw, "%-.18s ", (char *) adven[i].name); + if( (strlen(adven[i].name)) > 12) + SelectObject(main_dc,font); + SetTextColor(main_dc,colors[0]); + win_draw_string(main_dc,name_rect,to_draw,1,10); + SelectObject(main_dc,bold_font); + } + if ((current_pressed_button < 0) || (current_pressed_button == i)) + switch (adven[i].main_status) { + // draw statistics + case 1: + if (i == current_active_pc) { + //Draw in race + if (adven[i].race == 0) + char_win_draw_string(main_dc,pc_race_rect,"Human ",1,10); + if (adven[i].race == 1) + char_win_draw_string(main_dc,pc_race_rect,"Nephilim ",1,10); + if (adven[i].race == 2) + char_win_draw_string(main_dc,pc_race_rect,"Slithzerikai ",1,10); + // Draw in skills + + sprintf((char *) to_draw, "Skills:"); + win_draw_string(main_dc,skill_rect,to_draw,0,10); + sprintf((char *) to_draw, "Hp: %d/%d Sp: %d/%d",adven[i].cur_health,adven[i].max_health,adven[i].cur_sp, + adven[i].max_sp); + win_draw_string(main_dc,hp_sp_rect,to_draw,0,10); + + + SelectObject(main_dc,font); + string_num=1; + for( k = 0; k < 19 ; ++k) + { + temp_rect = pc_skills_rect[k]; + temp_rect.left = pc_skills_rect[k].left + ((k < 10) ? 90 : 83); + + get_str(to_draw,9,string_num); + win_draw_string(main_dc,pc_skills_rect[k],to_draw,0,9); + + sprintf((char *) skill_value,"%d",adven[i].skills[k]); + OffsetRect(&temp_rect,-8,0); + temp_rect.right += 10; + win_draw_string(main_dc,temp_rect,skill_value,0,9); + //frame_dlog_rect((GrafPtr) mainPtr,pc_skills_rect[k],0); + string_num+=2; + } + //end skills + + //Write in pc Status + SelectObject(main_dc,bold_font); + sprintf((char *) to_draw, "Status:"); + win_draw_string(main_dc,status_rect,to_draw,0,10); + + SelectObject(main_dc,font); + //for(k = 0 ; k < 10; k++) + //frame_dlog_rect((GrafPtr) mainPtr,pc_status_rect[k],0); + if (adven[i].status[0] > 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Poisoned Weap.",0,9); + cur_rect++; + } + if (adven[i].status[1] > 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Blessed",0,9); + cur_rect++; + } + else if(adven[i].status[1] < 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Cursed",0,9); + cur_rect++; + } + if (adven[i].status[2] > 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Poisoned",0,9); + cur_rect++; + } + if (adven[i].status[3] > 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Hasted",0,9); + cur_rect++; + } + else if(adven[i].status[3] < 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Slowed",0,9); + cur_rect++; + } + if (adven[i].status[4] > 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Invulnerable",0,9); + cur_rect++; + } + if (adven[i].status[5] > 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Magic Resistant",0,9); + cur_rect++; + } + if (adven[i].status[6] > 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Webbed",0,9); + cur_rect++; + } + if (adven[i].status[7] > 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Diseased",0,9); + cur_rect++; + } + if (adven[i].status[8] > 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Sanctury",0,9); + cur_rect++; + } + if (adven[i].status[9] > 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Dumbfounded",0,9); + cur_rect++; + } + if (adven[i].status[10] > 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Martyr's Shield",0,9); + cur_rect++; + } + if (adven[i].status[11] > 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Asleep",0,9); + cur_rect++; + } + if (adven[i].status[12] > 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Paralyzed",0,9); + cur_rect++; + } + if (adven[i].status[13] > 0) + if(cur_rect <= 9) { + char_win_draw_string(main_dc,pc_status_rect[cur_rect],"Acid",0,9); + cur_rect++; + } + //end pc status section + + //Write in Traits + SelectObject(main_dc,bold_font); + sprintf((char *) to_draw, "Traits:"); + win_draw_string(main_dc,traits_rect,to_draw,0,10); + SelectObject(main_dc,font); + cur_rect=0; + if (adven[i].traits[0] == 1) + if(cur_rect <= 15) { + char_win_draw_string(main_dc,pc_traits_rect[cur_rect],"Toughness",0,9); + cur_rect++; + } + if (adven[i].traits[1] == 1) + if(cur_rect <= 15) { + char_win_draw_string(main_dc,pc_traits_rect[cur_rect],"Magically Apt",0,9); + cur_rect++; + } + if (adven[i].traits[2] == 1) + if(cur_rect <= 15) { + char_win_draw_string(main_dc,pc_traits_rect[cur_rect],"Ambidextrous",0,9); + cur_rect++; + } + if (adven[i].traits[3] == 1) + if(cur_rect <= 15) { + char_win_draw_string(main_dc,pc_traits_rect[cur_rect],"Nimble Fingers",0,9); + cur_rect++; + } + if (adven[i].traits[4] == 1) + if(cur_rect <= 15) { + char_win_draw_string(main_dc,pc_traits_rect[cur_rect],"Cave Lore",0,9); + cur_rect++; + } + + if (adven[i].traits[5] == 1) + if(cur_rect <= 15) { + char_win_draw_string(main_dc,pc_traits_rect[cur_rect],"Woodsman",0,9); + cur_rect++; + } + if (adven[i].traits[6] == 1) + if(cur_rect <= 15) { + char_win_draw_string(main_dc,pc_traits_rect[cur_rect],"Good Constitution",0,9); + cur_rect++; + } + if (adven[i].traits[7] == 1) + if(cur_rect <= 15) { + char_win_draw_string(main_dc,pc_traits_rect[cur_rect],"Highly Alert",0,9); + cur_rect++; + } + if (adven[i].traits[8] == 1) + if(cur_rect <= 15) { + char_win_draw_string(main_dc,pc_traits_rect[cur_rect],"Exceptional Str.",0,9); + cur_rect++; + } + if (adven[i].traits[9] == 1) + if(cur_rect <= 15) { + char_win_draw_string(main_dc,pc_traits_rect[cur_rect],"Recuperation",0,9); + cur_rect++; + } + if (adven[i].traits[10] == 1) + if(cur_rect <= 15) { + char_win_draw_string(main_dc,pc_traits_rect[cur_rect],"Sluggish",0,9); + cur_rect++; + } + if (adven[i].traits[11] == 1) + if(cur_rect <= 15) { + char_win_draw_string(main_dc,pc_traits_rect[cur_rect],"Magically Inept",0,9); + cur_rect++; + } + if (adven[i].traits[12] == 1) + if(cur_rect <= 14) { + char_win_draw_string(main_dc,pc_traits_rect[cur_rect],"Frail",0,9); + cur_rect++; + } + if (adven[i].traits[13] == 1) + if(cur_rect <= 14) { + char_win_draw_string(main_dc,pc_traits_rect[cur_rect],"Chronic Disease",0,9); + cur_rect++; + } + if (adven[i].traits[14] == 1) + if(cur_rect <= 13) { + char_win_draw_string(main_dc,pc_traits_rect[cur_rect],"Bad Back",0,9); + cur_rect++; + } + + //end traits + + + SetTextColor(main_dc,colors[0]); + SelectObject(main_dc,bold_font); + char_win_draw_string(main_dc,pc_area_buttons[i][3],"Alive ",1,10); + SelectObject(main_dc,bold_font); + } + break; + case 2: + if (i == current_active_pc){ + SetTextColor(main_dc,colors[0]); + SelectObject(main_dc,bold_font); + char_win_draw_string(main_dc,pc_area_buttons[i][3],"Dead ",1,10); + SelectObject(main_dc,bold_font); + break; + } + case 3: + if (i == current_active_pc){ + SetTextColor(main_dc,colors[0]); + SelectObject(main_dc,bold_font); + char_win_draw_string(main_dc,pc_area_buttons[i][3],"Dust ",1,10); + SelectObject(main_dc,bold_font); + break; + } + case 4: + if (i == current_active_pc){ + SetTextColor(main_dc,colors[0]); + SelectObject(main_dc,bold_font); + char_win_draw_string(main_dc,pc_area_buttons[i][3],"Stone ",1,10); + SelectObject(main_dc,bold_font); + break; + } + case 5: + if (i == current_active_pc){ + SetTextColor(main_dc,colors[0]); + SelectObject(main_dc,bold_font); + char_win_draw_string(main_dc,pc_area_buttons[i][3],"Fled ",1,10); + SelectObject(main_dc,bold_font); + break; + } + case 6: + if (i == current_active_pc){ + SetTextColor(main_dc,colors[0]); + SelectObject(main_dc,bold_font); + char_win_draw_string(main_dc,pc_area_buttons[i][3],"Surface ",1,10); + SelectObject(main_dc,bold_font); + break; + } + default: + if (i == current_active_pc){ + SetTextColor(main_dc,colors[0]); + SelectObject(main_dc,bold_font); + char_win_draw_string(main_dc,pc_area_buttons[i][3],"Absent ",1,10); + SelectObject(main_dc,bold_font); + break; + } + } + //frame_dlog_rect((GrafPtr) mainPtr,pc_area_buttons[i][0],0); + + + } + + } // Closes the for i=6 loop + SetTextColor(main_dc,colors[0]); + + for(i = 0; i < 5; i++) + if ((current_pressed_button < 0) || (current_pressed_button == i + 10)) { + if (clear_first == 1) { // first erase what's already there + paint_pattern(NULL,1,edit_rect[i][0],3); + } + + from_rect = (current_pressed_button == i + 10) ? ed_buttons_from[1] : ed_buttons_from[0]; + rect_draw_some_item(buttons_gworld,from_rect,buttons_gworld,edit_rect[i][0],0,1); + SetTextColor(main_dc,colors[3]); + switch(i) { + case 0: + char_win_draw_string(main_dc,edit_rect[0][1]," Add|Mage|Spells ",0,10); + break; + case 1: + char_win_draw_string(main_dc,edit_rect[1][1]," Add|Priest|Spells ",0,10); + break; + case 2: + char_win_draw_string(main_dc,edit_rect[2][1]," Edit|Traits",0,10); + break; + case 3: + char_win_draw_string(main_dc,edit_rect[3][1]," Edit|Skills",0,10); + break; + case 4: + char_win_draw_string(main_dc,edit_rect[4][1]," Edit| XP",0,10); + break; + default: + break; + } + SetTextColor(main_dc,colors[0]); + + } + + } +SetTextColor(main_dc,colors[0]); +} + +void display_strings_event_filter (short item_hit) +{ + + + + switch (item_hit) { + case 1: + dialog_not_toast = FALSE; + break; + } +} + +void display_strings(short str1a,short str1b,short str2a,short str2b, + char *title,short sound_num,short graphic_num,short parent_num) +{ + + + char sign_text[256]; + + + + make_cursor_sword(); + + store_str1a = str1a; + store_str1b = str1b; + store_str2a = str2a; + store_str2b = str2b; + + if ((str1a <= 0) || (str1b <= 0)) + return; + store_which_string_dlog = 970; + if (strlen(title) > 0) + store_which_string_dlog += 2; + if ((str2a > 0) && (str2b > 0)) + store_which_string_dlog++; + cd_create_dialog_parent_num(store_which_string_dlog,parent_num); + + cd_activate_item(store_which_string_dlog,2,0); + + csp(store_which_string_dlog,store_which_string_dlog,graphic_num); + + get_str(sign_text,str1a,str1b); + csit(store_which_string_dlog,4,(char *) sign_text); + if ((str2a > 0) && (str2b > 0)) { + get_str(sign_text,str2a,str2b); + csit(store_which_string_dlog,5,(char *) sign_text); + } + if (strlen(title) > 0) + csit(store_which_string_dlog,6,title); + csp(store_which_string_dlog,3,graphic_num); + if (sound_num >= 0) + play_sound(sound_num); + while (dialog_not_toast) + ModalDialog(); + + cd_kill_dialog(store_which_string_dlog,0); +} + +void get_str(char *str,short i, short j) +{ + GetIndString(str, i, j); +} + +void char_win_draw_string(HDC dest_window,RECT dest_rect,char *str,short mode,short line_height) +{ + char store_s[256]; + + strcpy((char *) store_s,str); + win_draw_string( dest_window, dest_rect,store_s, mode, line_height); + +} + +// mode: 0 - align up and left, 1 - center on one line +// str is a c string, 256 characters +// uses current font +void win_draw_string(HDC dest_hdc,RECT dest_rect,char *str,short mode,short) +{ + short i; + +// this will need formatting for '|' line breaks + for (i = 0; i < 256; i++) { + if (str[i] == '|') + str[i] = 13; + if (str[i] == '_') + str[i] = 34; + } + // if dest is main window, add ulx, uly + if (dest_hdc == main_dc) + OffsetRect(&dest_rect,ulx,uly); + switch (mode) { + case 0: + dest_rect.bottom += 6; + DrawText(dest_hdc,str,strlen((char *)str),&dest_rect,DT_LEFT | DT_WORDBREAK); break; + case 1: + dest_rect.bottom += 6; dest_rect.top -= 6; + DrawText(dest_hdc,str,strlen((char *)str),&dest_rect, + DT_CENTER | DT_VCENTER | DT_NOCLIP | DT_SINGLELINE); break; + case 2: case 3: + dest_rect.bottom += 6; dest_rect.top -= 6; + DrawText(dest_hdc,str,strlen((char *)str),&dest_rect, + DT_LEFT | DT_VCENTER | DT_NOCLIP | DT_SINGLELINE); break; + } + // not yet done adjusts for 1, 2, 3 + +} + +short string_length(char *str,HDC hdc) +{ + short text_len[257]; + short total_width = 0,i,len; + char p_str[256]; + + for (i = 0; i < 257; i++) + text_len[i]= 0; + + strcpy((char *) p_str,str); + MeasureText(256,p_str,text_len,hdc); + len = strlen((char *)str); + + for (i = 0; i < 257; i++) + if ((text_len[i] > total_width) && (i <= len)) + total_width = text_len[i]; + return total_width; +} + +// Note ... this expects a str len of at most 256 and +// len_array pointing to a 256 long array of shorts +void MeasureText(short str_len,char *str, short *len_array,HDC hdc) +{ + short text_len[257]; + short i; + char p_str[257]; + SIZE val_returned; + char *store_array; + short *store2; + + store_array = (char *) len_array; + for (i = 0; i < 256; i++) + text_len[i] = 0; + for (i = 1; i < str_len; i++) { + strncpy(p_str,str,i); + p_str[i] = 0; + GetTextExtentPoint32(hdc,p_str,i, &val_returned); + text_len[i] = val_returned.cx; + } + for (i = 0; i < 256; i++) { + store2 = (short *) store_array; + *store2 = text_len[i]; + store_array += 2; + } + } + + +void GetIndString(char *str,short i, short j) { + UINT resnum = 0,len; + short k; + + resnum = i * 300 + j; + + len = LoadString(store_hInstance,resnum,str,256); + if (len == 0) { + sprintf(str,""); + return; + } + for (k = 0; k < 256; k++) { + if (str[k] == '|') + str[k] = 13; + if (str[k] == '_') + str[k] = 34; + } +} + + +void make_cursor_sword() +{ + SetCursor(sword_curs); +} diff --git a/Blades of Exile Char Editor/GRAPHICS.H b/Blades of Exile Char Editor/GRAPHICS.H new file mode 100644 index 00000000..3c6712ed --- /dev/null +++ b/Blades of Exile Char Editor/GRAPHICS.H @@ -0,0 +1,25 @@ +void init_main_buttons(); +void Set_up_win (); +void redraw_screen(); +void draw_main_screen(); +void do_button_action(short which_pc,short which_button); +void draw_items(short clear_first); +void display_party(short mode,short clear_first); + + +void char_win_draw_string(HDC dest_window,RECT dest_rect,char *str,short mode,short line_height); +void win_draw_string(HDC dest_hdc,RECT dest_rect,char *str,short mode,short line_height); +void display_strings_event_filter (short item_hit); +void display_strings(short str1a,short str1b,short str2a,short str2b, + char *title,short sound_num,short graphic_num,short parent_num); +void c2p(char *str) ; +void p2c(char *str); +void get_str(char *,short i, short j); +short string_length(char *str,HDC hdc); +void make_cursor_sword(); + +void MeasureText(short str_len,char *str, short *len_array,HDC hdc); +void GetIndString(char *str,short i, short j) ; + +void lose_graphics(); + diff --git a/Blades of Exile Char Editor/GRAPHUTL.CPP b/Blades of Exile Char Editor/GRAPHUTL.CPP new file mode 100644 index 00000000..8ebe5d9a --- /dev/null +++ b/Blades of Exile Char Editor/GRAPHUTL.CPP @@ -0,0 +1,334 @@ +#define xmin(a,b) ((a) < (b) ? (a) : (b)) + +#include +#include +#include +#include +#include +#include +#include "global.h" + + +#include "edsound.h" + +#include "graphutl.h" + +extern HWND mainPtr; +//extern HPALETTE hpal; +extern HDC main_dc,main_dc2,main_dc3; +extern short ulx,uly; +extern HBITMAP mixed_gworld,dialog_pattern_gworld,pattern_gworld,status_pattern_gworld; +extern char file_path_name[256]; + + int elements[5] = {COLOR_ACTIVEBORDER,COLOR_ACTIVECAPTION, + COLOR_WINDOWFRAME,COLOR_SCROLLBAR,COLOR_BTNFACE}; + COLORREF store_element_colors[5]; +short dlog_pat_placed = 0; +short current_pattern = -1; + +HBITMAP load_pict(short pict_num,HDC model_hdc) +{ + HBITMAP got_bitmap; + + switch(pict_num) { + case 700: case 701: case 702: got_bitmap = ReadBMP("images/STATAREA.BMP"); break; + case 703: got_bitmap = ReadBMP("images/TEXTBAR.BMP"); break; + case 704: got_bitmap = ReadBMP("images/BUTTONS.BMP"); break; + case 705: got_bitmap = ReadBMP("images/TERSCRN.BMP"); break; + case 800: got_bitmap = ReadBMP("images/TER1.BMP"); break; + case 801: got_bitmap = ReadBMP("images/TER2.BMP"); break; + case 802: got_bitmap = ReadBMP("images/TER3.BMP"); break; + case 803: got_bitmap = ReadBMP("images/TER4.BMP"); break; + case 804: got_bitmap = ReadBMP("images/TER5.BMP"); break; + case 805: got_bitmap = ReadBMP("images/TER6.BMP"); break; + case 820: got_bitmap = ReadBMP("images/TERANIM.BMP"); break; + case 821: got_bitmap = ReadBMP("images/FIELDS.BMP"); break; + case 830: got_bitmap = ReadBMP("images/STARTUP.BMP"); break; + case 850: got_bitmap = ReadBMP("images/DLOGPICS.BMP"); break; + case 860: got_bitmap = ReadBMP("images/TALKPORT.BMP"); break; + case 875: got_bitmap = ReadBMP("images/DLOGMAPS.BMP"); break; + case 880: got_bitmap = ReadBMP("images/MISSILES.BMP"); break; + case 900: got_bitmap = ReadBMP("images/TINYOBJ.BMP"); break; + case 901: got_bitmap = ReadBMP("images/OBJECTS.BMP"); break; + case 902: got_bitmap = ReadBMP("images/PCS.BMP"); break; + case 905: got_bitmap = ReadBMP("images/PCS.BMP"); break; + case 903: case 904: got_bitmap = ReadBMP("images/MIXED.BMP"); break; + case 1100: case 1200: got_bitmap = ReadBMP("images/MONST1.BMP"); break; + case 1101: case 1201: got_bitmap = ReadBMP("images/MONST2.BMP"); break; + case 1102: case 1202: got_bitmap = ReadBMP("images/MONST3.BMP"); break; + case 1103: case 1203: got_bitmap = ReadBMP("images/MONST4.BMP"); break; + case 1104: case 1204: got_bitmap = ReadBMP("images/MONST5.BMP"); break; + case 1105: case 1205: got_bitmap = ReadBMP("images/MONST6.BMP"); break; + case 1106: case 1206: got_bitmap = ReadBMP("images/MONST7.BMP"); break; + case 1107: case 1207: got_bitmap = ReadBMP("images/MONST8.BMP"); break; + case 1108: case 1208: got_bitmap = ReadBMP("images/MONST9.BMP"); break; + case 1109: case 1209: got_bitmap = ReadBMP("images/MONST10.BMP"); break; + case 1400: got_bitmap = ReadBMP("images/STSCICON.BMP"); break; + case 1401: got_bitmap = ReadBMP("images/HELPPICS.BMP"); break; + case 1402: got_bitmap = ReadBMP("images/APPIC.BMP"); break; + case 1500: case 1501: case 1502: case 1503: case 1504: case 1505: case 1506: case 1507: + got_bitmap = ReadBMP("images/BIGMAPS.BMP"); break; + case 2000: got_bitmap = ReadBMP("images/DLOGBTNS.BMP"); break; + case 3000: got_bitmap = ReadBMP("images/START.BMP"); break; + case 3001: got_bitmap = ReadBMP("images/SPIDLOGO.BMP"); break; + case 5000: got_bitmap = ReadBMP("images/BLEDTITL.BMP"); break; + case 5001: got_bitmap = ReadBMP("images/PCEDBTNS.BMP"); break; + + default: got_bitmap = NULL; + } + return got_bitmap; +} + +void rect_draw_some_item(HBITMAP src,RECT src_rect,HBITMAP dest,RECT dest_rect, + short trans, short main_win) { + HDC hdcMem,hdcMem2,hdcMem3,destDC; + HBITMAP transbmp; + COLORREF white = RGB(255,255,255),oldcolor; + + HBRUSH hbrush,old_brush; + COLORREF x = RGB(17,17,17); + UINT c; + HBITMAP store,store2; + Boolean dlog_draw = FALSE; + + if (main_win == 2) { + destDC = (HDC) dest; + main_win = 1; + dlog_draw = TRUE; + hdcMem = CreateCompatibleDC(destDC); + SelectObject(hdcMem, src); + SetMapMode(hdcMem,GetMapMode((HDC) mainPtr)); + //SelectPalette(hdcMem,hpal,0); + } + else { + destDC = main_dc; + hdcMem = main_dc2; + store = (HBITMAP) SelectObject(hdcMem,src); + } + + if (trans != 1) { + if (main_win == 0) { // Not transparent, into bitmap + hdcMem2 = main_dc3; + store2 = (HBITMAP) SelectObject(hdcMem2, dest); + StretchBlt(hdcMem2,dest_rect.left,dest_rect.top,dest_rect.right - dest_rect.left, + dest_rect.bottom - dest_rect.top, + hdcMem,src_rect.left,src_rect.top,src_rect.right - src_rect.left, + src_rect.bottom - src_rect.top,(trans >= 0) ? SRCCOPY : SRCAND); + SelectObject(hdcMem2,store2); + } + + else { // Not transparent, onto screen + if (trans == 2) { + //c = GetNearestPaletteIndex(hpal,x); + hbrush = CreateSolidBrush(PALETTEINDEX(c)); + old_brush = (HBRUSH) SelectObject(destDC,hbrush); + + } + if (dlog_draw == FALSE) + SetViewportOrgEx(destDC,ulx,uly, NULL); + + StretchBlt(destDC,dest_rect.left,dest_rect.top,dest_rect.right - dest_rect.left, + dest_rect.bottom - dest_rect.top, + hdcMem,src_rect.left,src_rect.top,src_rect.right - src_rect.left, + src_rect.bottom - src_rect.top,(trans == 0) ? SRCCOPY : PATCOPY); + if (trans == 2) { + SelectObject(destDC,old_brush); + if (DeleteObject(hbrush) == 0) + play_sound(1); + } + if (dlog_draw == FALSE) + SetViewportOrgEx(destDC,0,0,NULL); + + + } + } // end of non-transparent draws + else { + if (main_win == 0) { + hdcMem3 = CreateCompatibleDC(hdcMem); + SelectObject(hdcMem3, dest); + SetMapMode(hdcMem3,GetMapMode((HDC) mainPtr)); + //SelectPalette(hdcMem3,hpal,0); + transbmp = CreateBitmap(src_rect.right - src_rect.left, + src_rect.bottom - src_rect.top,1,1,NULL); + hdcMem2 = CreateCompatibleDC(destDC); + SelectObject(hdcMem2, transbmp); + oldcolor = SetBkColor(hdcMem, white); + StretchBlt(hdcMem2,0,0,dest_rect.right - dest_rect.left, + dest_rect.bottom - dest_rect.top, + hdcMem,src_rect.left,src_rect.top,src_rect.right - src_rect.left, + src_rect.bottom - src_rect.top,SRCCOPY); + SetBkColor(hdcMem, oldcolor); + + StretchBlt(hdcMem3,dest_rect.left,dest_rect.top,dest_rect.right - dest_rect.left, + dest_rect.bottom - dest_rect.top, + hdcMem,src_rect.left,src_rect.top,src_rect.right - src_rect.left, + src_rect.bottom - src_rect.top,SRCINVERT); + StretchBlt(hdcMem3,dest_rect.left,dest_rect.top,dest_rect.right - dest_rect.left, + dest_rect.bottom - dest_rect.top, + hdcMem2,0,0,src_rect.right - src_rect.left, + src_rect.bottom - src_rect.top,SRCAND); + StretchBlt(hdcMem3,dest_rect.left,dest_rect.top,dest_rect.right - dest_rect.left, + dest_rect.bottom - dest_rect.top, + hdcMem,src_rect.left,src_rect.top,src_rect.right - src_rect.left, + src_rect.bottom - src_rect.top,SRCINVERT); + DeleteDC(hdcMem3); + DeleteDC(hdcMem2); + + DeleteObject(transbmp); + } + else { + if (dlog_draw == FALSE) + SetViewportOrgEx(destDC,ulx,uly,NULL); + transbmp = CreateBitmap(src_rect.right - src_rect.left, + src_rect.bottom - src_rect.top,1,1,NULL); + hdcMem2 = CreateCompatibleDC(destDC); + SelectObject(hdcMem2, transbmp); + oldcolor = SetBkColor(hdcMem, white); + StretchBlt(hdcMem2,0,0,dest_rect.right - dest_rect.left, + dest_rect.bottom - dest_rect.top, + hdcMem,src_rect.left,src_rect.top,src_rect.right - src_rect.left, + src_rect.bottom - src_rect.top,SRCCOPY); + + SetBkColor(hdcMem, oldcolor); + + StretchBlt(destDC,dest_rect.left,dest_rect.top,dest_rect.right - dest_rect.left, + dest_rect.bottom - dest_rect.top, + hdcMem,src_rect.left,src_rect.top,src_rect.right - src_rect.left, + src_rect.bottom - src_rect.top,SRCINVERT); + StretchBlt(destDC,dest_rect.left,dest_rect.top,dest_rect.right - dest_rect.left, + dest_rect.bottom - dest_rect.top, + hdcMem2,0,0,src_rect.right - src_rect.left, + src_rect.bottom - src_rect.top,SRCAND); + StretchBlt(destDC,dest_rect.left,dest_rect.top,dest_rect.right - dest_rect.left, + dest_rect.bottom - dest_rect.top, + hdcMem,src_rect.left,src_rect.top,src_rect.right - src_rect.left, + src_rect.bottom - src_rect.top,SRCINVERT); + if (dlog_draw == FALSE) + SetViewportOrgEx(destDC,0,0,NULL); + DeleteDC(hdcMem2); + + DeleteObject(transbmp); + + + } + } + if (dlog_draw == TRUE) + DeleteDC(hdcMem); + else SelectObject(hdcMem,store); +} + + void fry_dc(HWND hwnd,HDC dc) + { + if (ReleaseDC(hwnd,dc) == 0) + PostQuitMessage(0); + } + +void DisposeGWorld(HBITMAP bitmap) +{ + DeleteObject(bitmap); +} + +void SectRect(RECT *a, RECT *b, RECT *c) + { + IntersectRect(c,a,b); + } + +Boolean Button() +{ + MSG msg; + + if (PeekMessage(&msg,mainPtr,WM_MOUSEFIRST,WM_MOUSELAST,PM_REMOVE) > 0) + if ((msg.message == WM_LBUTTONDOWN) || (msg.message == WM_CHAR) + || (msg.message == WM_KEYDOWN)) + return TRUE; + if (PeekMessage(&msg,mainPtr,WM_KEYFIRST,WM_KEYLAST,PM_REMOVE) > 0) + if ((msg.message == WM_LBUTTONDOWN) || (msg.message == WM_CHAR) + || (msg.message == WM_KEYDOWN)) + return TRUE; + return FALSE; +} + + +// which_mode is 0 ... dest is a bitmap +// is 1 ... ignore dest ... paint on mainPtr +// is 2 ... dest is a dialog, use the dialog pattern +// both pattern gworlds are 192 x 256 +void paint_pattern(HBITMAP dest,short which_mode,RECT dest_rect,short which_pattern) +{ + HBITMAP source_pat; + RECT pattern_source = {32,168,96,232}, pat_dest_orig = {0,0,64,64},pat_dest; + short i,j; + + RECT draw_from_orig = {0,0,192,256},draw_from,draw_to; + short store_ulx,store_uly; + + if (which_mode == 1) + OffsetRect(&dest_rect,ulx, uly); + else if (which_mode == 3) + which_mode = 1; + if (which_mode == 2) { + source_pat = dialog_pattern_gworld; + if (dlog_pat_placed == 0) { + dlog_pat_placed = 1; + OffsetRect(&pattern_source, 64 * 2,0); + for (i = 0; i < 3; i++) + for (j = 0; j < 4; j++) { + pat_dest = pat_dest_orig; + OffsetRect(&pat_dest,64 * i, 64 * j); + rect_draw_some_item(mixed_gworld,pattern_source, + dialog_pattern_gworld,pat_dest,0,0); + } + } + } + else { + source_pat = pattern_gworld; + if (current_pattern != which_pattern) { + current_pattern = which_pattern; + OffsetRect(&pattern_source, 64 * (which_pattern % 5), + 64 * (which_pattern / 5)); + for (i = 0; i < 3; i++) + for (j = 0; j < 4; j++) { + pat_dest = pat_dest_orig; + OffsetRect(&pat_dest,64 * i, 64 * j); + rect_draw_some_item(mixed_gworld,pattern_source, + pattern_gworld,pat_dest,0,0); + } + } + } + + // now patterns are loaded, so have fun + // first nullify ul shifting + store_ulx = ulx; + store_uly = uly; + ulx = uly = 0; + for (i = 0; i < (dest_rect.right / 192) + 1; i++) + for (j = 0; j < (dest_rect.bottom / 256) + 1; j++) { + draw_to = draw_from_orig; + OffsetRect(&draw_to,192 * i, 256 * j); + IntersectRect(&draw_to,&draw_to,&dest_rect); + if (draw_to.right != 0) { + draw_from = draw_to; + OffsetRect(&draw_from, -192 * i, -256 * j); + switch (which_mode) { + case 0: + rect_draw_some_item(source_pat,draw_from, + dest,draw_to,0,0); break; + case 1: + rect_draw_some_item(source_pat,draw_from, + source_pat,draw_to,0,1); break; + case 2: + rect_draw_some_item(source_pat,draw_from, + dest,draw_to,0,2); break; + } + } + } + ulx = store_ulx; + uly = store_uly; +} + +/* GK */ + +HBITMAP ReadBMP(char * fileName) +{ + return (HBITMAP) LoadImage(0, fileName, IMAGE_BITMAP, 0, 0, LR_LOADFROMFILE); +} diff --git a/Blades of Exile Char Editor/GRAPHUTL.H b/Blades of Exile Char Editor/GRAPHUTL.H new file mode 100644 index 00000000..7222672c --- /dev/null +++ b/Blades of Exile Char Editor/GRAPHUTL.H @@ -0,0 +1,16 @@ +#ifndef _GRAPHUTL_H + #define _GRAPHUTL_H + +HBITMAP load_pict(short pict_num,HDC model_hdc); +void rect_draw_some_item(HBITMAP src,RECT src_rect,HBITMAP dest,RECT dest_rect, + short trans, short main_win) ; + void fry_dc(HWND hwnd,HDC dc) ; + void DisposeGWorld(HBITMAP bitmap); +void SectRect(RECT *a, RECT *b, RECT *c); +Boolean Button(); +void paint_pattern(HBITMAP dest,short which_mode,RECT dest_rect,short which_pattern); + +/* GK */ +HBITMAP ReadBMP(char * fileName); + +#endif diff --git a/Blades of Exile Char Editor/Resources/BLADEXIL.ICO b/Blades of Exile Char Editor/Resources/BLADEXIL.ICO new file mode 100644 index 00000000..6cfced9b Binary files /dev/null and b/Blades of Exile Char Editor/Resources/BLADEXIL.ICO differ diff --git a/Blades of Exile Char Editor/Resources/BOOT.CUR b/Blades of Exile Char Editor/Resources/BOOT.CUR new file mode 100644 index 00000000..0bb41768 Binary files /dev/null and b/Blades of Exile Char Editor/Resources/BOOT.CUR differ diff --git a/Blades of Exile Char Editor/Resources/C.CUR b/Blades of Exile Char Editor/Resources/C.CUR new file mode 100644 index 00000000..bcc4fefc Binary files /dev/null and b/Blades of Exile Char Editor/Resources/C.CUR differ diff --git a/Blades of Exile Char Editor/Resources/D.CUR b/Blades of Exile Char Editor/Resources/D.CUR new file mode 100644 index 00000000..68617d3e Binary files /dev/null and b/Blades of Exile Char Editor/Resources/D.CUR differ diff --git a/Blades of Exile Char Editor/Resources/DL.CUR b/Blades of Exile Char Editor/Resources/DL.CUR new file mode 100644 index 00000000..c4861293 Binary files /dev/null and b/Blades of Exile Char Editor/Resources/DL.CUR differ diff --git a/Blades of Exile Char Editor/Resources/DR.CUR b/Blades of Exile Char Editor/Resources/DR.CUR new file mode 100644 index 00000000..7c1ae737 Binary files /dev/null and b/Blades of Exile Char Editor/Resources/DR.CUR differ diff --git a/Blades of Exile Char Editor/Resources/KEY.CUR b/Blades of Exile Char Editor/Resources/KEY.CUR new file mode 100644 index 00000000..3cdf2d4a Binary files /dev/null and b/Blades of Exile Char Editor/Resources/KEY.CUR differ diff --git a/Blades of Exile Char Editor/Resources/L.CUR b/Blades of Exile Char Editor/Resources/L.CUR new file mode 100644 index 00000000..be7af994 Binary files /dev/null and b/Blades of Exile Char Editor/Resources/L.CUR differ diff --git a/Blades of Exile Char Editor/Resources/LOOK.CUR b/Blades of Exile Char Editor/Resources/LOOK.CUR new file mode 100644 index 00000000..ca1ad8e5 Binary files /dev/null and b/Blades of Exile Char Editor/Resources/LOOK.CUR differ diff --git a/Blades of Exile Char Editor/Resources/R.CUR b/Blades of Exile Char Editor/Resources/R.CUR new file mode 100644 index 00000000..39f194ec Binary files /dev/null and b/Blades of Exile Char Editor/Resources/R.CUR differ diff --git a/Blades of Exile Char Editor/Resources/SND0.WAV b/Blades of Exile Char Editor/Resources/SND0.WAV new file mode 100644 index 00000000..793c0297 Binary files /dev/null and b/Blades of Exile Char Editor/Resources/SND0.WAV differ diff --git a/Blades of Exile Char Editor/Resources/SND1.WAV b/Blades of Exile Char Editor/Resources/SND1.WAV new file mode 100644 index 00000000..d057572a Binary files /dev/null and b/Blades of Exile Char Editor/Resources/SND1.WAV differ diff --git a/Blades of Exile Char Editor/Resources/SND3.WAV b/Blades of Exile Char Editor/Resources/SND3.WAV new file mode 100644 index 00000000..ce6b09d0 Binary files /dev/null and b/Blades of Exile Char Editor/Resources/SND3.WAV differ diff --git a/Blades of Exile Char Editor/Resources/SND34.WAV b/Blades of Exile Char Editor/Resources/SND34.WAV new file mode 100644 index 00000000..0a40f8d7 Binary files /dev/null and b/Blades of Exile Char Editor/Resources/SND34.WAV differ diff --git a/Blades of Exile Char Editor/Resources/SND37.WAV b/Blades of Exile Char Editor/Resources/SND37.WAV new file mode 100644 index 00000000..6781ba20 Binary files /dev/null and b/Blades of Exile Char Editor/Resources/SND37.WAV differ diff --git a/Blades of Exile Char Editor/Resources/SWORD.CUR b/Blades of Exile Char Editor/Resources/SWORD.CUR new file mode 100644 index 00000000..938203a3 Binary files /dev/null and b/Blades of Exile Char Editor/Resources/SWORD.CUR differ diff --git a/Blades of Exile Char Editor/Resources/TALK.CUR b/Blades of Exile Char Editor/Resources/TALK.CUR new file mode 100644 index 00000000..2d0fe3e6 Binary files /dev/null and b/Blades of Exile Char Editor/Resources/TALK.CUR differ diff --git a/Blades of Exile Char Editor/Resources/TARGET.CUR b/Blades of Exile Char Editor/Resources/TARGET.CUR new file mode 100644 index 00000000..a077508f Binary files /dev/null and b/Blades of Exile Char Editor/Resources/TARGET.CUR differ diff --git a/Blades of Exile Char Editor/Resources/U.CUR b/Blades of Exile Char Editor/Resources/U.CUR new file mode 100644 index 00000000..56ef1d9c Binary files /dev/null and b/Blades of Exile Char Editor/Resources/U.CUR differ diff --git a/Blades of Exile Char Editor/Resources/UL.CUR b/Blades of Exile Char Editor/Resources/UL.CUR new file mode 100644 index 00000000..9ffadb99 Binary files /dev/null and b/Blades of Exile Char Editor/Resources/UL.CUR differ diff --git a/Blades of Exile Char Editor/Resources/UR.CUR b/Blades of Exile Char Editor/Resources/UR.CUR new file mode 100644 index 00000000..113bd7a3 Binary files /dev/null and b/Blades of Exile Char Editor/Resources/UR.CUR differ