a place for all your custom card needs you can post scripts pics and request for card to be made also please donate to the funding for a new server made for custom card duels
 
HomePortalCalendarFAQSearchMemberlistUsergroupsRegisterLog in

Share | .
 

 Prevent counters on a monster

View previous topic View next topic Go down 
AuthorMessage
TGAP-Trixie

avatar


Member Title : Trixie does not even...
Posts : 273
Join date : 2014-04-17

PostSubject: Prevent counters on a monster   Thu May 01, 2014 8:17 pm

Had to hold off on a card I wanted to code because there was nothing remotely close in the game that prevents counters from being placed on cards. But with the new gate blocker, I'm one step closer.

However, gate blocker prevents YOUR OPPONENT from placing counters on ANY cards on the field. I'm just trying to have a monster that can't have counters added to itself (from either player), via effects like venom swamp, card guard, gimmick puppet of strings etc., and also, inflicting 500 damage to the opponent when a counter would be added to it.

I'm not that good at scripting yet to find a way to work around this, but here is gate blocker's counter preventing code if it helps.
Code:
local e3=Effect.CreateEffect(c)
 e3:SetType(EFFECT_TYPE_FIELD)
 e3:SetRange(LOCATION_MZONE)
 e3:SetCode(EFFECT_CANNOT_PLACE_COUNTER)
 e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
 e3:SetTargetRange(0,1)
 c:RegisterEffect(e3)
Back to top Go down
View user profile
VB99

avatar


Member Title : Legendary Planet
Posts : 368
Join date : 2013-11-10

PostSubject: Re: Prevent counters on a monster   Thu May 01, 2014 9:34 pm

I have no idea how this is supposed to work... I mean, you can script it that it removes every counter on it when one is added and inflicts burn for it, but that way?

Not sure though, I mean, I'm still a lerner.

_________________
Back to top Go down
View user profile http://www.fanfiktion.de/u/VB99
TGAP-Trixie

avatar


Member Title : Trixie does not even...
Posts : 273
Join date : 2014-04-17

PostSubject: Re: Prevent counters on a monster   Fri May 02, 2014 2:53 am

It could be done that way I suppose. Removing the counter would be a cost for the burn damage so fiendish chain shouldn't prevent it from removing the counters (except new counters afterwards which, oh well, is gonna happen).

I suppose I could script it somewhat like anything that can use the counter (breaker for example) but make it forced rather than optional. Not sure exactly how that'll happen, but if a card that prevents counters from being placed on it at all is impossible (atm) then that's the best alternative.
Back to top Go down
View user profile
outlaw1994

avatar
Admin
Admin

Member Title : Red-Eyes Lord
Posts : 797
Join date : 2013-07-09
Age : 22
Location : bundaberg qld australia

PostSubject: Re: Prevent counters on a monster   Fri May 02, 2014 6:29 am

local e3=Effect.CreateEffect(c)
 e3:SetType(EFFECT_TYPE_SINGLE)
 e3:SetRange(LOCATION_MZONE)
 e3:SetCode(EFFECT_CANNOT_PLACE_COUNTER)
 c:RegisterEffect(e3)


that would make it so no counter can be place on the monster with this effect i will see if i can find something about the burn for you
Back to top Go down
View user profile http://mackpro.userboard.net
cane_63106

avatar


Member Title : D.D. Dragon Kaiser
Posts : 454
Join date : 2013-07-23
Location : St. Louis, MO

PostSubject: Re: Prevent counters on a monster   Sat May 03, 2014 7:02 am

wouldn't it work out a continuous effect that negates each attempt then burns instead of all out stopping?

_________________
Now...you will feel my wrath and know your place! I activate DIMENSIONAL END!!!

Custom Card Duels
Back to top Go down
View user profile http:// https://www.youtube.com/user/cane63106/videos
outlaw1994

avatar
Admin
Admin

Member Title : Red-Eyes Lord
Posts : 797
Join date : 2013-07-09
Age : 22
Location : bundaberg qld australia

