Commit fb894d44 authored by DailyShana's avatar DailyShana

fix

parent d589bd45
...@@ -1723,15 +1723,20 @@ int32 scriptlib::card_enable_counter_permit(lua_State *L) { ...@@ -1723,15 +1723,20 @@ int32 scriptlib::card_enable_counter_permit(lua_State *L) {
check_param_count(L, 2); check_param_count(L, 2);
card* pcard = *(card**) lua_touserdata(L, 1); card* pcard = *(card**) lua_touserdata(L, 1);
int32 countertype = lua_tointeger(L, 2); int32 countertype = lua_tointeger(L, 2);
uint16 prange;
if(pcard->data.type & TYPE_MONSTER)
prange = LOCATION_MZONE;
else
prange = LOCATION_SZONE | LOCATION_FZONE;
if(lua_gettop(L) > 2) {
prange |= lua_tointeger(L, 3);
}
effect* peffect = pcard->pduel->new_effect(); effect* peffect = pcard->pduel->new_effect();
peffect->owner = pcard; peffect->owner = pcard;
peffect->type = EFFECT_TYPE_SINGLE; peffect->type = EFFECT_TYPE_SINGLE;
peffect->code = EFFECT_COUNTER_PERMIT | countertype; peffect->code = EFFECT_COUNTER_PERMIT | countertype;
peffect->flag = EFFECT_FLAG_SINGLE_RANGE; peffect->flag = EFFECT_FLAG_SINGLE_RANGE;
if(pcard->data.type & TYPE_MONSTER) peffect->range = prange;
peffect->range = LOCATION_MZONE;
else
peffect->range = LOCATION_SZONE | LOCATION_FZONE;
pcard->add_effect(peffect); pcard->add_effect(peffect);
return 0; return 0;
} }
......
--マジカル・アブダクター --マジカル・アブダクター
function c10239627.initial_effect(c) function c10239627.initial_effect(c)
c:EnableCounterPermit(0x3001) c:EnableCounterPermit(0x3001,LOCATION_PZONE)
--pendulum summon --pendulum summon
aux.AddPendulumProcedure(c) aux.AddPendulumProcedure(c)
--Activate --Activate
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment