Hello,
If though the IP exists in your /root/blocked_ips.txt that does not mean you've got the IP blocked in your firewall. If you restart/reload your firewall it usually flushes all rules and do the IPs from /root/blocked_ips.txt get loaded with a start of firewall? I'd guess, no.
So you might need either remove the IP from the file and re-add it from Directadmin web-GUI, or re-write your script, which start your firewall. Or even both.