• Tutorials

  • Home
  • GPDL $RANDOM

    DungeonCraft Help Home

    $RANDOM(Max);

    Returns a random integer less than Max. For example, to roll a 6-sided die you might do the following:

    n=$nPLUS($RANDOM(6),1));

    $RANDOM returns a number between 0 and 5 and adding 1 makes it between 1 and 6.