Get it on the marketplace: By Hyper
🔥Join the Hyper gaming and development Discord Channel for generic chat and support! Would love to speak to you there.}
The ultimate survival character:
It includes a fully networked survival character with advanced logic such as:
Base player stats:
Health
The character has a health variable. This is the most important one.
The health is affected by damage events.
For instance: Fall, hunger, thirst, no air, etc.
When the health is zero, the charachter will collapse and a die sound is spawned
when the character is very close to dieing, a very low health sound is spawned. In this case a fast heartbeat.
Also a blood splatter screen animation is included. On event damage the blood splatter is activated.
For generic damage events, the armor will decrease first
The character has the option to enable or disable health regeneration.
The amount of regen is determined by the: VariableHealthRegenerationRate
When health is at max, the logic will not be excecated.
Also, when the actor is receiving damage, the health is not regenerated for a couple of seconds
Armor
The character has armor.
The armor is substracted on event damage.
However, the armor is not substracted on certain damage types such as:
Hunger damage
Thirst Damage
Out of Air Damage
Fall Damage
If the armor is zero, a armor break sound is spawned.
If there is no armor on the char, the UI will adapt
Hunger
The character has hunger logic.
The hunger decreases over time by a consumption rate variable.
When the hunger is in low range, a stomach growling sound is spawned.
When the hunger is at zero, damage will be applied to the health, not the armor.
Thirst
The character has thirst logic.
The thirst decreases over time by a consumption rate variable.
When the thirst is in low range, a stomach growling sound is spawned.
When the thirst is at zero, damage will be applied to the health, not the armor.
Energy
The character included energy logic.
You can sprint with shift. Sprinting consumes energy.
The sprint speed is lerped to the max speed and also reversed via timeline.
You can jump with spacebar. Jumping consumes energy.
Jumping spawns a jump sound.
When the energy is in low range, you can’t jump or sprint.
The char will automatically stop sprinting when is zero.
The energy has a regeneration rate variable.
When the energy is in low range, an out of breath sound is spawned.
Oxygen
The character has an Oxygen variable.
This can be used for: under water, but also for “space survival“
Only when oxygen is consumed the UI will show the oxygen bar based on an animation
The consuming of oxygen is triggered by a variable: Consuming oxygen bool.
When the Air is low, an out of breath sound is spawned (gasping).
When air is regained a regaining sound is spawned
When oxygen is zero, apply damage only to health, not armor.
Generic Penalty system:
This pack includes a generic penalty system. You can easily apply penalties to all stats based on health, temperature or from a pickup e.g.
Rotten Fish
Alchohol
Health states (Including post process and screen effects):
Sick: Bad stats, slowly recovering
Healthy: Normal Stats
Infection: Need medecine, bad stats and slowly dieing
Wounded: bad stats but slowly restoring. Small chance of infection if not attended
Poisoned: random chance of recovering. Antidote helps to restore.
Drunk: Temp dizzy screen, more hunger and thirst. A bit more energy
Temperature states:
Very cold: Bad stats and small amount of damage
Cold: Bad stats, faster hunger
Normal
Hot: Bad stats, faster thirst
Very hot: Bad stats and small amount of damage
Based on “external temperature“, the temperature state is switched.
Be aware, the character also has a “Chill“ temperature.
The chill temperature can differ per character.
This is depended on a chill temp penalty.
The penalty is determined by e.g. clothing, if is wet, or near a fire and warmed.
Each state has a screen animation effect.
Misc States:
This affects the chill temperature of the individual.
Wet: When in rain or just out of water. Faster cold
Warming: Near a fire, faster not wet AND faster too hot and less fast too cold
On Fire: Fire particle dying not wet
Weather based temperature support:
Possible to integrate with a weather plugin.
The weather system should include a temperature variable.
To set temperature state in the char: Call the “Set Temperature State based on external temperature“ event
In the weather system you want to set temperature depended on season (spring, summer, autumn, winter)
Depended on time of day (Morning, afternoon, evening, night)
Character logic:
Sprint, Run and Walk:
Switch between Run and walk with Tab
Enable sprint with left shift.
Fall damage: