exit

package
v0.9.9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 4, 2026 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DirectionDeltas = map[string][3]int{
	"north":     {0, -1, 0},
	"south":     {0, 1, 0},
	"west":      {-1, 0, 0},
	"east":      {1, 0, 0},
	"northwest": {-1, -1, 0},
	"northeast": {1, -1, 0},
	"southwest": {-1, 1, 0},
	"southeast": {1, 1, 0},
	"down":      {0, 0, -1},
	"up":        {0, 0, 1},

	"north-x2":     {0, -2, 0},
	"south-x2":     {0, 2, 0},
	"west-x2":      {-2, 0, 0},
	"east-x2":      {2, 0, 0},
	"northwest-x2": {-2, -2, 0},
	"northeast-x2": {2, -2, 0},
	"southwest-x2": {-2, 2, 0},
	"southeast-x2": {2, 2, 0},

	"north-x3":     {0, -3, 0},
	"south-x3":     {0, 3, 0},
	"west-x3":      {-3, 0, 0},
	"east-x3":      {3, 0, 0},
	"northwest-x3": {-3, -3, 0},
	"northeast-x3": {3, -3, 0},
	"southwest-x3": {-3, 3, 0},
	"southeast-x3": {3, 3, 0},

	"north-gap":     {0, -1, 0},
	"south-gap":     {0, 1, 0},
	"west-gap":      {-1, 0, 0},
	"east-gap":      {1, 0, 0},
	"northwest-gap": {-1, -1, 0},
	"northeast-gap": {1, -1, 0},
	"southwest-gap": {-1, 1, 0},
	"southeast-gap": {1, 1, 0},

	"north-gap2":     {0, -2, 0},
	"south-gap2":     {0, 2, 0},
	"west-gap2":      {-2, 0, 0},
	"east-gap2":      {2, 0, 0},
	"northwest-gap2": {-2, -2, 0},
	"northeast-gap2": {2, -2, 0},
	"southwest-gap2": {-2, 2, 0},
	"southeast-gap2": {2, 2, 0},

	"north-gap3":     {0, -3, 0},
	"south-gap3":     {0, 3, 0},
	"west-gap3":      {-3, 0, 0},
	"east-gap3":      {3, 0, 0},
	"northwest-gap3": {-3, -3, 0},
	"northeast-gap3": {3, -3, 0},
	"southwest-gap3": {-3, 3, 0},
	"southeast-gap3": {3, 3, 0},
}

Functions

func GetDelta added in v0.9.8

func GetDelta(exitName string) (x, y, z int)

func IsCompassDirection added in v0.9.8

func IsCompassDirection(exitName string) bool

func IsDirectionalExit added in v0.9.8

func IsDirectionalExit(exitName string) bool

Types

type RoomExit

type RoomExit struct {
	RoomId       int
	Secret       bool          `yaml:"secret,omitempty"`
	MapDirection string        `yaml:"mapdirection,omitempty"` // Optionaly indicate the direction of this exit for mapping purposes
	ExitMessage  string        `yaml:"exitmessage,omitempty"`  // If set, this message is sent to the user, followed by a delay, before they actually go through the exit.
	Lock         gamelock.Lock `yaml:"lock,omitempty"`         // 0 - no lock. greater than zero = difficulty to unlock.
}

func (RoomExit) HasLock

func (re RoomExit) HasLock() bool

type TemporaryRoomExit

type TemporaryRoomExit struct {
	RoomId       int    // Where does it lead to?
	Title        string // Does this exit have a special title?
	UserId       int    // Who created it?
	SpawnedRound uint64 `yaml:"-"` // When the temp exit was created
	Expires      string // When will it be auto-cleaned up?
}

There is a magic portal of Chuckles, magic portal of Henry here! There is a magical hole in the east wall here!

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL