Skip to content

Commit

Permalink
Merging final GDK for Unreal 0.11.0 release
Browse files Browse the repository at this point in the history
Release 0.11.0
  • Loading branch information
gdk-for-unreal-bot committed Sep 3, 2020
2 parents 96d2e88 + 1a08127 commit d383ce3
Show file tree
Hide file tree
Showing 59 changed files with 76 additions and 81 deletions.
Binary file not shown.
Binary file modified Game/Content/Blueprints/Weapons/BP_InstantWeapon.uasset
Binary file not shown.
Binary file modified Game/Content/Blueprints/Weapons/BP_ProjectileWeapon.uasset
Binary file not shown.
Binary file modified Game/Content/Blueprints/Weapons/Grenades/BP_Projectile.uasset
Binary file not shown.
Binary file modified Game/Content/Characters/BP_SimulatedPlayerCharacter.uasset
Binary file not shown.
Binary file not shown.
Binary file modified Game/Content/Characters/Player/Meshes/CH_SK_PlayerRobot.uasset
Binary file not shown.
Binary file not shown.
Binary file modified Game/Content/Controllers/BP_GDK_PlayerController.uasset
Binary file not shown.
Binary file modified Game/Content/Controllers/BP_SimulatedPlayerAIController.uasset
Binary file not shown.
Binary file modified Game/Content/GameMode/BP_ControlGameState.uasset
Binary file not shown.
Binary file not shown.
Binary file added Game/Content/GameMode/BP_GymGameState.uasset
Binary file not shown.
Binary file modified Game/Content/GameMode/BP_TeamDeathmatchGameState.uasset
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added Game/Content/InGameTutorial/Maps/Map03_RPCs.umap
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified Game/Content/UI/Blueprints/BP_Minimal_HUD.uasset
Binary file not shown.
Binary file modified Game/Content/UI/Blueprints/BP_RangeFinder.uasset
Binary file not shown.
Binary file modified Game/Content/UI/Blueprints/Scores/BP_ResultsScreen.uasset
Binary file not shown.
Binary file modified Game/Content/UI/Blueprints/Scores/BP_ScoreTableWidget.uasset
Binary file not shown.
Binary file modified Game/Content/UI/Blueprints/Scores/BP_TeamScoreTable.uasset
Binary file not shown.
Binary file modified Game/Content/VFX/BP_BulletTracer.uasset
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
// Copyright (c) Improbable Worlds Ltd, All Rights Reserved

#include "Characters/Components/HealthComponent.h"

#include "GameFramework/Pawn.h"
#include "Net/UnrealNetwork.h"
#include "Runtime/Launch/Resources/Version.h"

#include "Controllers/Components/ControllerEventsComponent.h"
#include "Game/Components/ScorePublisher.h"
#include "GameFramework/Pawn.h"
#include "Characters/Components/TeamComponent.h"
#include "Net/UnrealNetwork.h"

