Please tell me way to use end game device in Verse code to end a round of a game.
With the follwing code, I tried to end a round and start next round.
However, when starting Fortnite on UEFN, it seems that this ends a game, not a round because round result is not shown as the first attached movie.
Like the second attached movie, I would like to end a round.
How should I change the code?
Thank you.
@editable
EndGame<public> : end_game_device = end_game_device{}
OnBegin<override>()<suspends>:void=
Playspace: fort_playspace = GetPlayspace()
var AllPlayers: []player = Playspace.GetPlayers()
if (FirstPlayer : player = AllPlayers[0]):
EndRound(FirstPlayer)
EndRound<private>(Agent:agent)<suspends> : void =
EndGame.Activate(Agent)
End game device property setting on the level
Winning Team: Winning Team
Activating Team: Any
What to End: End Round
Thank you very much for your reply.
I tried to use your code, setting “round setting” prop on the level and assign it to the creative device.
The result is the same with the first picture of my above post, Moving to edit mode session after execting EndRound.EndRound(Agent) on Fortnite from UEFN.
(The attached movie shows that after “RoundEnded” is printed in Log, this game moves to the edit mode)
However, because using “EndRound” method of round_settings_device class, it seems to me that round would be ended and move to the next round when playing this game on Fortnite.
On your enviroment of UEFN, round is ended and move to the next?
However, as you said, the cause seems to lie in “island settings”.
My island setings are followings (“Total Round” item has ‘25’);
Is there any problem on it? (I set 5 player spawn on the level)
|Voice Chat|All
|Max Players|100
|Teams|Free For All
|Team Size|Dynamic
|Default Class Identifier|No Class
|Revert To Default Class At|End of Round,
|Spawn Limit (Toggle On and Off)|10
|After Last Spawn Go To|Team Index, Team Index
|Total Rounds|25
|Team Rotation (Toggle On and Off)|False,
|End Game On Match Point Win|False
|Team Visuals Determined At|Round Start
|Time Limit (Toggle On and Off)|false
|Fastest Time Win|False
|All Teams Must Finish|False
|Game Win Condition|Most Score Wins,
|Eliminations to End (Toggle On and Off)|False
|AI Eliminations to End (Toggle On and Off)|False
|Objectives To End (Toggle On and Off)|False
|Collect Items to End (Toggle On and Off)|False
|Collect Item Count|False
|Score to End (Toggle On and Off)|False
|Last Standing Ends Game|False
|Join In Progress|Spawn
|Spawn Location|Spawn Pads
|Spawn Pad Selection|Random
|Respawn Type|Individual
|Post-Game Spawn Location|Island Start
|Only Allow Respawn If Spawn Pads found|False
|Auto Start|False
|Game Start Countdown|3.0
|Elimination Score|0.0,
|Assist Score|0.0,