void Awake() { Read('='); ip = GetValue("ip"); port = GetValue("port"); if (ip == "" || port == "") { Debug.LogWarning("canshuweikong"); } instance = this; myClient = new NetworkClient(); SetupClient(); }
public override void restoreSnapshot() { VimClientImpl _vClient = VClient.getConnection(); VirtualMachine vm = VClient.getMachine(); // Find a named snapshot which corresponds to what we're interested in VirtualMachineSnapshotTree snapshot = findRecusively(vm.Snapshot.RootSnapshotList, _spec.snapshotFriendlyName); // and revert it. VirtualMachineSnapshot shot = new VirtualMachineSnapshot(_vClient, snapshot.Snapshot); shot.RevertToSnapshot(vm.MoRef, false); }
public void Tick() { if (ConfigManager.CMisc.BunnyHop) { if (NativeMethods.GetAsyncKeyState(KeysCode.VK_SPACE) && !Base.LocalPlayer.BhopFlag() && Base.LocalPlayer.Velocity > 25) { VClient.SetForceJump(VClient.SUserCMD.ButtonID.IN_JUMP); } } if (ConfigManager.CMisc.NoFlash) { Base.LocalPlayer.FlashMax = 0f; } }
public void Tick(TeamID playerBaseTeam) { if (ConfigManager.CAim.AimActive) { ActiveWeapon = ConfigManager.CAimWeapon[GetWeaponID(BaseWeapon.ActiveWeaponIndex)]; if (NativeMethods.GetAsyncKeyState(KeysCode.MS_Click1)) { if (ActiveWeapon.WeaponActive && BaseWeapon.ActiveWeaponClip > 0) { if (!IsClosed) { if (Base.LocalPlayer.CrosshairId > 0 && Base.LocalPlayer.CrosshairId < VEngineClient.MaxPlayers) { PlayerBase crosshairPlayer = IClientEntityList.GetClientEntity(Base.LocalPlayer.CrosshairId).GetPlayer; m_Entity = GetTarget(crosshairPlayer, ActiveWeapon, crosshairPlayer.Team, playerBaseTeam); } else { m_Entity = NearestTarget(); } IsClosed = true; } if (m_Entity && m_Entity.Health != 0) { if (ActiveWeapon.SilentActive && Base.LocalPlayer.Bullet(false)) { SetViewAngelSilent(m_Entity.AngleToTarget(false, ActiveWeapon.WeaponBone, ActiveWeapon.RcsValue, ActiveWeapon.RcsActive)); } else { VEngineClient.ViewAngels = Vector.SmoothAngle(VEngineClient.ViewAngels, m_Entity.AngleToTarget(true, ActiveWeapon.WeaponBone, ActiveWeapon.RcsValue, ActiveWeapon.RcsActive), ActiveWeapon.Smooth); } } else { IsClosed = false; } if (ActiveWeapon.RcsStandaloneActive && Base.LocalPlayer.Bullet(true)) { RcsStandalone(ActiveWeapon.RcsStandaloneX, ActiveWeapon.RcsStandaloneY); } } if (ConfigManager.CAimMisc.MouseAttackActive) { VClient.SetForceAttack(VClient.SUserCMD.ButtonID.IN_ATTACK); } } else { OldAngle.X = OldAngle.Y = 0.0f; IsClosed = false; VClient.SetForceAttack(VClient.SUserCMD.ButtonID.IN_NOATTACK); } } }