阶段暂存
This commit is contained in:
		
							
								
								
									
										12
									
								
								Content/Lua/Level/LevelPlayerState.lua
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								Content/Lua/Level/LevelPlayerState.lua
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,12 @@ | ||||
| local GameplayStatics = import("GameplayStatics") | ||||
|  | ||||
| local LevelPlayerState = {} | ||||
|  | ||||
| function LevelPlayerState:ReceiveBeginPlay() | ||||
|     local pc = GameplayStatics.GetPlayerController(self, 0) | ||||
|     local role = self:CreateRoleRoster(pc) | ||||
|     print("LevelPlayerState:ReceiveBeginPlay", role, self:HasAuthority()) | ||||
|     pc:Possess(role) | ||||
| end | ||||
|  | ||||
| return Class(nil, nil, LevelPlayerState) | ||||
		Reference in New Issue
	
	Block a user