adding resources
This commit is contained in:
@@ -13,9 +13,16 @@ Tracks hex locations for the territory map.
|
||||
- `GET /api/locations/visible` Get locations visible to the authenticated user.
|
||||
- `GET /api/locations/visible?depth=3` Override visibility depth for a request.
|
||||
- `PUT /api/locations` Upsert location data (SUPER only).
|
||||
- `GET /api/resources/me` Get the authenticated player's resources.
|
||||
|
||||
`claim` and `put` require the same JWT issued by AuthApi.
|
||||
|
||||
When a player gains visibility over previously unseen coordinates, the service
|
||||
generates and persists those locations before returning them. Generated visible
|
||||
locations are unowned `Open` records until claimed by a player.
|
||||
|
||||
## Resources
|
||||
|
||||
Player resource state is stored server-side in the `PlayerResources` collection.
|
||||
New players start with 100 gold. A player's headquarters generates 10 gold per
|
||||
minute. Generation is applied lazily when the resource record is read.
|
||||
|
||||
Reference in New Issue
Block a user