diff options
author | Jesusaves <cpntb1@ymail.com> | 2021-04-09 13:33:57 -0300 |
---|---|---|
committer | Jesusaves <cpntb1@ymail.com> | 2021-04-09 13:33:57 -0300 |
commit | cf18ce071c79ae37e14ea38943e0b1d88da70a7b (patch) | |
tree | f9159c9b60b3018300dd22ffba0d797bc5e828e5 /npc/functions/questgen.txt | |
parent | 8a4bf716002a017de77fe7df301ef8e4aaf00a2e (diff) | |
download | serverdata-cf18ce071c79ae37e14ea38943e0b1d88da70a7b.tar.gz serverdata-cf18ce071c79ae37e14ea38943e0b1d88da70a7b.tar.bz2 serverdata-cf18ce071c79ae37e14ea38943e0b1d88da70a7b.tar.xz serverdata-cf18ce071c79ae37e14ea38943e0b1d88da70a7b.zip |
Override
Diffstat (limited to 'npc/functions/questgen.txt')
-rw-r--r-- | npc/functions/questgen.txt | 38 |
1 files changed, 0 insertions, 38 deletions
diff --git a/npc/functions/questgen.txt b/npc/functions/questgen.txt deleted file mode 100644 index 285924cb..00000000 --- a/npc/functions/questgen.txt +++ /dev/null @@ -1,38 +0,0 @@ -// Evol functions. -// Authors: -// monwarez -// Reid -// Description: -// Generate a random quest type and location. -// Variables: -// @quests : 2D array containing quest type and location availability -// with @nb_type rows and @nb_location columns. -// boolean value determine if the connection is possible between -// the quest type and location selected. -// @nb_difficulty : difficulty value from 0 to N-1. -// Argument: -// 0 : quest type -// 1 : quest location -// 2 : quest difficulty -// Return : Tridimentional array value; - -function script questgen { - - .@argc = getargcount(); - @q_type = getarg(0, rand(@nb_type * 10) / 10); - - do - { - @q_location = getarg(1, rand(@nb_location * 10) / 10); - .@cell = @q_type * @nb_location + @q_location; - - if (!@quests[.@cell] && .@argc >= 2) - { - return false; - } - } while (!@quests[.@cell]); - - @q_difficulty = getarg(2, rand(@nb_difficulty * 10) / 10); - - return true; -} |