diff options
author | Reid <reidyaro@gmail.com> | 2016-01-17 02:34:58 +0100 |
---|---|---|
committer | Reid <reidyaro@gmail.com> | 2016-01-17 02:37:29 +0100 |
commit | 150bff5ebcf8118bbcc48d0db9fab73f01cedc7d (patch) | |
tree | 28476f01e00aa81a0a36037360d50beb4855da86 /npc/functions | |
parent | f4a01a496b1787f9eb4146023d98104f13d304ba (diff) | |
download | serverdata-150bff5ebcf8118bbcc48d0db9fab73f01cedc7d.tar.gz serverdata-150bff5ebcf8118bbcc48d0db9fab73f01cedc7d.tar.bz2 serverdata-150bff5ebcf8118bbcc48d0db9fab73f01cedc7d.tar.xz serverdata-150bff5ebcf8118bbcc48d0db9fab73f01cedc7d.zip |
Add else if instead of many if on asleep function.
Diffstat (limited to 'npc/functions')
-rw-r--r-- | npc/functions/asleep.txt | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/npc/functions/asleep.txt b/npc/functions/asleep.txt index 35a6f5c4..0f981148 100644 --- a/npc/functions/asleep.txt +++ b/npc/functions/asleep.txt @@ -8,12 +8,14 @@ // .@rand = Random number between the number of "sleeping" choice. function script asleep { + closedialog; - .@rand = rand(3); + .@rand = rand(5); if (.@rand == 0) npctalk3 l("Zzzzzzzzz..."); - if (.@rand == 1) npctalk3 l("Rrrr... Pchhhh..."); - if (.@rand == 2) npctalk3 l("Ggrmm... Grmmmm..."); - if (.@rand == 3) npctalk3 l("Hm..."); + else if (.@rand == 1) npctalk3 l("Rrrr... Pchhhh..."); + else if (.@rand == 2) npctalk3 l("Ggrmm... Grmmmm..."); + else if (.@rand == 3) npctalk3 l("Hm..."); + else emotion 105; // Sleepy close; } |