PostSubject: Re: Prevent counters on a monster   Sat May 03, 2014 7:04 am

probably im busy atm but i will work on it later
Back to top Go down
View user profile http://mackpro.userboard.net
TGAP-Trixie

avatar


Member Title : Trixie does not even...
Posts : 273
Join date : 2014-04-17

PostSubject: Re: Prevent counters on a monster   Sun May 04, 2014 4:43 am

The script doesn't work, counters still get placed on it. I was looking in the constant file and was thinking maybe either COUNTER_NEED_PERMIT or COUNTER_NEED_ENABLE, but I don't know where that usually goes. I've also tried setcounterlimit and setting it to 0 but notihing.
Back to top Go down
View user profile
outlaw1994

avatar
Admin
Admin

Member Title : Red-Eyes Lord
Posts : 797
Join date : 2013-07-09
Age : 22
Location : bundaberg qld australia

PostSubject: Re: Prevent counters on a monster   Sun May 04, 2014 4:48 am

both those allow a card to have a certain type of counter 
COUNTER_NEED_PERMIT  lets it use a certain counter for example spell counters
COUNTER_NEED_ENABLE chect to see if the card has the above code to enable counters put on it
Back to top Go down
View user profile http://mackpro.userboard.net
TGAP-Trixie

avatar


Member Title : Trixie does not even...
Posts : 273
Join date : 2014-04-17

PostSubject: Re: Prevent counters on a monster   Sun May 04, 2014 5:15 am

I see. Then, going back to VB's suggestion of just letting the counters be placed on it and forcing the removal from them, do you know of a generic counter code, if there is one? That way it can be put in place of COUNTER_NEED_PERMIT, allowing it to use all possible types of counters for the forced removal/burn.
Back to top Go down
View user profile
outlaw1994

avatar
Admin
Admin

Member Title : Red-Eyes Lord
Posts : 797
Join date : 2013-07-09
Age : 22
Location : bundaberg qld australia

PostSubject: Re: Prevent counters on a monster   Sun May 04, 2014 6:30 am

you could try looking at the card counter cleaner if it helps
Back to top Go down
View user profile http://mackpro.userboard.net
outlaw1994

avatar
Admin
Admin

Member Title : Red-Eyes Lord
Posts : 797
Join date : 2013-07-09
Age : 22
Location : bundaberg qld australia

PostSubject: Re: Prevent counters on a monster   Sun May 04, 2014 7:00 am

here you go this should work just replace ???????? with the id of your card


Code:
function c????????.initial_effect(c)
   --check counter
   local e1=Effect.CreateEffect(c)
   e1:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
   e1:SetCode(EVENT_CHAIN_SOLVING)
   e1:SetProperty(EFFECT_FLAG_DELAY)
   e1:SetRange(LOCATION_MZONE)
   e1:SetOperation(c????????.acop)
   c:RegisterEffect(e1)
   --remove&damage
   local e2=Effect.CreateEffect(c)
   e2:SetCategory(CATEGORY_DESTROY+CATEGORY_DAMAGE)
   e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
   e2:SetCode(????????)
   e2:SetTarget(c????????.damtg)
   e2:SetOperation(c????????.damop)
   c:RegisterEffect(e2)
end
function c????????.acop(e,tp,eg,ep,ev,re,r,rp)
   local c=e:GetHandler()
   if c:GetCounter(0)~=0 then
      Duel.RaiseSingleEvent(c,????????,re,0,0,p,0)
   end
end
function c????????.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
   if chk==0 then return e:GetHandler():IsRelateToEffect(e) end
   Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,500)
end
function c????????.damop(e,tp,eg,ep,ev,re,r,rp)
   if not e:GetHandler():IsRelateToEffect(e) then return end
   e:GetHandler():RemoveCounter(tp,0,0,0)
   Duel.Damage(1-tp,500,REASON_EFFECT)
end



how it works is after an effect resolves it checks if it has a counter and if it does it activates the second effect removing the counter and inflicting damage all tested and works perfect
Back to top Go down
View user profile http://mackpro.userboard.net
VB99

