Re: Special abilities in targets[16] aren't properly cleared
Added your fix, thanx Korath.
High Quality Resources for Collectible Card Games and Home of the CCGHQ Team
https://www.slightlymagic.net/forum/
https://www.slightlymagic.net/forum/viewtopic.php?f=110&t=4108


diff --git a/src/cards/guildpact.c b/src/cards/guildpact.c
index a0eee61..86fc398 100644
--- a/src/cards/guildpact.c
+++ b/src/cards/guildpact.c
@@ -1277,7 +1277,7 @@ int card_leyline_of_singularity(int player, int card, event_t event){
for(i=0; i<2; i++){
int count = active_cards_count[i]-1;
while( count > -1 ){
- if( in_play(i, count) && is_what(i, count, TYPE_PERMANENT) && ! is_basic_land(i, count) && ! is_legendary(i, count) ){
+ if( in_play(i, count) && is_what(i, count, TYPE_PERMANENT) && ! is_what(i, count, TYPE_LAND) && ! is_legendary(i, count) ){
verify_legend_rule(i, count, get_id(i, count));
}
count--;
@@ -1286,7 +1286,7 @@ int card_leyline_of_singularity(int player, int card, event_t event){
}
if( trigger_condition == TRIGGER_COMES_INTO_PLAY && affect_me(player, card) && player == reason_for_trigger_controller){
- if( ! is_basic_land(trigger_cause_controller,trigger_cause) && ! is_legendary(trigger_cause_controller,trigger_cause) ){
+ if( ! is_what(trigger_cause_controller, trigger_cause, TYPE_LAND) && ! is_legendary(trigger_cause_controller,trigger_cause) ){
if( ! check_battlefield_for_id(2, CARD_ID_MIRROR_GALLERY) ){
if(event == EVENT_TRIGGER){
event_result |= 2;
diff --git a/src/functions/tutors.c b/src/functions/tutors.c
index 56b4b52..f2b6f8c 100644
--- a/src/functions/tutors.c
+++ b/src/functions/tutors.c
@@ -125,7 +125,7 @@ int new_select_a_card(int player, int targ_player, int search_location, int must
if( search_location == 4 ){
int hand_index[99];
int i;
- for(i=0; i<100; i++){
+ for(i=0; i<99; i++){
hand_index[i] = -1;
}
int hand_c = 0;