UHealthComponent::UHealthComponent()
{
Expand Down Expand Up @@ -79,7 +82,11 @@ void UHealthComponent::TakeDamage(float Damage, const FDamageEvent& DamageEvent,
APlayerState* InstigatorPlayerState = EventInstigator->PlayerState;
if (InstigatorPlayerState != nullptr)
{
#if ENGINE_MINOR_VERSION <= 24
InstigatorPlayerId = InstigatorPlayerState->PlayerId;
#else
InstigatorPlayerId = InstigatorPlayerState->GetPlayerId();
#endif
if (const UTeamComponent* TeamComponent = InstigatorPlayerState->FindComponentByClass<UTeamComponent>())
{
InstigatorTeamId = TeamComponent->GetTeam();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
// Copyright (c) Improbable Worlds Ltd, All Rights Reserved

#include "Controllers/Components/ControllerEventsComponent.h"

#include "GameFramework/Controller.h"
#include "GameFramework/PlayerState.h"

#include "Runtime/Launch/Resources/Version.h"

UControllerEventsComponent::UControllerEventsComponent()
{
Expand All @@ -19,7 +20,11 @@ void UControllerEventsComponent::Death_Implementation(const AController* Killer)
APlayerState* KillerPlayerState = Killer->PlayerState;
if (KillerPlayerState != nullptr)
{
#if ENGINE_MINOR_VERSION <= 24
ClientInformOfDeath(KillerPlayerState->GetPlayerName(), KillerPlayerState->PlayerId);
#else
ClientInformOfDeath(KillerPlayerState->GetPlayerName(), KillerPlayerState->GetPlayerId());
#endif
}
else
{
Expand All @@ -37,7 +42,11 @@ void UControllerEventsComponent::Kill_Implementation(const AController* Victim)
APlayerState* VictimPlayerState = Victim->PlayerState;
if (VictimPlayerState != nullptr)
{
#if ENGINE_MINOR_VERSION <= 24
ClientInformOfKill(VictimPlayerState->GetPlayerName(), VictimPlayerState->PlayerId);
#else
ClientInformOfKill(VictimPlayerState->GetPlayerName(), VictimPlayerState->GetPlayerId());
#endif
}
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
// Copyright (c) Improbable Worlds Ltd, All Rights Reserved

#include "Game/Components/DeathmatchScoreComponent.h"

#include "Net/UnrealNetwork.h"
#include "Runtime/Launch/Resources/Version.h"

UDeathmatchScoreComponent::UDeathmatchScoreComponent()
{
Expand All @@ -18,10 +20,16 @@ void UDeathmatchScoreComponent::GetLifetimeReplicatedProps(TArray<FLifetimePrope

void UDeathmatchScoreComponent::RecordNewPlayer(APlayerState* PlayerState)
{
if (!PlayerScoreMap.Contains(PlayerState->PlayerId))
#if ENGINE_MINOR_VERSION <= 24
const int32 NewPlayerId = PlayerState->PlayerId;
#else
const int32 NewPlayerId = PlayerState->GetPlayerId();
#endif

if (!PlayerScoreMap.Contains(NewPlayerId))
{
FPlayerScore NewPlayerScore;
NewPlayerScore.PlayerId = PlayerState->PlayerId;
NewPlayerScore.PlayerId = NewPlayerId;
NewPlayerScore.PlayerName = PlayerState->GetPlayerName();
NewPlayerScore.Kills = 0;
NewPlayerScore.Deaths = 0;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
// Copyright (c) Improbable Worlds Ltd, All Rights Reserved


#include "Game/Components/TeamDeathmatchScoreComponent.h"

#include "Net/UnrealNetwork.h"
#include "Runtime/Launch/Resources/Version.h"

#include "Characters/Components/TeamComponent.h"

UTeamDeathmatchScoreComponent::UTeamDeathmatchScoreComponent()
Expand All @@ -29,12 +31,18 @@ void UTeamDeathmatchScoreComponent::SetTeamScores(TArray<FTeamScore> InitialTeam

void UTeamDeathmatchScoreComponent::RecordNewPlayer(APlayerState* PlayerState)
{
if (!PlayerScoreMap.Contains(PlayerState->PlayerId))
#if ENGINE_MINOR_VERSION <= 24
const int32 NewPlayerId = PlayerState->PlayerId;
#else
const int32 NewPlayerId = PlayerState->GetPlayerId();
#endif

if (!PlayerScoreMap.Contains(NewPlayerId))
{
if (const UTeamComponent* TeamComponent = PlayerState->FindComponentByClass<UTeamComponent>())
{
FPlayerScore NewPlayerScore;
NewPlayerScore.PlayerId = PlayerState->PlayerId;
NewPlayerScore.PlayerId = NewPlayerId;
NewPlayerScore.PlayerName = PlayerState->GetPlayerName();
NewPlayerScore.Kills = 0;
NewPlayerScore.Deaths = 0;
Expand Down Expand Up @@ -70,15 +78,21 @@ void UTeamDeathmatchScoreComponent::RecordNewPlayer(APlayerState* PlayerState)

void UTeamDeathmatchScoreComponent::RemovePlayer(APlayerState* PlayerState)
{
if (PlayerScoreMap.Contains(PlayerState->PlayerId))
#if ENGINE_MINOR_VERSION <= 24
const int32 RemovedPlayerId = PlayerState->PlayerId;
#else
const int32 RemovedPlayerId = PlayerState->GetPlayerId();
#endif

if (PlayerScoreMap.Contains(RemovedPlayerId))
{
if (const UTeamComponent* TeamComponent = PlayerState->FindComponentByClass<UTeamComponent>())
{
const uint8 TeamId = TeamComponent->GetTeam().GetId();
if (TeamScoreMap.Contains(TeamId))
{
TArray<FPlayerScore>* PlayerScores = &TeamScoreArray[TeamScoreMap[TeamId]].PlayerScores;
PlayerScores->RemoveAt(PlayerScoreMap[PlayerState->PlayerId]);
PlayerScores->RemoveAt(PlayerScoreMap[RemovedPlayerId]);
for (int i = 0; i < PlayerScores->Num(); i++)
{
int32 PlayerId = (*PlayerScores)[i].PlayerId;
Expand All @@ -87,23 +101,29 @@ void UTeamDeathmatchScoreComponent::RemovePlayer(APlayerState* PlayerState)
}
}

PlayerScoreMap.Remove(PlayerState->PlayerId);
PlayerScoreMap.Remove(RemovedPlayerId);
}
}

void UTeamDeathmatchScoreComponent::RecordKill(APlayerState* KillerState, APlayerState* VictimState)
{
if (PlayerScoreMap.Contains(KillerState->PlayerId))
#if ENGINE_MINOR_VERSION <= 24
const int32 KillerId = KillerState->PlayerId;
const int32 VictimId = VictimState->PlayerId;
#else
const int32 KillerId = KillerState->GetPlayerId();
const int32 VictimId = VictimState->GetPlayerId();
#endif

if (PlayerScoreMap.Contains(KillerId))
{
const int32 KillerId = KillerState->PlayerId;
const uint8 KillerTeamId = KillerState->FindComponentByClass<UTeamComponent>()->GetTeam().GetId();

++TeamScoreArray[TeamScoreMap[KillerTeamId]].PlayerScores[PlayerScoreMap[KillerId]].Kills;
}

if (PlayerScoreMap.Contains(VictimState->PlayerId))
if (PlayerScoreMap.Contains(VictimId))
{
const int32 VictimId = VictimState->PlayerId;
const uint8 VictimTeamId = VictimState->FindComponentByClass<UTeamComponent>()->GetTeam().GetId();

++TeamScoreArray[TeamScoreMap[VictimTeamId]].PlayerScores[PlayerScoreMap[VictimId]].Deaths;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,12 @@ void UTeamDeathmatchSpawnerComponent::SetTeams(TArray<FGenericTeamId> TeamIds)

void UTeamDeathmatchSpawnerComponent::RequestSpawn(APlayerController* Controller)
{
if (TeamAssignments.Num() == 0)
{
UE_LOG(LogTeamDeathmatchSpawnerComponent, Error, TEXT("Requested spawn but Spawner component hasn't been initialized! Controller: %s"), *GetNameSafe(Controller));
return;
}

int32 TeamId = -1;
if (SpawnedPlayers.Contains(Controller))
{
Expand Down
2 changes: 1 addition & 1 deletion UnrealGDKVersion.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.10.0
0.11.0
3 changes: 2 additions & 1 deletion ci/nightly.template.steps.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ windows: &windows
- "permission_set=builder"
- "platform=windows"
- "scaler_version=2"
- "queue=${CI_WINDOWS_BUILDER_QUEUE:-v4-20-03-26-102432-bk9951-8afe0ffb}"
- "queue=${CI_WINDOWS_BUILDER_QUEUE:-v4-20-07-20-102655-bk13456-70b30abf-d}"
- "boot_disk_size_gb=500"
timeout_in_minutes: 60 # TODO(ENG-548): reduce timeout once agent-cold-start is optimised.
retry:
Expand Down Expand Up @@ -63,3 +63,4 @@ steps:
STEP_NUMBER: "${STEP_NUMBER}"
GDK_BRANCH: "${GDK_BRANCH}"
UE-SharedDataCachePath: "\\\\gdk-for-unreal-cache.${CI_ENVIRONMENT}-intinf-eu1.i8e.io\\samba\\ddc"
NDKROOT: "c:/Android/android-ndk-r21d"
13 changes: 7 additions & 6 deletions ci/setup-and-build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,9 @@ pushd "$exampleproject_home"
"GDKShooter", `
"Win64", `
"Development", `
"GDKShooter.uproject"
)
"GDKShooter.uproject", `
"-nocompile"
)
$build_client_handle = $build_client_proc.Handle
Wait-Process -InputObject $build_client_proc
if ($build_client_proc.ExitCode -ne 0) {
Expand All @@ -148,8 +149,9 @@ pushd "$exampleproject_home"
"GDKShooterServer", `
"Linux", `
"Development", `
"GDKShooter.uproject"
)
"GDKShooter.uproject", `
"-nocompile"
)
$build_server_handle = $build_server_proc.Handle
Wait-Process -InputObject $build_server_proc

Expand Down Expand Up @@ -180,8 +182,7 @@ pushd "$exampleproject_home"
"-targetplatform=Android", `
"-cookflavor=Multi", `
"-build", `
"-utf8output", `
"-compile"
"-utf8output"
)

$build_server_handle = $build_server_proc.Handle
Expand Down
57 changes: 0 additions & 57 deletions spatial/default_launch.json

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
"${IMPROBABLE_WORKER_ID}",
"coordinator_start_delay_millis=10000",

"connect.to.spatialos",
"127.0.0.1",
"+workerType",
"UnrealClient",
"+deployment",
Expand Down

0 comments on commit d383ce3

Please sign in to comment.