From a5c939bec95ceab467e7fedc530460e4a70e7138 Mon Sep 17 00:00:00 2001 From: Atemo Date: Fri, 9 Aug 2024 23:33:43 +0200 Subject: [PATCH] Updated addhomintimacy script command (#8551) * The command now fails silently when no players are attached or if the player has no homunculus (like other homunculus script command) Fixed #8534 --- doc/script_commands.txt | 1 + src/map/script.cpp | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/doc/script_commands.txt b/doc/script_commands.txt index ce0e838d7b8..41c08486336 100644 --- a/doc/script_commands.txt +++ b/doc/script_commands.txt @@ -10691,6 +10691,7 @@ current invoking character. *addhomintimacy {,}; Increase or decrease a homunculus' intimacy value by the given . 100000 is full loyalty. +Fails silently when no players are attached or if the player has no homunculus. --------------------------------------- diff --git a/src/map/script.cpp b/src/map/script.cpp index 1d1045b4a2b..bd53f409bf0 100644 --- a/src/map/script.cpp +++ b/src/map/script.cpp @@ -15861,7 +15861,7 @@ BUILDIN_FUNC(addhomintimacy) homun_data *hd; if (!script_charid2sd(3, sd) || !(hd = sd->hd)) - return SCRIPT_CMD_FAILURE; + return SCRIPT_CMD_SUCCESS; int32 value = script_getnum(st, 2);