User Tools

Site Tools


server:running_the_server:positional_parameters

This is an old revision of the document!


Running The Server : Startup Parameters

When the server is started, it recognizes the following parameters;
most of them have corresponding environment variables .

_say_server_help(){
cat >&1 <<EoI
The server does not recognize --long options.
$CMDNAME -help
Flags:
 -csport <port> Specifies the port to use for the new client/server code.
 -d          Turns on some debugging.
 +d          Turns off debugging (useful if server compiled with debugging
             as default).
 -detach     The server will go in the background, closing all
             connections to the tty.
 -h          Display this information.
 -log <file> Specifies which file to send output to.
             Only has meaning if -detach is specified.
 -mon        Turns on monster debugging.
 -o          Prints out info on what was defined at compile time.
 -s          Display the high-score list.
 -score <name or class> Displays all high scores with matching name/class.
 -v          Print version and contributors.
 -conf       Sets the configuration dir (settings, motd, etc.)
 -data       Sets the lib dir (archetypes, treasures, etc.)
 -local      Read/write local data (hiscore, unique items, etc.)
 -maps       Sets the directory for maps.
 -arch       Sets the archetype file to use.
 -regions    Sets the regions file to use.
 -playerdir  Sets the directory for the player files.
 -templatedir Sets the directory for template generate maps.
 -treasures  Sets the treasures file to use.
 -uniquedir  Sets the unique items/maps directory.
 -tmpdir     Sets the directory for temporary files (mostly maps.)
 -m          Lists out suggested experience for all monsters.
 -m2         Dumps out abilities.
 -m3         Dumps out artifact information.
 -m4         Dumps out spell information.
 -m5         Dumps out skill information.
 -m6         Dumps out race information.
 -m7         Dumps out alchemy information.
 -m8         Dumps out gods information.
 -m9         Dumps out more alchemy information (formula checking).
 -mt <name>  Dumps out list of treasures for a monster.
EoI
exit
}

Running the server

-csport

Syntax : -csport <portnumber>

The default port-number for the crossfire server is 13227 .
If you want to run it for another port, or even want to host multiple instances of the server, then it needs to assign a different port number for each instance that runs.

-detach

-d / +d

-mon

Configurations for the server

-arch

-conf

-data

-local

-log

-maps

-playerdir

-regions

-templatedir

-tmpdir

-treasures

-uniquedir

Requesting information from the server binary

-h

-o

-s

-score

-v

-m

  • -m Lists out suggested experience for all monsters. Output goes to stdout.
    • print_monsters()
    • common/info.c printf(“%-16s|%6” FMT64
  • -m2 Dumps out abilities. Output goes to stdout.
    • dump_abilities()
    • common/info.c printf(“%4d”, op→resist[i]);
  • -m3 Dumps out artifact information. Output is printed to logfile .
    • dump_artifacts
    • common/treasure.c printf(logfile,“Artifact %-30s Dif
  • -m4 Dumps out spell information. Output is printed to stderr.
    • dump_spells()
    • server/spell_util.c fprintf(stderr, ”%s:%s:%s
  • -m5 Dumps out skill information. No Output Possible.
  • :!: NOT functional ! Code hooks are there, but no dump_skills() function.
  • just exit(0);
  • -m6 Dumps out race information. Output goes to stderr.
  • dump_races()
  • server/init.c fprintf(stderr,“\nRACE
  • -m7 Dumps out alchemy information. Output goes to the logfile .
  • dump_alchemy()
  • common/recipe.c fprintf(logfile, “\n Formulae
  • -m8 Dumps out gods information. Output goes to stderr.
  • dump_gods()
  • common/holy.c fprintf(stderr,”GOD: %s\n”,god→name);
  • -m9 Dumps out more alchemy information (formula checking). Output is printed to the logfile .
  • dump_alchemy_costs()
  • common/recipe.c fprintf(logfile, “\n Formulae with %d ingredient%s
  • -mt <name> Dumps out list of treasures for a monster. Output is printed to the logfile .
  • server/init.c, calls dumpvalues = 10
  • init_beforeplay()
  • dump_monster_treasure(settings.dumparg)
  • common/treasure.c fprintf (logfile, “treasures for %s (arch:
server/running_the_server/positional_parameters.1520284306.txt.gz · Last modified: (external edit)

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki