indigoextras.jobs

Members list

Type members

Classlikes

trait Job extends Product, Serializable

A trait that when extended represents a job that can be done. Jobs have names and can be local to the worker, or globalablly available

A trait that when extended represents a job that can be done. Jobs have names and can be local to the worker, or globalablly available

Attributes

Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
final case class JobMarket(id: SubSystemId, availableJobs: List[Job]) extends SubSystem

The JobMarket is a subsystem that manages a global pool of available jobs.

The JobMarket is a subsystem that manages a global pool of available jobs.

Not all jobs are available to all workers however.

All interaction with the job market is done by a series of events.

Value parameters

availableJobs

Jobs currently available for allocation to workers.

Attributes

Companion
object
Supertypes
trait Serializable
trait Product
trait Equals
trait SubSystem
class Object
trait Matchable
class Any
Show all
object JobMarket

Attributes

Companion
class
Supertypes
trait Product
trait Mirror
class Object
trait Matchable
class Any
Self type
JobMarket.type
sealed trait JobMarketEvent extends GlobalEvent, Product, Serializable

Events that are used to manage the JobMarket

Events that are used to manage the JobMarket

Attributes

Companion
object
Supertypes
trait Serializable
trait Product
trait Equals
trait GlobalEvent
class Object
trait Matchable
class Any
Show all
Known subtypes
class Allocate
class Find
class NothingFound
class Post

Attributes

Companion
trait
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
object JobName

Attributes

Supertypes
class Object
trait Matchable
class Any
Self type
JobName.type
final case class WorkContext[Actor, Context](gameTime: GameTime, dice: Dice, actor: Actor, context: Context)

The context the work is being done in, similar to frame context, work is not done in a vacuum.

The context the work is being done in, similar to frame context, work is not done in a vacuum.

Value parameters

actor

An instance of the actor, for asking question like "Can the actor do the work?"

context

A free form type, e.g.: A list of other characters the worker can see.

dice

A dice for random number generation.

gameTime

The supplied game time.

Attributes

Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
final case class WorkProgressReport[Actor, Context](workSchedule: WorkSchedule[Actor, Context], actor: Actor)

Encapsulates an updated schedule and an updated actor. Work is done by workers, but work can also affect workers, e.g. making them stronger, smarter, or tired.

Encapsulates an updated schedule and an updated actor. Work is done by workers, but work can also affect workers, e.g. making them stronger, smarter, or tired.

Value parameters

actor

The updated actor.

workSchedule

The updated work schedule.

Attributes

Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
final case class WorkSchedule[Actor, Context](id: BindingKey, worker: Worker[Actor, Context], jobStack: List[Job])

Represents an Actor's work schedule

Represents an Actor's work schedule

Attributes

Companion
object
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
object WorkSchedule

Attributes

Companion
class
Supertypes
trait Product
trait Mirror
class Object
trait Matchable
class Any
Self type
trait Worker[Actor, Context]

Represents a Worker for a given Actor

Represents a Worker for a given Actor

Attributes

Companion
object
Supertypes
class Object
trait Matchable
class Any
object Worker

Attributes

Companion
trait
Supertypes
class Object
trait Matchable
class Any
Self type
Worker.type

Types

opaque type JobName

A simple type to distingush job names from other strings.

A simple type to distingush job names from other strings.

Value parameters

value

the name of the job

Attributes