Skip to content
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

Uri van Roe weird behavior in S4 #46

Closed
nemaara opened this issue Mar 29, 2022 · 16 comments
Closed

Uri van Roe weird behavior in S4 #46

nemaara opened this issue Mar 29, 2022 · 16 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@nemaara
Copy link
Owner

nemaara commented Mar 29, 2022

@cooljeanius Your code here doesn't behave how you might think it does:

{MSG_Uri _"This is taking too long. Men, gather me an escort, for I shall be taking this battle to the mixling myself!"}
.

Turns out you can make him run between your keep and his own so he gets stuck in limbo and doesn't recruit again. Makes the scenario a lot easier to just defend forever.

@cooljeanius
Copy link
Collaborator

ok so I guess #30 isn't actually fixed after all... I wonder if this is a general issue with the [leader_goal] tag, or just how it's being used here?

@cooljeanius
Copy link
Collaborator

(note that the [leader_goal] tag has been there since before I started modifying this campaign; the only stuff I've changed about it has been the addition of the dialogue surrounding it, and the provision of some extra reinforcements for him)

@cooljeanius
Copy link
Collaborator

maybe it's worth trying setting some of the other keys that the [leader_goal] tag accepts? e.g. auto_remove=, id=, and/or max_risk=... or maybe adding a [micro_ai] tag?

@nemaara
Copy link
Owner Author

nemaara commented Mar 29, 2022

Yea your code does exactly what you're telling him to do. The problem is the logic is flawed. By setting a leader goal only when someone is on the keep, all I have to do is make Gawen or any other unit run on and off the keep and Uri will just run back and forth. So it needs some better logic to either go straight there and charge into you or to just stay at his base permanently. No waffling back and forth lol.

@cooljeanius
Copy link
Collaborator

cooljeanius commented Mar 30, 2022

Oh you mean this part:

[if]
[not]
[have_unit]
side=1
x,y=21,21 # Gawen's keep
[/have_unit]
[/not]
[then]
# He already has a leader_goal aiming here, but if the path is already clear, then give him a bit of extra prompting:
[modify_unit]
[filter]
id=Uri van Roe
[/filter]
goto_x,goto_y=21,21 # The empty keep that Gawen presumably abandoned
[/modify_unit]
{MSG_Uri _"To Barnon!"}
[/then]
[else]
{MSG_Uri _"You can't stay holed up there forever, Gawen!"}
[/else]
[/if]

That's different from the setting of the [leader_goal] here:
[ai]
turns=15-30 # Turn 15 corresponds to a hardcoded event, so keep that end of the range constant
[leader_goal]
x,y=21,21 # Gawen's keep
[/leader_goal]
leader_aggression={ON_DIFFICULTY 0.5 0.6 0.7}
[goal]
name=protect_unit
[criteria]
id=Uri van Roe
side=4
canrecruit=yes
[/criteria]
protect_radius=6 # MP of an Akladian Lord
value={ON_DIFFICULTY 9 7 5}
[/goal]
[/ai]

Also the event from L547-L567 only ought to fire once, on turn 15, not every time Gawen moves on or off the keep. If Uri keeps waffling about which way he wants to go, that's got to be decisions made by his AI instead.

cooljeanius added a commit to cooljeanius/A_New_Order that referenced this issue Mar 30, 2022
@nemaara
Copy link
Owner Author

nemaara commented Mar 31, 2022

Hmmm. You're right so that means the AI probably needs some tweaking. Can't release without this fixed I think.

@cooljeanius
Copy link
Collaborator

Hmmm. You're right so that means the AI probably needs some tweaking. Can't release without this fixed I think.

I'm busy tomorrow, but I should be able to get around to testing 13dfd3c sometime within the next week or so...

cooljeanius added a commit to cooljeanius/A_New_Order that referenced this issue Apr 3, 2022
more messing with AI to try to address nemaara/A_New_Order#46
cooljeanius referenced this issue in cooljeanius/A_New_Order Apr 3, 2022
address some AI issues that I discovered on testing the previous few commits (this particular commit, however, is as of yet untested itself)
@cooljeanius
Copy link
Collaborator

OK I've tested some changes, and... I'm getting kind of tired testing this scenario, tbh; can I just submit a PR for what I've got so far and leave the rest of the testing to you?

@nemaara
Copy link
Owner Author

nemaara commented Apr 9, 2022

Sure thing!

cooljeanius referenced this issue in cooljeanius/A_New_Order-1 Apr 9, 2022
well, act less abusably, at least. This is meant to address bug #46 but testing it got boring, so there are some parts still untested. I also changed some other things about the scenario I noticed while I was at it
@cooljeanius
Copy link
Collaborator

Sure thing!

ok I opened PR #49

@cooljeanius
Copy link
Collaborator

so, did merging PR #49 fix this satisfactorily?

@nemaara
Copy link
Owner Author

nemaara commented Apr 21, 2022

Yeah seems fine.

@nemaara nemaara closed this as completed Apr 21, 2022
@cooljeanius
Copy link
Collaborator

We might need to reopen; @knyghtmare discovered another oddity with this

@cooljeanius cooljeanius added the bug Something isn't working label May 29, 2022
@cooljeanius
Copy link
Collaborator

Yeah I'm reopening this; szopen sent me a message on the forums with a replay from another player who was able to kill Uri because of this; I'm attaching it here:
ANO-Battle of Barnon Turn 21.gz

@cooljeanius cooljeanius reopened this Jun 5, 2022
cooljeanius added a commit to cooljeanius/A_New_Order that referenced this issue Jun 6, 2022
- Update credits as per nemaara/A_New_Order#28
- Make `{CLEAR_RECALL}` macro look less glitchy to players
- Fall colors for a few Barnon trees I missed previously
- Have Uri van Roe keep getting reinforcements each time you attack him at Barnon, to try to mitigate nemaara/A_New_Order#46
- Give enemy more gold in Barnon more times (depending on difficulty)
- Add an "enemies defeated" event to Barnon to address nemaara/A_New_Order#52
- improve detection of debug kills
- attempt to get Hoyre to return with reinforcements (doesn't seem to work)
@cooljeanius cooljeanius self-assigned this Jun 6, 2022
cooljeanius referenced this issue in cooljeanius/A_New_Order-1 Jul 30, 2022
- update credits (issue #28)
- update ART_TODO.txt for the sake of artists being commissioned to do art
- next release will be 1.5.0, not 1.4.2
- split out death message macros into a separate file
- use more abilities from units/macros/abilities.cfg, as per #55
- update some terrain filters to account for map changes in nemaara#75
- more Barnon updates for #46 and #52
- regenerate potfile with wmlxgettext
- ensure portraits are embedded in unit types
@cooljeanius
Copy link
Collaborator

ok so #76 should do a better job of addressing this (not necessarily "fixing" it per se, just making the effects of it more manageable to the point where this can be closed again)

@cooljeanius
Copy link
Collaborator

OK hopefully e2cca67 can count as closing this for real this time; it might still require some further tuning, though...

@cooljeanius cooljeanius added this to the 1.5.0 milestone Jan 10, 2023
cooljeanius added a commit that referenced this issue Aug 25, 2024
…esnoth-map-diff-8c64bc7

Bump utils/wesnoth-map-diff from `ac95084` to `8c64bc7`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants