Add new game object type Location #64

Closed
opened 2017-01-09 19:02:06 +01:00 by nik · 3 comments
nik commented 2017-01-09 19:02:06 +01:00 (Migrated from edugit.org)

Add a new game object type Location that can be used for, e.g., a shop or some kind. It can be placed on the map and interacted with, much like an NPC, but a dead spot that simply enables action on a loction.

Add a new game object type Location that can be used for, e.g., a shop or some kind. It can be placed on the map and interacted with, much like an NPC, but a dead spot that simply enables action on a loction.
nik commented 2017-01-09 20:32:29 +01:00 (Migrated from edugit.org)

@Creeparoo what do you think?

@Creeparoo what do you think?
nik commented 2017-02-15 14:27:52 +01:00 (Migrated from edugit.org)

A few design notes:

  • Location is a new GameObject subclass
  • It has a spawn_latlon or spawn_osm but exists only exactly once at the latlon or any such OSM object
  • A nearby location is detected on position update of the player
  • It is up to the game to decide whether anything is done, so on_pass (or whatever you name it) is always called as long as the player is within the defined distance of the location
  • isonmap always returns False for locations
A few design notes: * Location is a new GameObject subclass * It has a spawn_latlon or spawn_osm but exists only exactly once at the latlon or any such OSM object * A nearby location is detected on position update of the player * It is up to the game to decide whether anything is done, so on_pass (or whatever you name it) is always called as long as the player is within the defined distance of the location * isonmap always returns False for locations
nik commented 2017-02-15 18:49:49 +01:00 (Migrated from edugit.org)

Implementation in feature-location seems complete. Need to fix a bug in spawn_default(), though.

Implementation in `feature-location` seems complete. Need to fix a bug in `spawn_default()`, though.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
nik/veripeditus-server#64
No description provided.