Board index
Microprose's Magic: The Gathering
ManaLink 3.0
Bug Reports
Archived Reports
Pending Reports





[Fixed]AI target Permanent=Planeswalker bad param & crash
Moderators: BAgate, drool66, Aswan jaguar, gmzombie, stassy, CCGHQ Admins
5 posts
• Page 1 of 1
[Fixed]AI target Permanent=Planeswalker bad param & crash
by Althuna » 10 Apr 2024, 04:54
I have savegame. It is an autosave from gauntlet mode (not with challenges).
- Attachments
-
New WinRAR archive.rar
- (3.43 KiB) Downloaded 266 times
Last edited by Aswan jaguar on 05 Jun 2024, 14:05, edited 3 times in total.
Reason: fixed
Reason: fixed
Re: [confirm]AI target Permanent=Planeswalker bad param & cr
by Aswan jaguar » 10 Apr 2024, 15:15
The issue happens as AI wants to target opponent's Planeswalker with Utter End - EDIT: and at the same time attack with creatures.
It will happen with any card that can target a permanent and AI selects to target a Planeswalker.(at least the ones that destroy or exile their targets that I have tested).
Happens only to AI. When AI targets a planeswalker and target type has been set to TYPE_PLANESWALKER so card rules text is "target a planeswalker" it works fine.
It will happen with any card that can target a permanent and AI selects to target a Planeswalker.(at least the ones that destroy or exile their targets that I have tested).
Happens only to AI. When AI targets a planeswalker and target type has been set to TYPE_PLANESWALKER so card rules text is "target a planeswalker" it works fine.
- The error produced: | Open
- bad parameters
get_card_instance(0, -2)
0: 0x026CFB58
1: 0x026D679E
2: 0x0271E27C
3: 0x026AAE72
4: 0x027448D5
5: 0x0271BE5C
6: 0x0271BEDA
7: 0x0271D357
8: 0x00435A13
9: 0x004770E3
10: 0x026E8D21
11: 0x026BF222
12: 0x026EF2D4
13: 0x0047902C
14: 0x004946E9
15: 0x7C80B729
Last edited by Aswan jaguar on 05 Jun 2024, 14:04, edited 2 times in total.
Reason: add edit
Reason: add edit
---
Trying to squash some bugs and playtesting.
Trying to squash some bugs and playtesting.
-
Aswan jaguar - Super Tester Elite
- Posts: 8129
- Joined: 13 May 2010, 12:17
- Has thanked: 748 times
- Been thanked: 477 times
Re: [confirm]AI target Permanent=Planeswalker bad param & cr
by drool66 » 02 Jun 2024, 18:40
This particular bug goes through damage_effects.c::effect_damage() - I don't know how the damage_creature is sending -2 in targets[4].card, but the check early on should be "tc > -1", not "tc != -1", as should the various checks to targets[4].card (as should most or all of the various param checks all over the place in Manalink...)
The latest images for Manalink will be here.
The latest Manalink installation directory will be here. Well, not quite, anymore. Check the latest patches.
The latest Manalink installation directory will be here. Well, not quite, anymore. Check the latest patches.
-
drool66 - Programmer
- Posts: 1185
- Joined: 25 Nov 2010, 22:38
- Has thanked: 187 times
- Been thanked: 280 times
Re: [confirm]AI target Permanent=Planeswalker bad param & cr
by Aswan jaguar » 05 Jun 2024, 14:02
Fixed and tested in commit 36167cd, changed only the first check to targets[4].card.
It was some interaction between Utter End ( or cards like that as I say above ) and a creature ( certainly with a token creature, didn't test with just creature ) that AI was thinking to attack with it, and there was a planeswalker on human's battlefield. If either no creatures to attack or no Utter End and such no bug.
It was some interaction between Utter End ( or cards like that as I say above ) and a creature ( certainly with a token creature, didn't test with just creature ) that AI was thinking to attack with it, and there was a planeswalker on human's battlefield. If either no creatures to attack or no Utter End and such no bug.
---
Trying to squash some bugs and playtesting.
Trying to squash some bugs and playtesting.
-
Aswan jaguar - Super Tester Elite
- Posts: 8129
- Joined: 13 May 2010, 12:17
- Has thanked: 748 times
- Been thanked: 477 times
Re: [Fixed]AI target Permanent=Planeswalker bad param & cras
by drool66 » 11 Jun 2024, 05:35
Fixed in 08b94da
EDIT: this fix is for bug [fixed]Bad parameters - validate counterslell crashes game and not for the above - edited
EDIT: this fix is for bug [fixed]Bad parameters - validate counterslell crashes game and not for the above - edited
Last edited by Aswan jaguar on 29 Jun 2024, 09:58, edited 1 time in total.
Reason: edit
Reason: edit
The latest images for Manalink will be here.
The latest Manalink installation directory will be here. Well, not quite, anymore. Check the latest patches.
The latest Manalink installation directory will be here. Well, not quite, anymore. Check the latest patches.
-
drool66 - Programmer
- Posts: 1185
- Joined: 25 Nov 2010, 22:38
- Has thanked: 187 times
- Been thanked: 280 times
5 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 3 guests