diff --git a/Fk/Pages/RoomLogic.js b/Fk/Pages/RoomLogic.js index 8c5f798a990e3c2d360ccdd3944623c8f0ddb81e..95efbe94cf39da6814621bd6e03e7d5c37bf05b7 100644 --- a/Fk/Pages/RoomLogic.js +++ b/Fk/Pages/RoomLogic.js @@ -553,6 +553,9 @@ function getPlayerStr(playerid) { if (photo.deputyGeneral && photo.deputyGeneral !== "") { ret = ret + "/" + luatr(photo.deputyGeneral); } + if (playerid == Self.id) { + ret = ret + luatr("playerstr_self") + } return ret; } diff --git a/Fk/util.js b/Fk/util.js index 2c8c49d3ec8107063fecace1ed1879c680de8ca7..3e8ea9910e0e0278e3e7a30d4eac46b586d7dac6 100644 --- a/Fk/util.js +++ b/Fk/util.js @@ -23,6 +23,9 @@ function getPlayerStr(playerid) { if (photo.deputyGeneral && photo.deputyGeneral !== "") { ret = ret + "/" + luatr(photo.deputyGeneral); } + if (playerid == Self.id) { + ret = ret + luatr("playerstr_self") + } return ret; } diff --git a/lua/client/client.lua b/lua/client/client.lua index b8b6210e19d08ded71c9ae036af8d5f34e60a5bd..3cfb10360ae39d66e380732c692a405668c46475 100644 --- a/lua/client/client.lua +++ b/lua/client/client.lua @@ -192,6 +192,9 @@ local function parseMsg(msg, nocolor, visible_data) break end end + if pid == Self.id then + ret = ret .. Fk:translate("playerstr_self") + end ret = string.format(str, color, ret) return ret end diff --git a/lua/client/i18n/en_US.lua b/lua/client/i18n/en_US.lua index bb8d2fd5dcd931cda0073d01a3f048647b3d958a..519062e6f58f8af0667842a75c043ebf63a0c9d7 100644 --- a/lua/client/i18n/en_US.lua +++ b/lua/client/i18n/en_US.lua @@ -293,6 +293,7 @@ Fk:loadTranslationTable({ ["seat#11"] = "Seat#11", ["seat#12"] = "Seat#12", ["@ControledBy"] = "Controller", + ["playerstr_self"] = "(you)", -- ["Menu"] = "菜单", -- ["Surrender"] = "投降", diff --git a/lua/client/i18n/vi_VN.lua b/lua/client/i18n/vi_VN.lua index f81f098710b58da77e8b70c9f9f32953aeb38e56..9c3a73ba5a6d070746df522425ea3544f5475ce5 100644 --- a/lua/client/i18n/vi_VN.lua +++ b/lua/client/i18n/vi_VN.lua @@ -348,6 +348,7 @@ Trang chủ: https://libgit2.org ["seat#11"] = "#11", ["seat#12"] = "#12", ["@ControledBy"] = "Bị kiểm soát bởi", + --["playerstr_self"] = "(你)", ["Menu"] = "Menu", ["Surrender"] = "Đầu hàng", diff --git a/lua/client/i18n/zh_CN.lua b/lua/client/i18n/zh_CN.lua index b205b32fcc21dd99f6227f8d6f2c4cf152d0319d..95eed7bd73530d1b14e8063d28721c387bd90fd1 100644 --- a/lua/client/i18n/zh_CN.lua +++ b/lua/client/i18n/zh_CN.lua @@ -362,6 +362,7 @@ FreeKill使用的是libgit2的C API,与此同时使用Git完成拓展包的下 ["seat#11"] = "十一号位", ["seat#12"] = "十二号位", ["@ControledBy"] = "控制者", + ["playerstr_self"] = "(你)", ["Menu"] = "菜单", ["Surrender"] = "投降", diff --git a/lua/server/gameevent.lua b/lua/server/gameevent.lua index 756be449caf8e045311197536bbf5e5421ded518..bc77a64a51b362c79b5870a3d3754aee6bcfb28e 100644 --- a/lua/server/gameevent.lua +++ b/lua/server/gameevent.lua @@ -115,6 +115,9 @@ local function parseMsg(msg, nocolor, visible_data) break end end + if pid == Self.id then + ret = ret .. Fk:translate("playerstr_self") + end ret = string.format(str, color, ret) return ret end