Lost Souls directory structure

From LSWiki

(Difference between revisions)
Jump to: navigation, search
Revision as of 05:38, 17 January 2007 (edit)
Chaos (Talk | contribs)
(/daemon)
← Previous diff
Revision as of 05:39, 17 January 2007 (edit)
Chaos (Talk | contribs)
(/daemon)
Next diff →
Line 29: Line 29:
''Twilight writes:'' This is where daemons are. What are daemons you ask? Good question. Basically I think they are objects that control, handle, and store data. Right? ''Twilight writes:'' This is where daemons are. What are daemons you ask? Good question. Basically I think they are objects that control, handle, and store data. Right?
-''Chaos responds:'' Something like that. Our daemons are probably best understood by reference to Unix system daemons, which are programs that run continuously (usually) and handle some particular task; the most popular daemon is the HTTP daemon, or web server. Our daemons are similar: they're objects that hang out and handle some particular function. ''/daemon/armour'' manages the armour subsystem, tracking the armour type and armour style definitions; ''/daemon/weapons'' manages the weapon subsystem, tracking weapon types, weapon sizes, and ammunition types. These are examples of a class of daemon called '''broker daemons''' because their main function is handling definition objects and brokering requests for them; they're mainly found in /daemon. '''Control daemons''' are another major class; these live in the /dmn directories of individual projects and serve as central managers for the project. Other daemons just package up some similar functionality, such as ''/daemon/time''; some manage ongoing or specific-purpose processes of the game, such as ''/daemon/cron'', ''/daemon/autoheal'', and ''/daemon/shutdown''.+''Chaos responds:'' Something like that. Our daemons are probably best understood by reference to Unix system daemons, which are programs that run continuously (usually) and handle some particular task; the most popular daemon is the HTTP daemon, or web server. Our daemons are similar: they're objects that hang out and handle some particular function. ''/daemon/armour'' manages the armour subsystem, tracking the armour type and armour style definitions; ''/daemon/weapons'' manages the weapon subsystem, tracking weapon types, weapon sizes, and ammunition types. These are examples of a class of daemon called '''broker daemons''' because their main function is handling definition objects and brokering requests for them; they're mainly found in /daemon. '''Control daemons''' are another major class; these live in the ~Project/dmn directories of individual projects and serve as central managers for the project. Other daemons just package up some similar functionality, such as ''/daemon/time''; some manage ongoing or specific-purpose processes of the game, such as ''/daemon/cron'', ''/daemon/autoheal'', and ''/daemon/shutdown''.
Two of the universal characteristics of daemons is that they are never cloned and they are never in-game items. I can conceive of circumstances that could create an exception to the former, but not the latter. Two of the universal characteristics of daemons is that they are never cloned and they are never in-game items. I can conceive of circumstances that could create an exception to the former, but not the latter.

Revision as of 05:39, 17 January 2007

This structure of this file mirror the LS directory structure. If you don't know how to navigate the directory structure, please read the Developer Primer.

Contents

/d

This is where the world is. The "d" stands for "domain", which apparently used to mean something. Chaos claims that this stands for "deployed", but we all know he's a dirty liar.

Read access privilege: read_d

Write access privilege: write_d

/d/Affiliations

This is where affiliations (associations, guilds, offices, racial and other faculties).

Read access privilege: read_sensitive

Write access privilege: write_sensitive

/d/Almeria

This is where the main map and the main world is, though it's all in subdirectories. Take a look, it should be pretty clear.

/d/System

This is where Bytehaven is, which is an area with a few handy developer bits like the test character register, and the Banishment tablet. There is also a project called Public that has some 'utility' rooms.

/d/Misc

Things that don't belong elsewhere, like projects that are primarily about items (Lzrelekoi) or wandering areas (the Vanishing Tower).

/d/Various

Like Almeria, except not Almeria. Includes placeholders for other continents, some partially functional (/d/Tenochlan), others less so (/d/Arrakis), still others not really at all (/d/Mordor); other sorts of region (/d/Astra, which is meant to contain the Prime plane's outer space); and other planes of existence (/d/Exoma, /d/Umbra, /d/Amber).

/daemon

Twilight writes: This is where daemons are. What are daemons you ask? Good question. Basically I think they are objects that control, handle, and store data. Right?

Chaos responds: Something like that. Our daemons are probably best understood by reference to Unix system daemons, which are programs that run continuously (usually) and handle some particular task; the most popular daemon is the HTTP daemon, or web server. Our daemons are similar: they're objects that hang out and handle some particular function. /daemon/armour manages the armour subsystem, tracking the armour type and armour style definitions; /daemon/weapons manages the weapon subsystem, tracking weapon types, weapon sizes, and ammunition types. These are examples of a class of daemon called broker daemons because their main function is handling definition objects and brokering requests for them; they're mainly found in /daemon. Control daemons are another major class; these live in the ~Project/dmn directories of individual projects and serve as central managers for the project. Other daemons just package up some similar functionality, such as /daemon/time; some manage ongoing or specific-purpose processes of the game, such as /daemon/cron, /daemon/autoheal, and /daemon/shutdown.

Two of the universal characteristics of daemons is that they are never cloned and they are never in-game items. I can conceive of circumstances that could create an exception to the former, but not the latter.

If you need to refer to a daemon that lives in /daemon in code, you will almost always be using the "service" macros for them, defined in /lib/services.h, which look like Daemon_Time, Daemon_Autoheal, Daemon_Shutdown, and so on. Another daemon, /daemon/services, manages these. Besides being prettier than string pathnames, these use a special mechanism to make them faster than other methods you might use for referring to daemons.

Read access privilege: read_lib

Write access privilege: write_lib

/def

This is where definition files reside. Definitions are abstract files that determine certain generic properties of particular files. Races, anatomies, weapon types, damage types, are all examples of things that have definitions.

Read access privilege: read_lib

Write access privilege: write_lib

/etc

A few header files are here, like item.h. This directory is mostly unused and is pretty much on its way out, but the basic idea of it once was that it would container header files that were strongly related to a particular instance of the Ain Soph lib rather than to the core of the lib itself.

Read access privilege: read_lib

Write access privilege: write_lib

/lib

This is the main location for Ain Soph lib header files. Most of the .h files you will ever use are found here. Project header files can usually be found in /d/Almeria/lib, or /d/Affiliations/lib, or something of that sort.

Read access privilege: read_lib

Write access privilege: write_lib

/lib/dev

This is where developer work-in-progress project header files go. It is set up to be writable by ordinary developers. It perpetually is in serious need of cleaning out.

Read access privilege: standard

Write access privilege: standard

/lib/descriptors

This is where the header files that are automatically generated by the descriptor definitions in /def/descriptor are kept. Most header files are manually maintained; these are unusual in being created by the system.

/mod

This hierarchy contains component modules, mainly to be assembled into complete inheritables by things in /std.

Read access privilege: read_lib

Write access privilege: write_lib

/obj

This hierarchy mainly contains files that are intended to be physical objects in the game world; weapons, armour, comestibles, and so on. There are a few special cases.

Read access privilege: read_lib

Write access privilege: write_lib

/obj/extensions

This is where standard system-wide extension objects are kept. Extensions are a way of loading functionality onto objects using attached, subsidiary objects; for instance, all weapon functionality is tracked by a weapon extension. This allows any object to be treated as an improvised weapon if need be.

/obj/interfaces

System-level input dialog interfaces are kept here. These are objects whose purpose is to handle an interactive dialog; the best example is /obj/interfaces/creation.c, which is the character generation interface.

/obj/master

This is where things like the master object and the simul_efun object are kept -- crucial system things.

Read access privilege: read_secure

Write access privilege: write_secure

/pub

This is a public directory hierarchy where files can be exchanged and freely edited, and so on. One interesting subdirectory is /pub/defunct, where we generally put the /w directories of former developers.

Read access privilege: read

Write access privilege: standard

/std

Contains "final product" inheritable and clonable objects. Most of the objects you will use as base inheritables live here: /std/room, /std/item, /std/autonomon, /std/daemon, and so on.

Read access privilege: read_lib

Write access privilege: write_lib

/sys

Contains "system" header files. Generally, these are distinguished from header files that live in /lib by being more strongly related to things in /obj/master (e.g. /sys/security.h), or by being header files provided with the driver rather than defined by the Ain Soph lib (e.g. /sys/lpctypes.h). Two important, possibly poorly placed header files that live here are /sys/config.h, which contains some important lib-level settings, and /sys/master.h, which defines LS_Foo() macros that are mostly for referring to things in /obj.

Read access privilege: read_lib

Write access privilege: write_lib

/tmp

A public directory for temporary files. Files in this directory are cleared out periodically.

Read access privilege: read

Write access privilege: standard

/txt

Contains text files of various kinds.

Read access privilege: standard

Write access privilege: write_lib

/txt/adm

Contains files that control administrative elements of the system, such as the file that defines what permissions are required to read and write these various directories.

Read access privilege: read_lib

Write access privilege: write_secure

/txt/doc

Developer documentation. Documents retrieved by the 'man' command are pulled from this hierarchy. You should work at becoming familiar with the contents of /txt/doc.

Read access privilege: read

Write access privilege: documentation

/txt/help

Player documentation. This one of the (fairly numerous) places that the 'help' command pulls information from.

Read access privilege: read

Write access privilege: documentation

/txt/log

Standard location for system log files. Many of these are quite interesting.

Read access privilege: standard

Write access privilege: write_lib

/txt/log/dev

Standard location for developer log files. The usual filename convention is /txt/log/dev/<name>.<topic>. Your personal error log file is /txt/log/dev/<your_name>.

Read access privilege: read_w for others' files, standard for your files

Write access privilege: write_w for others' files, standard for your files

/txt/web

The lostsouls.org Web site.

Read access privilege: standard

Write access privilege: write_web

/usr

User files, mainly incarnos and kept-item save files, are in this hierarchy.

Read access privilege: player_files

Write access privilege: player_files

/w

This is where developer workspaces go; your personal directory, /w/yourname, is under this hierarchy. Originally the 'w' stood for 'wizard', back when we used such ill-advised terminology for developers, and the whole 'workspace' thing is just so we don't have to change the directory name.

Read access privilege: read_w

Write access privilege: write_w

Personal tools