From 1e58ae86ede467ac84248720a89ed5005404a3ea Mon Sep 17 00:00:00 2001 From: Jesusaves Date: Thu, 21 Jun 2018 12:34:43 -0300 Subject: Implode stuff --- npc/commands/kami.txt | 4 +--- npc/commands/wgm.txt | 4 +--- 2 files changed, 2 insertions(+), 6 deletions(-) (limited to 'npc/commands') diff --git a/npc/commands/kami.txt b/npc/commands/kami.txt index c07190796..4cb8964a9 100644 --- a/npc/commands/kami.txt +++ b/npc/commands/kami.txt @@ -16,9 +16,7 @@ OnCall: .@request$ = strcharinfo(0)+": "; - for (.@i = 0; .@i < .@atcmd_numparameters; ++.@i) { - .@request$ += (.@i > 0 ? " " : "") + .@atcmd_parameters$[.@i]; - } + .@request$ += implode(.@atcmd_parameters$, " "); channelmes("#world", .@request$); announce l(.@request$), bc_all|bc_npc; end; diff --git a/npc/commands/wgm.txt b/npc/commands/wgm.txt index d24841546..cbaa95b86 100644 --- a/npc/commands/wgm.txt +++ b/npc/commands/wgm.txt @@ -14,9 +14,7 @@ OnCall: .@request$ = strcharinfo(0)+": "; - for (.@i = 0; .@i < .@atcmd_numparameters; ++.@i) { - .@request$ += (.@i > 0 ? " " : "") + .@atcmd_parameters$[.@i]; - } + .@request$ += implode(.@atcmd_parameters$, " "); atcommand("@request "+.@request$); end; -- cgit v1.2.3-70-g09d2