OSDN Git Service

#37287 #37353 (2.2.0.89) BACT_IDX, BACT_RESTRICT_IDX 型を定義し、型の置換を継続中。LNK4075を修正。 ...
authorDeskull <desull@users.sourceforge.jp>
Tue, 12 Dec 2017 16:02:50 +0000 (01:02 +0900)
committerDeskull <desull@users.sourceforge.jp>
Tue, 12 Dec 2017 16:02:50 +0000 (01:02 +0900)
Hengband_vcs2015/Hengband/Hengband.vcxproj
src/bldg.c
src/h-type.h
src/init1.c
src/types.h
src/wizard2.c

index 3b2598e..54bb818 100644 (file)
@@ -1,5 +1,17 @@
 <?xml version="1.0" encoding="utf-8"?>\r
-<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
+  <Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
+    <ConfigurationType>StaticLibrary</ConfigurationType>\r
+    <UseDebugLibraries>true</UseDebugLibraries>\r
+    <PlatformToolset>v120</PlatformToolset>\r
+    <CharacterSet>Unicode</CharacterSet>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
+    <ConfigurationType>StaticLibrary</ConfigurationType>\r
+    <UseDebugLibraries>false</UseDebugLibraries>\r
+    <PlatformToolset>v120</PlatformToolset>\r
+    <CharacterSet>Unicode</CharacterSet>\r
+  </PropertyGroup>\r
   <ItemGroup Label="ProjectConfigurations">\r
     <ProjectConfiguration Include="Debug|Win32">\r
       <Configuration>Debug</Configuration>\r
index 094b425..c5bc79b 100644 (file)
@@ -4293,8 +4293,8 @@ static bool research_mon(void)
  */
 static void bldg_process_command(building_type *bldg, int i)
 {
-       int bact = bldg->actions[i];
-       int bcost;
+       BACT_IDX bact = bldg->actions[i];
+       PRICE bcost;
        bool paid = FALSE;
        int amt;
 
index f5139db..4dd0576 100644 (file)
@@ -113,6 +113,8 @@ typedef s16b CLASS_IDX;                     /*!< ゲーム中のプレイヤー職業ID型を定
 typedef s16b MIMIC_RACE_IDX;   /*!< ゲーム中のプレイヤー変身種族ID型を定義 */
 typedef s16b PATRON_IDX;               /*!< ゲーム中のプレイヤーパトロンID型を定義 */
 typedef s32b ACTION_IDX;               /*!< プレイヤーが現在取っている常時行動のID定義 */
+typedef s16b BACT_IDX;                 /*!< 町の施設処理のID定義 */
+typedef s16b BACT_RESTRICT_IDX;        /*!< 町の施設処理の規制処理ID定義 */
 
 typedef s16b MONRACE_IDX;              /*!< ゲーム中のモンスター種族ID型を定義 */
 typedef s16b MONSTER_IDX;              /*!< ゲーム中のモンスター個体ID型を定義 */
index 306068d..998e188 100644 (file)
@@ -3864,10 +3864,10 @@ static errr parse_line_building(char *buf)
                                building[index].letters[action_index] = zz[4][0];
 
                                /* Action code */
-                               building[index].actions[action_index] = atoi(zz[5]);
+                               building[index].actions[action_index] = (BACT_IDX)atoi(zz[5]);
 
                                /* Action restriction */
-                               building[index].action_restr[action_index] = atoi(zz[6]);
+                               building[index].action_restr[action_index] = (BACT_RESTRICT_IDX)atoi(zz[6]);
 
                                break;
                        }
index 54b18de..4fa714c 100644 (file)
@@ -1463,8 +1463,8 @@ struct building_type
        PRICE member_costs[8];           /* Costs for class members of building */
        PRICE other_costs[8];               /* Costs for nonguild members */
        char letters[8];                /* action letters */
-       s16b actions[8];                /* action codes */
-       s16b action_restr[8];           /* action restrictions */
+       BACT_IDX actions[8];                /* action codes */
+       BACT_RESTRICT_IDX action_restr[8];           /* action restrictions */
 
        CLASS_IDX member_class[MAX_CLASS];   /* which classes are part of guild */
        RACE_IDX member_race[MAX_RACES];    /* which classes are part of guild */
index 3068fed..df0595f 100644 (file)
@@ -1539,9 +1539,8 @@ static void do_cmd_wiz_jump(void)
        if (command_arg <= 0)
        {
                char    ppp[80];
-
                char    tmp_val[160];
-               int             tmp_dungeon_type;
+               DUNGEON_IDX tmp_dungeon_type;
 
                /* Prompt */
                sprintf(ppp, "Jump which dungeon : ");
@@ -1552,7 +1551,7 @@ static void do_cmd_wiz_jump(void)
                /* Ask for a level */
                if (!get_string(ppp, tmp_val, 2)) return;
 
-               tmp_dungeon_type = atoi(tmp_val);
+               tmp_dungeon_type = (DUNGEON_IDX)atoi(tmp_val);
                if (!d_info[tmp_dungeon_type].maxdepth || (tmp_dungeon_type > max_d_idx)) tmp_dungeon_type = DUNGEON_ANGBAND;
 
                /* Prompt */
@@ -1566,9 +1565,9 @@ static void do_cmd_wiz_jump(void)
                if (!get_string(ppp, tmp_val, 10)) return;
 
                /* Extract request */
-               command_arg = (s16b)atoi(tmp_val);
+               command_arg = (COMMAND_ARG)atoi(tmp_val);
 
-               dungeon_type = (byte_hack)tmp_dungeon_type;
+               dungeon_type = tmp_dungeon_type;
        }
 
        /* Paranoia */