Closed salix5 closed 9 months ago
@mercury233 @purerosefallen Simplify card::get_code(), card::get_another_code()
card::get_code()
card::get_another_code()
card::second_code Now cards with 2 original name are checked by looking up this table.
card::second_code
data.code This is the id in card database, which might be an id of alternative artwork.
data.code
The types of card id are:
cards with 2 original name Lua table id: data.code code_rule1: data.code code_rule2: second_code[data.code]
always treated as X Lua table id: data.code code_rule1: data.alias code_rule2: 0
alternative artwork Lua table id: data.alias (The original card) code_rule1: data.alias code_rule2: 0
other Lua table id: data.code code_rule1: data.code code_rule2: 0
The Lua table id: card::get_original_code() code_rule1, code_rule2: card::get_original_code_rule()
card::get_original_code()
card::get_original_code_rule()
Now data.code is not sent to Lua functions directly.
@mercury233 @purerosefallen Simplify
card::get_code()
,card::get_another_code()
card::second_code
Now cards with 2 original name are checked by looking up this table.data.code
This is the id in card database, which might be an id of alternative artwork.The types of card id are:
cards with 2 original name Lua table id: data.code code_rule1: data.code code_rule2: second_code[data.code]
always treated as X Lua table id: data.code code_rule1: data.alias code_rule2: 0
alternative artwork Lua table id: data.alias (The original card) code_rule1: data.alias code_rule2: 0
other Lua table id: data.code code_rule1: data.code code_rule2: 0
The Lua table id:
card::get_original_code()
code_rule1, code_rule2:card::get_original_code_rule()
Now
data.code
is not sent to Lua functions directly.