summaryrefslogtreecommitdiff
path: root/npc/other/Global_Functions.txt
diff options
context:
space:
mode:
authorHaru <haru@dotalux.com>2019-03-11 00:36:30 +0100
committerGitHub <noreply@github.com>2019-03-11 00:36:30 +0100
commit63b87d387dade9a66db16607864ae2bd5fcdc57a (patch)
tree69e974a65775707ed257d7fdf725187eb81fcc57 /npc/other/Global_Functions.txt
parentaf3bf18055ceae4b85df96f5fe66b9edc203351d (diff)
parentf202ca60acb3fbdf6ca1db5691bef35ff758ae79 (diff)
downloadhercules-63b87d387dade9a66db16607864ae2bd5fcdc57a.tar.gz
hercules-63b87d387dade9a66db16607864ae2bd5fcdc57a.tar.bz2
hercules-63b87d387dade9a66db16607864ae2bd5fcdc57a.tar.xz
hercules-63b87d387dade9a66db16607864ae2bd5fcdc57a.zip
Merge pull request #2360 from sigtus/stable
Added missing return on F_GetTradeRestriction
Diffstat (limited to 'npc/other/Global_Functions.txt')
-rw-r--r--npc/other/Global_Functions.txt28
1 files changed, 10 insertions, 18 deletions
diff --git a/npc/other/Global_Functions.txt b/npc/other/Global_Functions.txt
index 904ed7165..86332e931 100644
--- a/npc/other/Global_Functions.txt
+++ b/npc/other/Global_Functions.txt
@@ -446,32 +446,24 @@ function script F_MesColor {
function script F_GetTradeRestriction {
.@trade = getiteminfo(getarg(0), ITEMINFO_TRADE);
- if (.@trade == 0) {
+ if (.@trade == 0)
return "None";
- }
.@trade$ = "";
- if (.@trade & ITR_NODROP) {
+ if (.@trade & ITR_NODROP)
.@trade$ += "NoDrop|";
- }
- if (.@trade & ITR_NOTRADE) {
+ if (.@trade & ITR_NOTRADE)
.@trade$ += "NoTrade|";
- }
- if (.@trade & ITR_PARTNEROVERRIDE) {
+ if (.@trade & ITR_PARTNEROVERRIDE)
.@trade$ += "PartnerOverride|";
- }
- if (.@trade & ITR_NOSELLTONPC) {
+ if (.@trade & ITR_NOSELLTONPC)
.@trade$ += "NoSellToNpc|";
- }
- if (.@trade & ITR_NOSTORAGE) {
+ if (.@trade & ITR_NOSTORAGE)
.@trade$ += "NoStorage|";
- }
- if (.@trade & ITR_NOGSTORAGE) {
+ if (.@trade & ITR_NOGSTORAGE)
.@trade$ += "NoGuildStorage|";
- }
- if (.@trade & ITR_NOMAIL) {
+ if (.@trade & ITR_NOMAIL)
.@trade$ += "NoMail|";
- }
- if (.@trade & ITR_NOAUCTION) {
+ if (.@trade & ITR_NOAUCTION)
.@trade$ += "NoAuction|";
- }
+ return .@trade$;
}