OSDN Git Service

[Feature] #41179 angband-version.c を作成して put_version() を移動. / Create angband-version...
authordeskull <deskull@users.sourceforge.jp>
Sun, 17 Jan 2021 15:02:00 +0000 (00:02 +0900)
committerdeskull <deskull@users.sourceforge.jp>
Sun, 17 Jan 2021 15:02:00 +0000 (00:02 +0900)
Hengband/Hengband/Hengband.vcxproj
Hengband/Hengband/Hengband.vcxproj.filters
src/Makefile.am
src/main/angband-initializer.c
src/system/angband-version.c [new file with mode: 0644]

index c51d87c..708871f 100644 (file)
     <ClCompile Include="..\..\src\store\purchase-order.c" />\r
     <ClCompile Include="..\..\src\store\sell-order.c" />\r
     <ClCompile Include="..\..\src\store\service-checker.c" />\r
+    <ClCompile Include="..\..\src\system\angband-version.c" />\r
     <ClCompile Include="..\..\src\target\grid-selector.c" />\r
     <ClCompile Include="..\..\src\target\projection-path-calculator.c" />\r
     <ClCompile Include="..\..\src\target\target-describer.c" />\r
index c5298cd..6d72f8b 100644 (file)
     <ClCompile Include="..\..\src\monster-attack\monster-attack-lose.c">
       <Filter>monster-attack</Filter>
     </ClCompile>
+    <ClCompile Include="..\..\src\system\angband-version.c">
+      <Filter>system</Filter>
+    </ClCompile>
   </ItemGroup>
   <ItemGroup>
     <ClInclude Include="..\..\src\combat\shoot.h">
index ee792d0..8106303 100644 (file)
@@ -799,7 +799,8 @@ hengband_SOURCES = \
        \
        system/alloc-entries.c system/alloc-entries.h \
        system/alloc-entry-definition.h \
-       system/angband.h system/angband-version.h \
+       system/angband.h \
+       system/angband-version.c system/angband-version.h \
        system/artifact-type-definition.c system/artifact-type-definition.h \
        system/building-type-definition.c system/building-type-definition.h \
        system/dungeon-data-definition.h \
index b70be71..61b5cd6 100644 (file)
@@ -123,17 +123,6 @@ static void init_angband_aux(concptr why)
     quit(_("致命的なエラー。", "Fatal Error."));
 }
 
-void put_version(char *buf)
-{
-    if (IS_ALPHA_VERSION) {
-        sprintf(buf, "変愚蛮怒 %d.%d.%dAlpha%d", H_VER_MAJOR, H_VER_MINOR, H_VER_PATCH, H_VER_EXTRA);
-
-    } else {
-        char *mode = IS_STABLE_VERSION ? _("安定版", "Stable") : _("開発版", "Developing");
-        sprintf(buf, _("変愚蛮怒 %d.%d.%d.%d(%s)", "Hengband %d.%d.%d.%d(%s)"), H_VER_MAJOR, H_VER_MINOR, H_VER_PATCH, H_VER_EXTRA, mode);
-    }
-}
-
 /*!
  * @brief タイトル記述
  * @param なし
diff --git a/src/system/angband-version.c b/src/system/angband-version.c
new file mode 100644 (file)
index 0000000..2bd89f3
--- /dev/null
@@ -0,0 +1,14 @@
+#pragma once
+#include "system/angband.h"
+#include "system/angband-version.h"
+
+void put_version(char *buf)
+{
+    if (IS_ALPHA_VERSION) {
+        sprintf(buf, "変愚蛮怒 %d.%d.%dAlpha%d", H_VER_MAJOR, H_VER_MINOR, H_VER_PATCH, H_VER_EXTRA);
+
+    } else {
+        char *mode = IS_STABLE_VERSION ? _("安定版", "Stable") : _("開発版", "Developing");
+        sprintf(buf, _("変愚蛮怒 %d.%d.%d.%d(%s)", "Hengband %d.%d.%d.%d(%s)"), H_VER_MAJOR, H_VER_MINOR, H_VER_PATCH, H_VER_EXTRA, mode);
+    }
+}