From 5060c66738898913ca880d83b0fdcd5be2e0b59d Mon Sep 17 00:00:00 2001 From: Joel Kronqvist Date: Sun, 17 Nov 2024 14:19:58 +0200 Subject: Small style fixes (mostly shortening comment lines written by others...) --- src/scalevalapokalypsi/Model/Adventure.scala | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) (limited to 'src/scalevalapokalypsi/Model/Adventure.scala') diff --git a/src/scalevalapokalypsi/Model/Adventure.scala b/src/scalevalapokalypsi/Model/Adventure.scala index 2bf6cfe..e751280 100644 --- a/src/scalevalapokalypsi/Model/Adventure.scala +++ b/src/scalevalapokalypsi/Model/Adventure.scala @@ -1,15 +1,17 @@ package scalevalapokalypsi.Model import scala.collection.mutable.Map +import scalevalapokalypsi.Model.Entities.* -/** The class `Adventure` represents text adventure games. An adventure consists of a player and - * a number of areas that make up the game world. It provides methods for playing the game one - * turn at a time and for checking the state of the game. +/** The class `Adventure` holds data of the game world and provides methods + * for implementing a user interface for it. * - * N.B. This version of the class has a lot of “hard-coded” information that pertains to a very - * specific adventure game that involves a small trip through a twisted forest. All newly created - * instances of class `Adventure` are identical to each other. To create other kinds of adventure - * games, you will need to modify or replace the source code of this class. */ + * Data about the game world includes remote players, other entities and areas. + * The methods are documented below. + * + * @param playerNames a vector of the names of players to create and add + * to the adventure straight away + */ class Adventure(val playerNames: Vector[String]): private val middle = Area("Forest", "You are somewhere in the forest. There are a lot of trees here.\nBirds are singing.") -- cgit v1.2.3