-
Notifications
You must be signed in to change notification settings - Fork 70
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Don't double-use waffles #1365
Don't double-use waffles #1365
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me
There is some weirdness going on in your log there
1 - We shouldn't update auto_replaces unless the replacement works. Currently we assume it will work and track it before using the replacer. This is a bit of a refactor and could be in a different PR 2 - Having troubles lining up what is in log vs what your code is. Code seems that it would abort if we are going to replace the enemy, but log shows we got to round 2 before aborting for not being able to find a replacer. Which is good as we used waffle and don't want to use it again. Also why does log show combat state gets "replacer" added? That should always be added before using the waffle. Are you sure this code is the same as what you were using when log was generated? |
Yeah, the log was just showing that the couple of iterations of useItem I went through weren't effective. After I did the cigarette lighter trick of useItems($item[waffle], $item[none]); it works better and then after I fixed the combat tracking section in stage2 it works perfectly as expected. It uses 1 and logs it properly. |
@@ -375,7 +375,7 @@ string auto_edCombatHandler(int round, monster enemy, string text) | |||
combat_status_add("banishercheck"); | |||
} | |||
|
|||
if (!combat_status_check("replacercheck") && canReplace(enemy) && auto_wantToReplace(enemy, my_location())) | |||
if (!combat_status_check("replacercheck") && auto_wantToReplace(enemy, my_location())) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thinking out loud. Don't need to add support for parsing funkslinging like you did in the general combat code because Ed can't throw 2 items in a single round of combat. True fact?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Never ran Ed but looking through the wiki that makes sense to me since you lose your skills and there is no funkslinging equivalent in the skill tree
RELEASE/scripts/autoscend/combat/auto_combat_default_stage2.ash
Outdated
Show resolved
Hide resolved
{ | ||
return "item " + $item[waffle]; | ||
return useItems($item[waffle], $item[none]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return useItems($item[waffle], $item[none]); | |
return useItem($item[waffle]); |
useItem()
has handling for funkslinging, no need to complicate it unnecessarily.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It didn't work with useItem. It tried to double use them, BUT that was before I updated the replacer logger in stage2. Will try useItem again and see if it works now
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, useItem double uses waffle for some reason. I changed it back to useItem and this happened.
useItem waffle.txt
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does it still double use when using useItem + change useItem to have none
as the second item?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmm did a quick test by using 2 different custom combat scripts. One for each of the returned value above. Both resulted in only 1 waffle being used. So none
vs nothing
doesn't seem to be the issue
@Malibu-Stacey agree with you useItem should be used but isn't obvious why it double uses waffles. Folks are running into this issue so over rode you request and merged it. We can make an issue for it |
Description
Currently double-use waffles. Trying to update code so that it doesn't do that.
How Has This Been Tested?
Running through normal Standard Sauceror for as quick a run as possible.
Checklist: