Commit c379d06a authored by salix5's avatar salix5

Card.IsReleasable: REASON_COST by default

parent 662706b7
......@@ -2410,7 +2410,7 @@ int32 scriptlib::card_is_releasable(lua_State *L) {
check_param(L, PARAM_TYPE_CARD, 1);
card* pcard = *(card**) lua_touserdata(L, 1);
uint32 p = pcard->pduel->game_field->core.reason_player;
uint32 reason = 0;
uint32 reason = REASON_COST;
if (lua_gettop(L) >= 2)
reason = (uint32)lua_tointeger(L, 2);
if(pcard->is_releasable_by_nonsummon(p, reason))
......
......@@ -4334,7 +4334,7 @@ int32 scriptlib::duel_is_player_can_release(lua_State * L) {
check_param_count(L, 2);
check_param(L, PARAM_TYPE_CARD, 2);
card* pcard = *(card**) lua_touserdata(L, 2);
uint32 reason = 0;
uint32 reason = REASON_COST;
if (lua_gettop(L) >= 3)
reason = (uint32)lua_tointeger(L, 3);
lua_pushboolean(L, pduel->game_field->is_player_can_release(playerid, pcard, reason));
......
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