Decker coded cards
Discuss Upcoming Releases, Coding New Cards, Etc.
PLEASE DO NOT REPORT BUGS HERE!
PLEASE DO NOT REPORT BUGS HERE!
Moderators: BAgate, drool66, Aswan jaguar, gmzombie, stassy, CCGHQ Admins
Decker coded cards
by decker » 03 Nov 2012, 08:23
Hi,
So I'm going to post here the cards that I am fiddling with (I don't know if the id is of any use or only related to my version ?).
Kabuto Moth (200789d)
So I'm going to post here the cards that I am fiddling with (I don't know if the id is of any use or only related to my version ?).
Kabuto Moth (200789d)
- Code: Select all
int card_kabuto_moth(int player, int card, event_t event){
return vanilla_creature_pumper(player, card, event, 0, 0, 0, 0, 0, 0, 3, 1, 2, 0, 0);
}
- Code: Select all
int card_to_arms(int player, int card, event_t event){
if( event == EVENT_CAN_CAST ){
return 1;
}
if( event == EVENT_RESOLVE_SPELL ){
manipulate_all(player, card, player, TYPE_CREATURE, 0, 0, 0, 0, 0, 0, 0, -1, 0, ACT_UNTAP);
draw_cards(player, 1);
kill_card(player, card, KILL_DESTROY);
}
return 0;
}
-
decker - Posts: 61
- Joined: 09 May 2010, 18:37
- Location: Nice, France (GMT+1)
- Has thanked: 2 times
- Been thanked: 1 time
Re: Decker coded cards
by decker » 03 Nov 2012, 08:38
Now I am trying to work on Silent Arbiter, but I'm having a hard time finding a similar card Crawlspace is the closest I found but code only talks about attackers.
So I was thinking about this kind of code but I had to try to guess the blocking part...
So I was thinking about this kind of code but I had to try to guess the blocking part...
- Code: Select all
int card_silent_arbiter(int player, int card, event_t event){
card_instance_t *instance = get_card_instance(player, card);
if( trigger_condition == TRIGGER_DECLARE_ATTACK && current_phase == PHASE_DECLARE_ATTACKERS ){
if(event == EVENT_TRIGGER){
event_result |= 2;
}
else if( event == EVENT_RESOLVE_TRIGGER){
instance->info_slot++;
if(instance->info_slot > 1 ){
forbid_attack = 1;
}
}
}
if( trigger_condition == TRIGGER_DECLARE_ATTACK && current_phase == PHASE_DECLARE_BLOCKERS ){
if(event == EVENT_TRIGGER){
event_result |= 2;
}
else if( event == EVENT_RESOLVE_TRIGGER){
instance->info_slot++;
if(instance->info_slot > 1 ){
forbid_block = 1;
}
}
}
if( instance->info_slot > 0 && eot_trigger(player, card, event) ){
instance->info_slot = 0;
}
return 0;
}
-
decker - Posts: 61
- Joined: 09 May 2010, 18:37
- Location: Nice, France (GMT+1)
- Has thanked: 2 times
- Been thanked: 1 time
Re: Decker coded cards
by stassy » 05 Nov 2012, 07:25
Nice, I suggest also you PM Gargaroz about it as he doesn't often visit all the others forums beside the Bug and patch section.
- stassy
- Moderator
- Posts: 5274
- Joined: 25 Feb 2009, 07:06
- Has thanked: 471 times
- Been thanked: 337 times
Re: Decker coded cards
by fabiopinhao » 06 Jul 2013, 18:45
- fabiopinhao
- Posts: 2
- Joined: 06 Jul 2013, 18:43
- Has thanked: 0 time
- Been thanked: 0 time
4 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 17 guests