avatar


Member Title : Legendary Planet
Posts : 368
Join date : 2013-11-10

PostSubject: Re: Prevent counters on a monster   Sun May 04, 2014 11:23 am

I just wondered...
What kind of Attribute/Type are you going to give your monster?
I just wanted to say that I highly suggest you to make it a LIGHT/Reptile "Alien"-Monster so you can combo with Gol'Gar.

_________________
Back to top Go down
View user profile http://www.fanfiktion.de/u/VB99
TGAP-Trixie

avatar


Member Title : Trixie does not even...
Posts : 273
Join date : 2014-04-17

PostSubject: Re: Prevent counters on a monster   Mon May 05, 2014 4:43 am

Nice, it works perfectly. TYVM outlaw Smile

@VB. If you're that interested...
Bog Hydra:
 
 It's meant to combo with this card
FBB:
 

Both from the mlp series lol. And don't worry, Bog Hydra is 100%. The counter/burn was the confusing part. Gonna need to give it a minor errata as well.
Back to top Go down
View user profile
outlaw1994

avatar
Admin
Admin

Member Title : Red-Eyes Lord
Posts : 797
Join date : 2013-07-09
Age : 22
Location : bundaberg qld australia

PostSubject: Re: Prevent counters on a monster   Mon May 05, 2014 5:04 am

np tgap looking forward to playing them
Back to top Go down
View user profile http://mackpro.userboard.net
TGAP-Trixie

avatar


Member Title : Trixie does not even...
Posts : 273
Join date : 2014-04-17

PostSubject: Re: Prevent counters on a monster   Mon May 05, 2014 5:31 am

Yup. Speaking of which, how would I go about getting them on mackpro? Not that any sub-archetype that's currently coded is actually viable atm, except maybe the pegasi.
Also I've tried downloading mackpro once, but when I tried to extract the file, my computer crashed. I tried this 2 more times and the same thing happened, so I just deleted it. It could just be that my computer is old, but idk if anyone else has had similar issues.
Back to top Go down
View user profile
outlaw1994

avatar
Admin
Admin

Member Title : Red-Eyes Lord
Posts : 797
Join date : 2013-07-09
Age : 22
Location : bundaberg qld australia

PostSubject: Re: Prevent counters on a monster   Mon May 05, 2014 6:23 am

dk what are your specs and to get them on mackpro send a cardpacker zip with them to me and i will add them in next update
Back to top Go down
View user profile http://mackpro.userboard.net
TGAP-Trixie

avatar


Member Title : Trixie does not even...
Posts : 273
Join date : 2014-04-17

PostSubject: Re: Prevent counters on a monster   Tue May 06, 2014 7:15 pm

Win 7, 32bit, intel processor... Not 100% sure what specs are and if that's enough info.
Will send you the cardpacker zip if I can 100% a few more cards, probably later in the week (there's like 3 atm that need minor fixes that I might have to request if I can't figure it out)

Off-topic: is there a way to manually add cards to the banlist? Or do I absolutely need the card manager for that?
Back to top Go down
View user profile
outlaw1994

avatar
Admin
Admin

Member Title : Red-Eyes Lord
Posts : 797
Join date : 2013-07-09
Age : 22
Location : bundaberg qld australia

PostSubject: Re: Prevent counters on a monster   Wed May 07, 2014 2:01 am

you can manually add cards but its annoying just edit iflist.conf in notepad
Back to top Go down
View user profile http://mackpro.userboard.net
Sponsored content





PostSubject: Re: Prevent counters on a monster   

Back to top Go down
 

Prevent counters on a monster

View previous topic View next topic Back to top 
Page 1 of 1

 Similar topics

-
» Help on spell counters
» could cybermen upgrade the morbius monster
» Teratorns - the monster birds
» Monster Hunter! (Freedom Unite)
» Wyrdstone Counters By Ashton Sanders

Permissions in this forum:You cannot reply to topics in this forum
Mackpro :: MackPro :: Requests-