Complete early roadmap foundation and calendar helpers
This commit is contained in:
@@ -104,13 +104,15 @@ void AAgrarianGamePlayerController::AgrarianSurvival()
|
||||
|
||||
const FAgrarianSurvivalSnapshot& Survival = SurvivalComponent->Survival;
|
||||
ClientMessage(FString::Printf(
|
||||
TEXT("Health %.1f | Stamina %.1f | Hunger %.1f | Thirst %.1f | Temp %.1fC | Injury %.1f"),
|
||||
TEXT("Health %.1f | Stamina %.1f | Exhaustion %.1f | Hunger %.1f | Thirst %.1f | Temp %.1fC | Injury %.1f | Sickness %.1f"),
|
||||
Survival.Health,
|
||||
Survival.Stamina,
|
||||
Survival.Exhaustion,
|
||||
Survival.Hunger,
|
||||
Survival.Thirst,
|
||||
Survival.BodyTemperature,
|
||||
Survival.InjurySeverity));
|
||||
Survival.InjurySeverity,
|
||||
Survival.SicknessSeverity));
|
||||
}
|
||||
|
||||
void AAgrarianGamePlayerController::AgrarianHeal()
|
||||
@@ -167,8 +169,9 @@ void AAgrarianGamePlayerController::ServerAgrarianLoadWorld_Implementation()
|
||||
|
||||
Persistence->RegisterWorldActorClass(TEXT("primitive_shelter"), AAgrarianShelterActor::StaticClass());
|
||||
const UAgrarianSaveGame* SaveGame = Persistence->LoadOrCreateSave();
|
||||
const int32 RestoredPlayerCount = Persistence->RestorePlayers(SaveGame);
|
||||
const int32 RestoredCount = Persistence->RestoreWorldActors(SaveGame);
|
||||
ClientMessage(FString::Printf(TEXT("Agrarian world loaded. Restored actors: %d."), RestoredCount));
|
||||
ClientMessage(FString::Printf(TEXT("Agrarian world loaded. Restored players: %d. Restored actors: %d."), RestoredPlayerCount, RestoredCount));
|
||||
}
|
||||
|
||||
void AAgrarianGamePlayerController::ServerAgrarianHeal_Implementation()
|
||||
@@ -184,6 +187,8 @@ void AAgrarianGamePlayerController::ServerAgrarianHeal_Implementation()
|
||||
SurvivalComponent->RestoreHealth(100.0f);
|
||||
SurvivalComponent->AddFood(100.0f);
|
||||
SurvivalComponent->AddWater(100.0f);
|
||||
SurvivalComponent->ReduceExhaustion(100.0f);
|
||||
SurvivalComponent->ReduceSickness(100.0f);
|
||||
SurvivalComponent->AddWarmth(37.0f - SurvivalComponent->Survival.BodyTemperature);
|
||||
ClientMessage(TEXT("Agrarian survival restored."));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user