Zethfox wrote:kinda, i disallowed it during interupting with instants of the move to phases or when the stack is empty...simply becuase it created a few infinate loops, i basically had no way of telling ai to "stop" trying to find a card to play...meaning something like a mass removal spell in hand, it sees that it would be "bad" to play it, then it tries looking for something else, since the function is run on update() calls, ai gets stuck constantly looping "play this----no---ok look for something else---nothing----ok contenue interupting becuase i see there is something i can play---same thing as before hmmm---no----ect ect ect" you get the point.(
Not sure this is possible or not Zeth, but is it possible to code a boolean variable array that the AI could check against when an update() call occurs?
Example:
The update() function triggers, and the AI scans it's cards for a playable card. If it finds one, it checks the boolean array for that card #. If it's true, it skips the rest of the function.
if it's false then it sets that boolean array with the number being the card # in his hand to true.
If that card can't be played then it does nothing.
if the card can be played, it sets the variable back to false since the card is used and triggers the interrupt.
alternately, if there is a function for when a card is played or drawn, it could set that variable back to false then as well to make sure it will check that slot in his hand again later.
something along those lines might prevent the AI from looping permanently?
Not sure though, since my programming experience is limited to trigger editing for maps in games like Starcraft and Warcraft III