X-Git-Url: https://git.cworth.org/git?p=lmno.games;a=blobdiff_plain;f=empathy%2Fempathy.jsx;h=90bf0fd360829299facce85a1e3593c3a82db63a;hp=b58f9359ff5bdc7bed3bef174cc6119ee7cee0b7;hb=HEAD;hpb=6e3daa0768dafe57ad8f045b8314502316dc7c66 diff --git a/empathy/empathy.jsx b/empathy/empathy.jsx index b58f935..90bf0fd 100644 --- a/empathy/empathy.jsx +++ b/empathy/empathy.jsx @@ -996,13 +996,12 @@ class Game extends React.PureComponent { } set_other_player_info(info) { - const player_object = {...info, active: true}; const other_players_copy = [...this.state.other_players]; const idx = other_players_copy.findIndex(o => o.id === info.id); if (idx >= 0) { - other_players_copy[idx] = player_object; + other_players_copy[idx] = info; } else { - other_players_copy.push(player_object); + other_players_copy.push(info); } this.setState({ other_players: other_players_copy