Skip to content

Latest commit

 

History

History
109 lines (107 loc) · 5.27 KB

design.org

File metadata and controls

109 lines (107 loc) · 5.27 KB

Design

Overall Design

World

The world within the game is separated into sections of differing scale:

Overworld

The largest scale map (hence only the largest scale features show, and the characters within the map are the smallest scale). The overworld scale is approximately such that the characters are only 3 blocks tall. The overworld is also potentially unbounded - meaning at this scale the player can go anywhere and it is not a fixed camera. While travelling around the overworld, the player may find places (towns, caves, points of interest) which can be entered - then taking the player into a fixed local map of lower scale (smaller scale features show).

Local Map

The local map consists of a subset of the map, with bounded extents and in which the player character is approximately double the size (5-8 blocks tall). Within this map, the player may find places (houses, cave rooms, etc.) which can be entered - then taking the player into a fixed interior map of lower scale (smaller scale features show).

Interiors

The interior map is the smallest scale map (smallest features show) and is reserved for when the player needs to interact with / see very fine features. It usually represents the interior of houses, cave rooms, and potentially very specific points of interest within a map (e.g. under a bridge).

NPCs

All NPCs have some basic characteristics, stats, and behaviors:

  • Goal points with path planning
  • Health, Stamina, Fear, Magic, Status(es)
  • Item & Environment interaction
  • Equipment / items / Droppables
  • Interaction with other NPCs and player character
  • Possessable: they can be controllable by other characters / players

NPCs can come in a variety of types with different customizations between them:

Animals

Animals are NPCs which randomly wander around, may forage for food, can be killed for food, and can be frightened (by player or other NPCs). They can additionally be interacted with by the player in various ways (e.g. feeding, petting, etc.)

Friendlies

Foes

Neutrals

Systems

Inventory

Foliage System

Items

Interactible (chests, doors, etc.)

Exposes:

  • `PrimaryInteract()`
  • `SecondaryInteract()`

Foragable Item (mushrooms, plants, rocks, etc.)

Spawned into the world from an interaction with the world (e.g. hitting a rock with an axe) or may already exist within the world (e.g. if it is part of the Foliage System)

Disappears from the world when `PrimaryInteract()` is called and is then placed into the Inventory of the interaction instigator.

Droppable Item (health, meat, weapons, armor, etc.)

Can be any item which in the Inventory system and therefore can be placed back into the world. This contains the set of Foragable Item, Equippable Item, and others.

Equippable Item (weapons, torches, etc.)

Can be placed onto the bone of a pawn (e.g. NPC, player) and may optionally implement the Interactible interface.

Weapon

Projectile

Status Effects

In-world / Area of Effects (weather, spell, etc.)

Applied (buff, drain, etc.)

Class / Actor Hierarchy

Character (ACharacter)

InteractionComponent (UActorComponent)

AttributeComponent (UActorComponent)

EquipmentComponent (UActorComponent)

TArray<FName> ArmorSocketNames
TArray<FName> WeaponSocketNames
TMap<FName, AWotEquippedArmor> ArmorItems
TMap<FName, AWotEquippedWeapon> WeaponItems

Determines which of the Items in the character’s InventoryComponent are actually equipped. Provides interfaces for getting the defense stats of the player (based on all equipped armor), as well as the equipped weapon for performing attacks using the weapon.

InventoryComponent (UActorComponent)

TArray<UWotItem> Items (UObject)

DeathEffectComponent (UActorComponent)

Item (AActor)

ItemEquipment (WotItem)

ItemWeapon (WotItemEquipment)
ItemArmor (WotItemEquipment)

ItemInteractible (AActor)

Item (UWotItem)

Mesh (UStaticMeshComponent)

Projectile (AActor)

ArrowProjectile (WotProjectile)

TSubclassOf<UWotItem> ItemClass

ItemActor (AActor)

Item (UWotItem)

Mesh (UStaticMeshComponent)

Contains the item and renderable mesh. Implements SetItem() which will configure the mesh component to render the item’s static mesh.

InteractibleItemActor (ItemActor, IWotGameplayInterface)

EquippedArmor (ItemActor)

Implements GetDefense(), GetWear(), ApplyWear(), etc.

EquippedWeapon (ItemActor)

Implements PrimaryAttackStart, PrimaryAttackStop, SecondaryAttackStart, SecondaryAttackStop to allow owning player pawn to generically pass those events to the weapon to handle them. Held by the EquipmentComponent.