Issue information

Issue ID
#524
Status
Fixed
Severity
Medium
Started
Hercules Elf Bot
Nov 30, 2007 23:42
Last Post
Hercules Elf Bot
Nov 30, 2007 23:42
Confirmation
N/A

Hercules Elf Bot - Nov 30, 2007 23:42

Originally posted by [b]Christian[/b]
http://www.eathena.ws/board/index.php?autocom=bugtracker&showbug=524

\npc\quests\skills\priest_skills.txt
Lines 289-294
CODE
                    if (.@redem_s < 31)
                        if (.@red_suc > 20 && .@red_suc < 41) set .@success,1;
                    else if (.@redem_s < 41)
                        if (.@red_suc > 10 && .@red_suc < 41) set .@success,1;
                    else
                        if (.@red_suc > 10 && .@red_suc < 51) set .@success,1;

This part of the quest is messed up, because if the condition of the 2nd if is false, the 1st else would be triggered, but it should be only triggered by the 1st if. It's the same with the 4th if and 2nd else.

A possible fix:
CODE
                    if (.@redem_s < 31) {
                        if (.@red_suc > 20 && .@red_suc < 41) set .@success,1;
                    }
                    else if (.@redem_s < 41) {
                        if (.@red_suc > 10 && .@red_suc < 41) set .@success,1;
                    }
                    else {
                        if (.@red_suc > 10 && .@red_suc < 51) set .@success,1;
                    }