CN translation

UI, ability, night order
This commit is contained in:
Zijie Ning 2024-12-03 01:58:43 +01:00
parent 8c708d24a8
commit 72d17f76e4
7 changed files with 41 additions and 43 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 23 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

View file

@ -134,10 +134,6 @@
Copy player link Copy player link
<em><font-awesome-icon icon="copy"/></em> <em><font-awesome-icon icon="copy"/></em>
</li> </li>
<li v-if="!session.isSpectator" @click="distributeRoles">
Send Characters
<em><font-awesome-icon icon="theater-masks"/></em>
</li>
<li <li
v-if="session.voteHistory.length || !session.isSpectator" v-if="session.voteHistory.length || !session.isSpectator"
@click="toggleModal('voteHistory')" @click="toggleModal('voteHistory')"
@ -145,7 +141,7 @@
Vote history<em>[V]</em> Vote history<em>[V]</em>
</li> </li>
<li @click="leaveSession"> <li @click="leaveSession">
Leave Session 退出房间
<em>{{ session.sessionId }}</em> <em>{{ session.sessionId }}</em>
</li> </li>
</template> </template>
@ -154,13 +150,13 @@
<template v-if="tab === 'players' && !session.isSpectator"> <template v-if="tab === 'players' && !session.isSpectator">
<!-- Users --> <!-- Users -->
<li class="headline">Players</li> <li class="headline">Players</li>
<li @click="addPlayer" v-if="players.length < 20">Add<em>[A]</em></li> <li @click="addPlayer" v-if="players.length < 20">添加座位<em>[A]</em></li>
<li @click="randomizeSeatings" v-if="players.length > 2"> <li @click="randomizeSeatings" v-if="players.length > 2">
Randomize 随机座位
<em><font-awesome-icon icon="dice"/></em> <em><font-awesome-icon icon="dice"/></em>
</li> </li>
<li @click="clearPlayers" v-if="players.length"> <li @click="clearPlayers" v-if="players.length">
Remove all 移除全部座位
<em><font-awesome-icon icon="trash-alt"/></em> <em><font-awesome-icon icon="trash-alt"/></em>
</li> </li>
</template> </template>
@ -169,22 +165,26 @@
<!-- Characters --> <!-- Characters -->
<li class="headline">Characters</li> <li class="headline">Characters</li>
<li v-if="!session.isSpectator" @click="toggleModal('edition')"> <li v-if="!session.isSpectator" @click="toggleModal('edition')">
Select Edition 选择剧本
<em>[E]</em> <em>[E]</em>
</li> </li>
<li <li
@click="toggleModal('roles')" @click="toggleModal('roles')"
v-if="!session.isSpectator && players.length > 4" v-if="!session.isSpectator && players.length > 4"
> >
Choose & Assign 分配角色
<em>[C]</em> <em>[C]</em>
</li> </li>
<li v-if="!session.isSpectator" @click="distributeRoles">
发送角色
<em><font-awesome-icon icon="theater-masks"/></em>
</li>
<li v-if="!session.isSpectator" @click="toggleModal('fabled')"> <li v-if="!session.isSpectator" @click="toggleModal('fabled')">
Add Fabled 传奇角色
<em><font-awesome-icon icon="dragon"/></em> <em><font-awesome-icon icon="dragon"/></em>
</li> </li>
<li @click="clearRoles" v-if="players.length"> <li @click="clearRoles" v-if="players.length">
Remove all 移除全部角色
<em><font-awesome-icon icon="trash-alt"/></em> <em><font-awesome-icon icon="trash-alt"/></em>
</li> </li>
</template> </template>
@ -193,11 +193,11 @@
<!-- Help --> <!-- Help -->
<li class="headline">Help</li> <li class="headline">Help</li>
<li @click="toggleModal('reference')"> <li @click="toggleModal('reference')">
Reference Sheet 角色能力表
<em>[R]</em> <em>[R]</em>
</li> </li>
<li @click="toggleModal('nightOrder')"> <li @click="toggleModal('nightOrder')">
Night Order Sheet 夜晚顺序表
<em>[N]</em> <em>[N]</em>
</li> </li>
<li @click="toggleModal('gameState')"> <li @click="toggleModal('gameState')">
@ -253,7 +253,7 @@ export default {
hostSession() { hostSession() {
if (this.session.sessionId) return; if (this.session.sessionId) return;
const sessionId = prompt( const sessionId = prompt(
"Enter a channel number / name for your session", "输入你想要创建的房间的名称或号码",
Math.round(Math.random() * 10000) Math.round(Math.random() * 10000)
); );
if (sessionId) { if (sessionId) {
@ -271,7 +271,7 @@ export default {
distributeRoles() { distributeRoles() {
if (this.session.isSpectator) return; if (this.session.isSpectator) return;
const popup = const popup =
"Do you want to distribute assigned characters to all SEATED players?"; "你确定要向所有已入座的玩家发送角色吗?";
if (confirm(popup)) { if (confirm(popup)) {
this.$store.commit("session/distributeRoles", true); this.$store.commit("session/distributeRoles", true);
setTimeout( setTimeout(
@ -292,7 +292,7 @@ export default {
joinSession() { joinSession() {
if (this.session.sessionId) return this.leaveSession(); if (this.session.sessionId) return this.leaveSession();
let sessionId = prompt( let sessionId = prompt(
"Enter the channel number / name of the session you want to join" "输入你想要加入的房间的名称或号码"
); );
if (sessionId.match(/^https?:\/\//i)) { if (sessionId.match(/^https?:\/\//i)) {
sessionId = sessionId.split("#").pop(); sessionId = sessionId.split("#").pop();
@ -305,7 +305,7 @@ export default {
} }
}, },
leaveSession() { leaveSession() {
if (confirm("Are you sure you want to leave the active live game?")) { if (confirm("你确定要离开房间吗?")) {
this.$store.commit("session/setSpectator", false); this.$store.commit("session/setSpectator", false);
this.$store.commit("session/setSessionId", ""); this.$store.commit("session/setSessionId", "");
} }
@ -320,13 +320,13 @@ export default {
}, },
randomizeSeatings() { randomizeSeatings() {
if (this.session.isSpectator) return; if (this.session.isSpectator) return;
if (confirm("Are you sure you want to randomize seatings?")) { if (confirm("你确定要打乱座位吗?")) {
this.$store.dispatch("players/randomize"); this.$store.dispatch("players/randomize");
} }
}, },
clearPlayers() { clearPlayers() {
if (this.session.isSpectator) return; if (this.session.isSpectator) return;
if (confirm("Are you sure you want to remove all players?")) { if (confirm("你确定要移除所有座位吗?")) {
// abort vote if in progress // abort vote if in progress
if (this.session.nomination) { if (this.session.nomination) {
this.$store.commit("session/nomination"); this.$store.commit("session/nomination");
@ -335,7 +335,7 @@ export default {
} }
}, },
clearRoles() { clearRoles() {
if (confirm("Are you sure you want to remove all player roles?")) { if (confirm("你确定要移除所有玩家的角色吗?")) {
this.$store.dispatch("players/clearRoles"); this.$store.dispatch("players/clearRoles");
} }
}, },

View file

@ -632,11 +632,11 @@ li.move:not(.from) .player .overlay svg.move {
} }
} }
@include glow("townsfolk", $townsfolk); @include glow("镇民", $townsfolk);
@include glow("outsider", $outsider); @include glow("外来者", $outsider);
@include glow("demon", $demon); @include glow("恶魔", $demon);
@include glow("minion", $minion); @include glow("爪牙", $minion);
@include glow("traveler", $traveler); @include glow("旅行者", $traveler);
.player.you .token { .player.you .token {
animation: townsfolk-glow 5s ease-in-out infinite; animation: townsfolk-glow 5s ease-in-out infinite;

View file

@ -31,7 +31,7 @@
> >
<h3> <h3>
<span v-if="session.isSpectator">Other characters</span> <span v-if="session.isSpectator">Other characters</span>
<span v-else>Demon bluffs</span> <span v-else>恶魔的伪装角色</span>
<font-awesome-icon icon="times-circle" @click.stop="toggleBluffs" /> <font-awesome-icon icon="times-circle" @click.stop="toggleBluffs" />
<font-awesome-icon icon="plus-circle" @click.stop="toggleBluffs" /> <font-awesome-icon icon="plus-circle" @click.stop="toggleBluffs" />
</h3> </h3>
@ -48,7 +48,7 @@
<div class="fabled" :class="{ closed: !isFabledOpen }" v-if="fabled.length"> <div class="fabled" :class="{ closed: !isFabledOpen }" v-if="fabled.length">
<h3> <h3>
<span>Fabled</span> <span>传奇角色</span>
<font-awesome-icon icon="times-circle" @click.stop="toggleFabled" /> <font-awesome-icon icon="times-circle" @click.stop="toggleFabled" />
<font-awesome-icon icon="plus-circle" @click.stop="toggleFabled" /> <font-awesome-icon icon="plus-circle" @click.stop="toggleFabled" />
</h3> </h3>

View file

@ -113,25 +113,24 @@ export default {
if (this.players.length > 6) { if (this.players.length > 6) {
rolesFirstNight.push( rolesFirstNight.push(
{ {
id: "evil", id: "minion_info",
name: "Minion info", name: "爪牙信息",
firstNight: 5, firstNight: 5,
team: "minion", team: "minion",
players: this.players.filter(p => p.role.team === "minion"), players: this.players.filter(p => p.role.team === "minion"),
firstNightReminder: firstNightReminder:
"• If more than one Minion, they all make eye contact with each other. " + "• 如果有七名或以上玩家:爪牙睁眼相互认识。" +
"• Show the “This is the Demon” card. Point to the Demon." "• 告诉他们恶魔是哪名玩家。"
}, },
{ {
id: "evil", id: "demon_info",
name: "Demon info & bluffs", name: "恶魔信息",
firstNight: 8, firstNight: 8,
team: "demon", team: "demon",
players: this.players.filter(p => p.role.team === "demon"), players: this.players.filter(p => p.role.team === "demon"),
firstNightReminder: firstNightReminder:
"• Show the “These are your minions” card. Point to each Minion. " + "• 如果有七名或以上玩家:告诉恶魔,这些玩家是你的爪牙。 " +
"• Show the “These characters are not in play” card. Show 3 character tokens of good " + "• 告诉恶魔3个不在场的伪装角色。"
"characters not in play."
} }
); );
} }

View file

@ -4,7 +4,7 @@
v-if="modals.roles && nonTravelers >= 5" v-if="modals.roles && nonTravelers >= 5"
@close="toggleModal('roles')" @close="toggleModal('roles')"
> >
<h3>Select the characters for {{ nonTravelers }} players:</h3> <h3>{{ nonTravelers }} 个玩家选择角色:</h3>
<ul class="tokens" v-for="(teamRoles, team) in roleSelection" :key="team"> <ul class="tokens" v-for="(teamRoles, team) in roleSelection" :key="team">
<li class="count" :class="[team]"> <li class="count" :class="[team]">
{{ teamRoles.reduce((a, { selected }) => a + selected, 0) }} / {{ teamRoles.reduce((a, { selected }) => a + selected, 0) }} /
@ -31,14 +31,13 @@
<div class="warning" v-if="hasSelectedSetupRoles"> <div class="warning" v-if="hasSelectedSetupRoles">
<font-awesome-icon icon="exclamation-triangle" /> <font-awesome-icon icon="exclamation-triangle" />
<span> <span>
Warning: there are characters selected that modify the game setup! The 注意目前选择的角色会影响配板需要说书人手动调整
randomizer does not account for these characters.
</span> </span>
</div> </div>
<label class="multiple" :class="{ checked: allowMultiple }"> <label class="multiple" :class="{ checked: allowMultiple }">
<font-awesome-icon :icon="allowMultiple ? 'check-square' : 'square'" /> <font-awesome-icon :icon="allowMultiple ? 'check-square' : 'square'" />
<input type="checkbox" name="allow-multiple" v-model="allowMultiple" /> <input type="checkbox" name="allow-multiple" v-model="allowMultiple" />
Allow duplicate characters 允许重复角色
</label> </label>
<div class="button-group"> <div class="button-group">
<div <div
@ -49,11 +48,11 @@
}" }"
> >
<font-awesome-icon icon="people-arrows" /> <font-awesome-icon icon="people-arrows" />
Assign {{ selectedRoles }} characters randomly 随机分配 {{ selectedRoles }} 个角色
</div> </div>
<div class="button" @click="selectRandomRoles"> <div class="button" @click="selectRandomRoles">
<font-awesome-icon icon="random" /> <font-awesome-icon icon="random" />
Shuffle characters 随机选取角色
</div> </div>
</div> </div>
</Modal> </Modal>