DinoDevs / GladiatusCrazyAddon

This was "A browser addon for the Gladiatus browser game."

Home Page:https://gladiatus.dinodevs.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Failed to detect enemy - material as secondary drop

FrutyX opened this issue · comments

Taken from #382.

error3

Confirmed, a secondary drop is causing this errors (very #368 related):
And it does look like, that the secondary drop has to be a material, for this error to happen.

Failed to detect enemy url("//gf3.geo.gfsrv.net/cdn29/bac7e539d61a9de6caec21363c2694.jpg")

scd

I can't see how this error can happen with the current code. gca_tools.img.resolve("//gf3.geo.gfsrv.net/cdn29/bac7e539d61a9de6caec21363c2694.jpg") returns the enemy, so the error should not appear with the current code.

Can anyone still replicate it?

I think Thanos said something like that too, but I am getting it pretty normally (remember, a secondary drop and only a material), basically my error log is spammed with it.

And so it goes on... might just disable the console warning.

errors

I think Thanos said something like that too, but I am getting it pretty normally (remember, a secondary drop and only a material), basically my error log is spammed with it.

Does running gca_tools.img.resolve("//gf3.geo.gfsrv.net/cdn29/bac7e539d61a9de6caec21363c2694.jpg") in the console return the enemy url?

Yeah, it returns the enemy url 'img/npc/4/4_4.jpg', however I am looking at it now as a stored report, maybe the result would be different when it actually occurs, but damn, my UW costume just expired :D.

Yeah, it returns the enemy url 'img/npc/4/4_4.jpg', however I am looking at it now as a stored report, maybe the result would be different when it actually occurs, but damn, my UW costume just expired :D.

Still throws an error?

Not when looking at an old stored report.

Not when looking at an old stored report.

I think it works :P

Wait what? What works? :D I mean it works, but it's still throwing an error, except when looking at the report later.

Wait what? What works? :D I mean it works, but it's still throwing an error, except when looking at the report later.

Oh, sorry, yes it doesn't check the data if the report is old.

Edit the report.js line 187 and completely delete the check if (timePassed > 5) return;
Then check the old report.

Hello there.

enemy

Hello there.

enemy

I still can't see how this error is generated... What do you get with:

let image = document.getElementById('defenderAvatar11').getElementsByTagName('div')[2].style.backgroundImage;
let enemy = gca_tools.img.resolve(image);
if (enemy) console.log('Passed', image);
else console.error('Failed to detect enemy', image, enemy);

I am only eager to see if you can solve this, because it seems even Thanos just ignored this :D.

I am only eager to see if you can solve this, because it seems even Thanos just ignored this :D.

The error was extremally misleading :P
Test this fix (keep that check deleted and check the old report)

PATCHED!

Well done, and thank you. It seems it's gone, I hope, forever, gone, reduced to atoms. (yes I deleted the check again)

PATCHED!

Well done, and thank you. It seems it's gone, I hope, forever, gone, reduced to atoms. (yes I deleted the check again)

This will do for now... Ultimately, instead of deleting the url("...."), I should search for the url in the parenthesis... anyway, let's close this for now.

Ah lovely, I had 3 expeditions left without UW costume, and last exp gave me a secondary material drop, no error, perfect.