public void S_C_GunPowerUp(CMD_SC_GF_GUN_POWER_UP _gunPowerUp) { int _chair = (int)_gunPowerUp.gsChair; if (_chair >= CanonCtrl.Instance.deskType || _chair < 0) { return; } if (CanonCtrl.Instance.singleCanonList[_chair] != null) { CanonCtrl.Instance.singleCanonList[_chair].GunPowerUp(_chair, (int)_gunPowerUp.gsPower); } }
private bool DidGunPowerUp(int wHandleCode, byte[] wByteBuffer, int wDataSize) { int dataLen = wByteBuffer.Length; if (dataLen < wDataSize) { Debug.LogError("User join in data Error!!"); return(false); } CMD_SC_GF_GUN_POWER_UP gunPowerUp = GameConvert.ByteToStruct <CMD_SC_GF_GUN_POWER_UP>(wByteBuffer, wByteBuffer.Length); if (onGunPowerUpEvent != null) { onGunPowerUpEvent(gunPowerUp); } return(true); }