Vector3 GetPlayerSpawnPos() { IntVector2 posXZ = VArtifactUtil.GetSpawnPos(); Vector3 pos = new Vector3(posXZ.x, VFDataRTGen.GetPosTop(posXZ), posXZ.y); return(pos); }
void PeLauncher.ILaunchable.Launch() { Vector3 pos; if (PeGameMgr.IsMultiStory) { pos = new Vector3(12227f, 121.5f, 6095f); } else { VArtifactUtil.GetSpawnPos(); //IntVector2 posXZ = new IntVector2(0, 0); pos = Pathea.PlayerSpawnPosProvider.Instance.GetPos(); } BaseNetwork.MainPlayer.RequestPlayerLogin(pos); }
void PeLauncher.ILaunchable.Launch() { if (null == BaseNetwork.MainPlayer) { return; } Vector3 pos = BaseNetwork.MainPlayer._pos; if (BaseNetwork.MainPlayer.UseNewPos) { IntVector2 posXZ = VArtifactUtil.GetSpawnPos(); pos = new Vector3(posXZ.x, VFDataRTGen.GetPosTop(posXZ), posXZ.y); } Pathea.PlayerSpawnPosProvider.Instance.SetPos(pos); }
void BtnClick_OnCancel() { if (currentState == ReivieState.Reivie_Servant || currentEntity == null) { Hide(); return; } if (!PeGameMgr.IsMulti) { ReviveLabel label = new ReviveLabel(); label.pos = currentEntity.position; ReviveLabel.Mgr.Instance.Add(label); if (RandomDungenMgrData.InDungeon) { bool reviveSuc = DoRevive(true); if (reviveSuc) { currentEntity.position = RandomDungenMgrData.revivePos; Hide(); } return; } //lz-2016.08.03 空对象 if (null != MissionManager.Instance) { MissionManager.Instance.RemoveFollowTowerMission(); } DoRevive(true); Vector3 revivePos; if (SingleGameStory.curType == SingleGameStory.StoryScene.DienShip0) { revivePos = new Vector3(14798.09f, 20.98818f, 8246.396f); } else if (SingleGameStory.curType == SingleGameStory.StoryScene.L1Ship) { revivePos = new Vector3(9649.354f, 90.488f, 12744.77f); } else if (SingleGameStory.curType == SingleGameStory.StoryScene.PajaShip) { revivePos = new Vector3(1593.53f, 148.635f, 8022.03f); } else { revivePos = GetNearFastTrvalPos(currentEntity.position); } Pathea.FastTravelMgr.Instance.TravelTo(revivePos); } else { Vector3 warpPos = Vector3.zero; if (RandomDungenMgrData.InDungeon) { warpPos = RandomDungenMgrData.revivePos; } else if (PeGameMgr.IsMultiCoop) { warpPos = GetNearFastTrvalPos(currentEntity.position); } else { if (PeGameMgr.IsCustom) { warpPos = PlayerNetwork.mainPlayer.GetCustomModePos(); } else { IntVector2 posXZ = VArtifactUtil.GetSpawnPos(); warpPos = new Vector3(posXZ.x, VFDataRTGen.GetPosTop(posXZ), posXZ.y); } } PlayerNetwork.mainPlayer.RPCServer(EPacketType.PT_InGame_PlayerReset, warpPos); PlayerNetwork.mainPlayer.RequestChangeScene(0); } Hide(); }