private void ReadBombState(NetIncomingMessage msg, Player p, Bomb b) { bool active = msg.ReadBoolean(); if (active) { float remains = (float)(msg.ReadTime(false) - NetTime.Now); float px = msg.ReadFloat(); float py = msg.ReadFloat(); Direction dir = (Direction)msg.ReadByte(); float speed = msg.ReadFloat(); bool jelly = msg.ReadBoolean(); bool trigger = msg.ReadBoolean(); if (!b.isActive) { b.player = p; b.Activate(); game.Field.SetBomb(b); } b.timeRemains = remains; b.SetPos(px, py); b.SetSpeed(speed); b.SetJelly(jelly); b.SetTrigger(trigger); // TODO: jelly & trigger } else if (b.isActive) { b.Deactivate(); b.RemoveFromField(); } }