X-Git-Url: https://git.artsoft.org/?p=rocksndiamonds.git;a=blobdiff_plain;f=src%2Ffiles.c;fp=src%2Ffiles.c;h=d113c6ad0f9b9733b9f9d5303e9f1336c7bdc4e4;hp=1e185c2396e22093f82ec3a18f80bb0421fb9911;hb=368684d4c5e2a59cbea8c5e35171f3fe008b844f;hpb=110edc5fe9017a947274eb64af47ebb52a12d92f diff --git a/src/files.c b/src/files.c index 1e185c23..d113c6ad 100644 --- a/src/files.c +++ b/src/files.c @@ -11487,6 +11487,18 @@ static int get_anim_action_parameter_value(char *token) result = -(int)key; } + if (result == -1) + { + if (isURL(token)) + { + result = get_hash_from_key(token); // unsigned int => int + result = ABS(result); // may be negative now + result += (result < MAX_IMAGE_FILES ? MAX_IMAGE_FILES : 0); + + setHashEntry(anim_url_hash, int2str(result, 0), token); + } + } + if (result == -1) result = ANIM_EVENT_ACTION_NONE;