projects
/
vchess.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Advance on draw logic (for live, not corr)
[vchess.git]
/
client
/
src
/
views
/
Hall.vue
diff --git
a/client/src/views/Hall.vue
b/client/src/views/Hall.vue
index
60f6291
..
3a57944
100644
(file)
--- a/
client/src/views/Hall.vue
+++ b/
client/src/views/Hall.vue
@@
-8,7
+8,7
@@
main
p(v-html="infoMessage")
input#modalNewgame.modal(type="checkbox")
div(role="dialog" aria-labelledby="titleFenedit")
p(v-html="infoMessage")
input#modalNewgame.modal(type="checkbox")
div(role="dialog" aria-labelledby="titleFenedit")
- .card.smallpad
+ .card.smallpad
(@keyup.enter="newChallenge")
label#closeNewgame.modal-close(for="modalNewgame")
fieldset
label(for="selectVariant") {{ st.tr["Variant"] }}
label#closeNewgame.modal-close(for="modalNewgame")
fieldset
label(for="selectVariant") {{ st.tr["Variant"] }}
@@
-221,11
+221,7
@@
export default {
// ==> Moves sent by connected remote player(s) if live game
let url = "/game/" + g.id;
if (g.type == "live")
// ==> Moves sent by connected remote player(s) if live game
let url = "/game/" + g.id;
if (g.type == "live")
- {
- const remotes = g.players.filter(p => this.people.some(pl => pl.sid == p.sid));
- const rIdx = (remotes.length == 1 ? 0 : Math.floor(Math.random()*2));
- url += "?rid=" + remotes[rIdx].sid;
- }
+ url += "?rid=" + g.rid;
this.$router.push(url);
},
getVname: function(vid) {
this.$router.push(url);
},
getVname: function(vid) {
@@
-276,6
+272,9
@@
export default {
const data = JSON.parse(msg.data);
switch (data.code)
{
const data = JSON.parse(msg.data);
switch (data.code)
{
+ case "duplicate":
+ alert("Warning: duplicate 'offline' connection");
+ break;
// 0.2] Receive clients list (just socket IDs)
case "pollclients":
{
// 0.2] Receive clients list (just socket IDs)
case "pollclients":
{