Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
no81cards
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Nemo Ma
no81cards
Commits
407a4981
Commit
407a4981
authored
Feb 11, 2023
by
Nemo Ma
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
75db966b
Changes
14
Show whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
128 additions
and
79 deletions
+128
-79
expansions/script/c10100000.lua
expansions/script/c10100000.lua
+83
-47
expansions/script/c10150051.lua
expansions/script/c10150051.lua
+7
-1
expansions/script/c10150096.lua
expansions/script/c10150096.lua
+4
-3
expansions/script/c10199990.lua
expansions/script/c10199990.lua
+3
-3
expansions/script/c11451638.lua
expansions/script/c11451638.lua
+0
-1
expansions/script/c40010612.lua
expansions/script/c40010612.lua
+3
-3
expansions/script/c40010616.lua
expansions/script/c40010616.lua
+3
-3
expansions/script/c40010620.lua
expansions/script/c40010620.lua
+8
-6
expansions/script/c59984652.lua
expansions/script/c59984652.lua
+5
-5
expansions/script/c60001142.lua
expansions/script/c60001142.lua
+2
-0
expansions/script/c60002119.lua
expansions/script/c60002119.lua
+5
-2
expansions/script/c6100013.lua
expansions/script/c6100013.lua
+1
-1
expansions/script/c79029817.lua
expansions/script/c79029817.lua
+2
-2
expansions/script/c79029819.lua
expansions/script/c79029819.lua
+2
-2
No files found.
expansions/script/c10100000.lua
View file @
407a4981
...
...
@@ -2,7 +2,7 @@
--the old library (c10199990.lua and c10199991.lua) has gone out of service, becuase it has become a SHIT MOUNTAIN, hard for reading.
--any problems, you can call me: QQ/VX 852415212, PLZ note sth. about YGO while you add me, otherwise I will reject your friend request.
local
Version_Number
=
"202
2.12.28
"
local
Version_Number
=
"202
3.02.09
"
--<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
--<<<<<<<<<<<<<<<<<<<<<<<<<<<<< Constant <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
...
...
@@ -370,13 +370,22 @@ function s.create_timing_list()
[
"BeUsedAsLinkMaterial&BeSent2GY"
]
=
{
EVENT_BE_MATERIAL
,
{
s
.
material_to_gy_or_be_banished
(
"Link"
,
"GY"
)
}
},
[
"BeUsedAsLinkMaterial&BeSent2GY/Banished"
]
=
{
EVENT_BE_MATERIAL
,
{
s
.
material_to_gy_or_be_banished
(
"Link"
,
"GY,Banished"
)
}
},
[
"BeTributed"
]
=
{
EVENT_RELEASE
},
[
"BeTarget"
]
=
{
EVENT_BECOME_TARGET
},
[
"BeTarget"
]
=
{
EVENT_BECOME_TARGET
},
[
"BeEffectTarget"
]
=
{
EVENT_BECOME_TARGET
},
[
"ActivateEffect"
]
=
{
EVENT_CHAINING
},
[
"BeforeEffectResolving"
]
=
{
EVENT_CHAIN_SOLVING
},
[
"AfterEffectResolving"
]
=
{
EVENT_CHAIN_SOLVED
},
[
"ChainEnd"
]
=
{
EVENT_CHAIN_END
},
[
"NegateActivation"
]
=
{
EVENT_CHAIN_NEGATED
}
[
"NegateActivation"
]
=
{
EVENT_CHAIN_NEGATED
},
[
"TakeDamage"
]
=
{
EVENT_DAMAGE
},
[
"YouTakeDamage"
]
=
{
EVENT_DAMAGE
,
scl
.
cond_check_rp
(
0
)
},
[
"OpponentTakesDamage"
]
=
{
EVENT_DAMAGE
,
scl
.
cond_check_rp
(
1
)
},
[
"InflictDamage2Opponent"
]
=
{
EVENT_DAMAGE
,
scl
.
cond_check_rp
(
1
)
},
[
"TakeBattleDamage"
]
=
{
EVENT_BATTLE_DAMAGE
},
[
"YouTakeBattleDamage"
]
=
{
EVENT_BATTLE_DAMAGE
,
scl
.
cond_check_rp
(
0
)
},
[
"OpponentTakesBattleDamage"
]
=
{
EVENT_DAMAGE
,
scl
.
cond_check_rp
(
1
)
},
[
"TakeEffectDamage"
]
=
{
EVENT_DAMAGE
,
scl
.
cond_check_r
(
0
,
"Effect"
)
},
[
"YouTakeEffectDamage"
]
=
{
EVENT_DAMAGE
,
aux
.
AND
(
scl
.
cond_check_r
(
0
,
"Effect"
),
scl
.
cond_check_rp
(
0
))
},
[
"OpponentTakesEffectDamage"
]
=
{
EVENT_DAMAGE
,
aux
.
AND
(
scl
.
cond_check_r
(
0
,
"Effect"
),
scl
.
cond_check_rp
(
1
))
}
}
...
...
@@ -617,7 +626,7 @@ function s.create_buff_list()
[
"!BeDestroyedByEffects"
]
=
{
EFFECT_INDESTRUCTABLE_EFFECT
},
[
"!BeDestroyedByBattle/Effects"
]
=
{
{
"!BeDestroyedByBattle"
,
"!BeDestroyedByEffects"
}
},
[
"UnaffectedByEffects"
]
=
{
EFFECT_IMMUNE_EFFECT
,
scl
.
value_unaffected_by_other_card_effects
},
[
"SpecialSumCondition"
]
=
{
EFFECT_SPSUMMON_CONDITION
},
[
"SpecialSum
mon
Condition"
]
=
{
EFFECT_SPSUMMON_CONDITION
},
[
"!BeUsedAsFusionMaterial"
]
=
{
EFFECT_CANNOT_BE_FUSION_MATERIAL
},
[
"!BeUsedAsMaterial4FusionSummon"
]
=
{
EFFECT_CANNOT_BE_FUSION_MATERIAL
,
s
.
cannot_be_fusion_summon_material_value
},
[
"!BeUsedAsSynchroMaterial"
]
=
{
EFFECT_CANNOT_BE_SYNCHRO_MATERIAL
},
...
...
@@ -1680,7 +1689,7 @@ end
-->>register 1 buff on the card c, the condition will forbid it be fusion material in any time any where.
-->>eg2. Scl.CreateSingleBuffCondition(c, "!FusionMaterial,!SynchroMaterial", 1)
-->>register 2 buff on the card c, the condition will forbid it be fusion and synchro material in any time any where.
-->>eg3. Scl.CreateSingleBuffCondition(c, "SpecialSumCondition", aux.FALSE)
-->>eg3. Scl.CreateSingleBuffCondition(c, "SpecialSum
mon
Condition", aux.FALSE)
-->>register 1 buff on the card c, the condition will forbid it be speical summoned from any where in any time.
function
Scl
.
CreateSingleBuffCondition
(
reg_obj
,
att_obj
,
val_obj
,
rng
,
con
,
rst_obj
,
desc_obj
,
lim_obj
,
flag
)
local
flag2
=
Scl
.
GetNumFormatProperty
(
flag
)
...
...
@@ -1891,14 +1900,14 @@ end
--<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
--Creat a Spell/Trap's activate effect.
--Creat
e
a Spell/Trap's activate effect.
--code default == EVENT_FREE_CHAIN
--desc_obj default == DESC_ACTIVATE_SCL
--if the register handler is a Trap or Quick Play Spell, tmg_obj will automatic set to { 0, TIMINGS_CHECK_MONSTER + TIMING_END_PHASE }.
--other parama format : see Scl.CreateEffect
--//return effect, effect id
-->>eg1. Scl.CreateActivateEffect(c, nil, nil, {1, "Oath"}, "Search,Add2Hand", nil, nil, nil, s.tg, s.op)
-->>register a activate effect to card c, it can only activate once per turn, it is an searcher.
-->>register a
n
activate effect to card c, it can only activate once per turn, it is an searcher.
-->>return effect, effect id
function
Scl
.
CreateActivateEffect
(
reg_obj
,
code
,
desc_obj
,
lim_obj
,
ctgy
,
flag
,
con
,
cost
,
tg
,
op
,
tmg_obj
,
rst_obj
)
local
_
,
handler
=
Scl
.
GetRegisterInfo
(
reg_obj
)
...
...
@@ -2541,7 +2550,7 @@ end
--//return effect
-->>eg1. Scl.CreateSingleTriggerContinousEffect_DestroyReplace(c, 1, LOCATION_MZONE, nil, s.tg, s.op)
-->>If card c is destroyed by any ways except replace, you can do s.tg and s.op to replace the destroy.
function
Scl
.
CreateSingleTriggerContinousEffect_DestroyReplace
(
reg_obj
,
lim_obj
,
rng
,
repfilter
,
tg
,
op
,
con
,
rst_obj
,
flag
)
function
Scl
.
CreateSingleTriggerContinousEffect_DestroyReplace
(
reg_obj
,
lim_obj
,
rng
,
repfilter
,
tg
,
op
,
con
,
flag
,
rst_obj
)
local
flag2
=
Scl
.
GetNumFormatProperty
(
flag
)
local
e1
=
Scl
.
CreateSingleTriggerContinousEffect
(
reg_obj
,
EFFECT_DESTROY_REPLACE
,
nil
,
lim_obj
,
flag2
|
EFFECT_FLAG_SINGLE_RANGE
,
con
,
op
,
rst_obj
)
e1
:
SetTarget
(
s
.
create_single_trigger_continous_effect_destroy_replace_tg
(
repfilter
or
aux
.
TRUE
,
tg
))
...
...
@@ -2581,9 +2590,9 @@ end
--//return effect
-->>eg1. Scl.CreateFieldTriggerContinousEffect_DestroyReplace(c, 1, LOCATION_MZONE, nil, s.tg, s.op)
-->>If a card(s) meet s.tg(chk == 0) is destroyed by any ways except replace, you can do s.tg and s.op to replace the destroy.
function
Scl
.
CreateFieldTriggerContinousEffect_DestroyReplace
(
reg_obj
,
lim_obj
,
r
ange
,
repfilter
,
tg
,
op
,
con
,
force
,
flag
,
rst_obj
)
function
Scl
.
CreateFieldTriggerContinousEffect_DestroyReplace
(
reg_obj
,
lim_obj
,
r
ng
,
repfilter
,
tg
,
op
,
con
,
force
,
flag
,
rst_obj
)
repfilter
=
repfilter
or
aux
.
TRUE
local
e1
=
Scl
.
CreateFieldTriggerContinousEffect
(
reg_obj
,
EFFECT_DESTROY_REPLACE
,
nil
,
lim_obj
,
nil
,
r
ange
,
con
,
op
,
rst_obj
)
local
e1
=
Scl
.
CreateFieldTriggerContinousEffect
(
reg_obj
,
EFFECT_DESTROY_REPLACE
,
nil
,
lim_obj
,
nil
,
r
ng
,
con
,
op
,
rst_obj
)
e1
:
SetValue
(
s
.
create_field_trigger_continous_effect_destroy_replace_value
(
repfilter
))
e1
:
SetTarget
(
s
.
create_field_trigger_continous_effect_destroy_replace_tg
(
repfilter
,
tg
,
force
))
local
g
=
Group
.
CreateGroup
()
...
...
@@ -2921,9 +2930,9 @@ end
--Nested function
--value for "this card cannot be special summoned from extra, except by Scl.Summon_Type_List[sum_str][1]"
--usually use in EFFECT_SPSUMMON_CONDITION.
-->>eg1. scl.value_spsummon_from_extra("LinkSummon")(e, se, sp, st)
-->>eg1. scl.value_sp
ecial_
summon_from_extra("LinkSummon")(e, se, sp, st)
-->>"This card cannot be special summoned from extra, except by Link Summon".
function
scl
.
value_spsummon_from_extra
(
sum_str
)
function
scl
.
value_sp
ecial_
summon_from_extra
(
sum_str
)
return
function
(
e
,
se
,
sp
,
st
)
local
st2
=
Scl
.
Summon_Type_List
[
sum_str
]
return
not
e
:
GetHandler
():
IsLocation
(
LOCATION_EXTRA
)
or
st
&
st2
==
st2
...
...
@@ -2931,7 +2940,7 @@ function scl.value_spsummon_from_extra(sum_str)
end
--Value for "this card can only be special summoned by card effect".
--usually use in EFFECT_SPSUMMON_CONDITION.
function
scl
.
value_spsummon_by_card_effects
(
e
,
se
,
sp
,
st
)
function
scl
.
value_sp
ecial_
summon_by_card_effects
(
e
,
se
,
sp
,
st
)
--ygocore's official script has bug when VS EFFECT_SPSUMMON_PROC
--return se:IsHasType(EFFECT_TYPE_ACTIONS)
return
not
se
:
IsHasProperty
(
EFFECT_FLAG_UNCOPYABLE
)
...
...
@@ -2939,9 +2948,9 @@ end
--Nested function
--value for "include a reason (battle/cost/material/effect ...)"
--will call Scl.IsReason(nil, ...) to check if "r" include your point reason(s), paramas see Scl.IsReason
-->>eg1. scl.value_
reason
(0, REASON_BATTLE/"Battle")
-->>eg1. scl.value_
check_r
(0, REASON_BATTLE/"Battle")
-->>check if r include REASON_BATTLE
function
scl
.
value_
reason
(
...
)
function
scl
.
value_
check_r
(
...
)
local
arr
=
{
...
}
return
function
(
e
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
...
...
@@ -2987,7 +2996,7 @@ function scl.value_unaffected_by_other_untarget_effects(e, re)
return
true
end
--value for "immune to your opponent's card's effects that do not target this card".
function
scl
.
value_unaffected_by_opponents_untarget_effects
(
e
,
re
)
function
scl
.
value_unaffected_by_opponents_untarget_
self_
effects
(
e
,
re
)
local
c
=
e
:
GetHandler
()
local
ec
=
re
:
GetHandler
()
if
re
:
GetHandlerPlayer
()
==
e
:
GetHandlerPlayer
()
or
ec
:
IsHasCardTarget
(
c
)
or
(
re
:
IsHasType
(
EFFECT_TYPE_ACTIONS
)
and
re
:
IsHasProperty
(
EFFECT_FLAG_CARD_TARGET
)
and
c
:
IsRelateToEffect
(
re
))
then
return
false
...
...
@@ -3883,6 +3892,31 @@ function scl.cost_once_per_chain(flag_code, player_lim)
end
end
end
--Nested function
--condition: if player_idx == 0, check rp == tp, else check rp ~= tp
function
scl
.
cond_check_rp
(
player_idx
)
return
function
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
player_idx
==
0
then
return
rp
==
tp
elseif
player_idx
==
1
then
return
rp
~=
tp
end
return
false
end
end
--Nested function
--will call Scl.IsReason(nil, ...) to check if "r" include your point reason(s), paramas see Scl.IsReason
-->>eg1. scl.cond_check_r(0, REASON_EFFECT/"Effect")
-->>check if "r" has REASON_EFFECT
function
scl
.
cond_check_r
(
...
)
local
arr
=
{
...
}
return
function
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Scl
.
Global_Reason
=
r
local
res
=
Scl
.
IsReason
(
nil
,
table.unpack
(
arr
))
Scl
.
Global_Reason
=
nil
return
res
end
end
--condition: during your turn
function
scl
.
cond_during_your_turn
(
e
)
return
Duel
.
GetTurnPlayer
()
==
e
:
GetHandlerPlayer
()
...
...
@@ -3891,6 +3925,10 @@ end
function
scl
.
cond_during_opponents_turn
(
e
)
return
Duel
.
GetTurnPlayer
()
~=
e
:
GetHandlerPlayer
()
end
--condition: previous faceup
function
scl
.
cond_previous_faceup
(
e
)
return
e
:
GetHandler
():
IsPreviousPosition
(
POS_FACEUP
)
end
--Nested function
--condition: in XXX Phase
--the format of ... : phase_str1, player1, phase_str2, player2, ... ("Or" check)
...
...
@@ -3937,34 +3975,8 @@ function scl.cond_during_phase(...)
if
not
res
then
return
false
end
end
return
true
end
end
--Nested function
--condtion: because of ... reason(s)
--will call Scl.IsReason(c, ...) to check if the effect handler include your point reason(s), paramas see Scl.IsReason
-->>eg1. scl.cond_reason(REASON_BATTLE)
-->>check if the effect handler include the battle reason.
function
scl
.
cond_is_reason
(
...
)
local
reason_arr
=
{
...
}
return
function
(
e
)
return
Scl
.
IsReason
(
e
:
GetHandler
(),
table.unpack
(
reason_arr
))
end
end
--Nested function
--condition: previous faceup leaves the field, because of ... reason(s)
--will call Scl.IsReason(c, ...) to check if the effect handler include your point reason(s), paramas see Scl.IsReason
-->>eg1. scl.cond_previous_faceup(REASON_BATTLE)
-->>check if the effect handler is faceup leaves the field, because of battle.
function
scl
.
cond_faceup_leaves
(
...
)
local
reason_arr
=
{
...
}
return
function
(
e
)
local
c
=
e
:
GetHandler
()
if
#
reason_arr
>
0
and
not
Scl
.
IsReason
(
c
,
table.unpack
(
reason_arr
))
then
return
false
end
return
c
:
IsPreviousPosition
(
POS_FACEUP
)
end
end
--Nested function
...
...
@@ -3990,9 +4002,9 @@ end
--Nested function
--condition: is special summoned from "zone_obj"
--player (default == nil): if == 0, means from your zone(s), if == 1, means from your opponent's zone(s), if == nil, means from any player's zone(s).
-->>eg1. scl.con
_is_spsummon_from("Hand", player
)
-->>eg1. scl.con
d_is_special_summon_from("Hand"
)
-->>check if this card is special summon from hand.
function
scl
.
con
_is_sp
summon_from
(
zone_obj
,
player
)
function
scl
.
con
d_is_special_
summon_from
(
zone_obj
,
player
)
return
function
(
e
)
local
c
=
e
:
GetHandler
()
return
c
:
IsSummonType
(
SUMMON_TYPE_SPECIAL
)
and
Scl
.
IsPreviouslyInZone
(
c
,
zone_obj
)
and
(
not
player
or
(
player
==
0
and
c
:
IsPreviousControler
(
tp
))
or
(
player
==
1
and
c
:
IsPreviousControler
(
1
-
tp
)))
...
...
@@ -5362,6 +5374,19 @@ function s.get_target_releate_filter(c, filter, ...)
if
not
c
:
IsRelateToChain
()
then
return
false
end
return
filter
(
c
,
...
)
end
--Get target player and that num-format value for an effect that register player target information in Effect.SetTarget
--//return target player, target value
--[[
>>eg1. Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(1000)
Scl.GetPlayerTargetParamas()
>> return tp, 1000
--]]
function
Scl
.
GetPlayerTargetParamas
()
local
player
,
value
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
,
CHAININFO_TARGET_PARAM
)
Duel
.
Draw
(
p
,
d
,
REASON_EFFECT
)
return
player
,
value
end
--Add normal summon or set procedure
--parama see Scl.AddNormalSummonProcedure and Scl.AddNormalSetProcedure
--//return summon effect
...
...
@@ -5492,7 +5517,15 @@ function s.summon_count_limit_tg(sum_typ_str)
return
c
:
IsCode
(
e
:
GetHandler
():
GetOriginalCodeRule
())
and
sum_typ
&
sum_typ2
==
sum_typ2
end
end
--speical "aux.AddSynchroMixProcedure"
--Special add fusion material record
--now equal to Auxiliary.AddFusionProcMixRep + EnableReviveLimit()
-->>eg1. Scl.SetFusionMaterial(c, false, false, 114514, 1, 3, s.filter, 2, 2)
-->>this fusion monster needs 1~3 monsters witch name is 114514, and 2 other monsters meets s.filter(c, fc) as materials to fusion summon it.
function
Scl
.
SetFusionMaterial
(
c
,
instant_fusion_able
,
replace_name_able
,
...
)
c
:
EnableReviveLimit
()
return
aux
.
AddFusionProcMixRep
(
c
,
instant_fusion_able
,
replace_name_able
,
...
)
end
--Speical "aux.AddSynchroMixProcedure"
--can call some scl's custom functions in the procedure, like extra synchro material, dark synchro, custom level synchro, custom synchro material action, and so on
--return summon effect
function
Scl
.
AddSynchroProcedure
(
c
,
f1
,
f2
,
f3
,
f4
,
minc
,
maxc
,
gc
)
...
...
@@ -6848,4 +6881,7 @@ Scl.RaiseGlobalSetEvent()
2022.12.28 fix EFFECT_ACTIVATE_SPELL_AND_TRAP_FROM_ANY_ZONE_SCL
Add an zone check (current zone == activate zone) before cost check. (due to 130006007 "决斗者的最后之日" can activate in any zone.)
2022.02.09 fix some format error cause the library cannot be correct read.
--]]
\ No newline at end of file
expansions/script/c10150051.lua
View file @
407a4981
--邪心英雄 堕影魔王
function
c10150051
.
initial_effect
(
c
)
aux
.
AddCodeList
(
c
,
94820406
)
--fusion material
c
:
EnableReviveLimit
()
aux
.
AddFusionProcCodeFun
(
c
,
10150070
,
aux
.
FilterBoolFunction
(
Card
.
IsRace
,
RACE_FIEND
),
1
,
true
,
true
)
...
...
@@ -74,14 +75,19 @@ function c10150051.atkop(e,tp,eg,ep,ev,re,r,rp)
e2
:
SetRange
(
LOCATION_MZONE
)
e2
:
SetCode
(
EFFECT_IMMUNE_EFFECT
)
e2
:
SetReset
(
RESET_EVENT
+
0x1fe0000
+
RESET_PHASE
+
PHASE_END
,
2
)
e2
:
SetCondition
(
c10150051
.
econ
)
e2
:
SetValue
(
c10150051
.
efilter
)
e2
:
SetOwnerPlayer
(
tp
)
tc
:
RegisterEffect
(
e2
)
end
end
function
c10150051
.
econ
(
e
)
return
Duel
.
GetCurrentPhase
()
~=
PHASE_MAIN2
end
function
c10150051
.
efilter
(
e
,
re
)
return
e
:
GetOwnerPlayer
()
~=
re
:
GetOwnerPlayer
()
end
function
c10150051
.
splimit
(
e
,
se
,
sp
,
st
)
return
st
==
SUMMON_TYPE_FUSION
+
0x10
return
se
:
GetHandler
():
IsCode
(
94820406
)
or
Duel
.
IsPlayerAffectedByEffect
(
sp
,
72043279
)
and
st
&
SUMMON_TYPE_FUSION
==
SUMMON_TYPE_FUSION
end
expansions/script/c10150096.lua
View file @
407a4981
...
...
@@ -73,10 +73,11 @@ function cm.act(e,tp)
local
code
,
race
,
att
,
lv
,
atk
,
def
=
table.unpack
(
mat
)
local
tk
=
Duel
.
CreateToken
(
tp
,
86871615
)
local
e1
=
rsef
.
SV_LIMIT
({
c
,
tk
,
true
},
"ress"
,
nil
,
nil
,
rsreset
.
est
-
RESET_TOFIELD
)
rscf
.
QuickBuff
({
c
,
tk
,
true
},
"code"
,
code
,
"lv"
,
lv
,
"race"
,
race
,
"att"
,
att
,
"batk"
,
atk
,
"bdef"
,
def
,
"rst"
,
rsreset
.
est
-
RESET_TOFIELD
)
Duel
.
SpecialSummonStep
(
tk
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP_DEFENSE
)
Scl
.
AddSingleBuff
(
nil
,
"=Name"
,
code
,
"=Level"
,
lv
,
"=Race"
,
race
,
"=Attribute"
,
att
,
"=BaseATK"
,
atk
,
"=BaseDEF"
,
def
,
"Reset"
,
RESETS_SCL
-
RESET_TOFIELD
)
--rscf.QuickBuff({c,tk,true},"code",code,"lv",lv,"race",race,"att",att,"batk",atk,"bdef",def,"rst",rsreset.est-RESET_TOFIELD)
Scl
.
SpecialSummonStep
(
tk
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP_DEFENSE
)
end
Due
l
.
SpecialSummonComplete
()
Sc
l
.
SpecialSummonComplete
()
end
function
cm
.
splimit
(
e
,
c
,
sump
,
sumtype
,
sumpos
,
targetp
,
se
)
if
not
c
:
IsLocation
(
LOCATION_EXTRA
)
then
return
false
end
...
...
expansions/script/c10199990.lua
View file @
407a4981
...
...
@@ -666,8 +666,8 @@ end
function
rssf
.
SpecialSummonEither
(
sum_card
,
sum_eff
,
sum_typ
,
sum_pl
,
loc_pl
,
ignore_con
,
ignore_revie
,
pos
,
sum_zone
)
return
Scl
.
SpecialSummon2EitherFieldStep
(
sum_card
,
sum_typ
,
sum_pl
,
ignore_con
,
ignore_revie
,
pos
,
sum_zone
)
end
rsval
.
spconfe
=
scl
.
value_spsummon_from_extra
(
"SpecialSummon"
)
rsval
.
spconbe
=
scl
.
value_spsummon_by_card_effects
rsval
.
spconfe
=
scl
.
value_sp
ecial_
summon_from_extra
(
"SpecialSummon"
)
rsval
.
spconbe
=
scl
.
value_sp
ecial_
summon_by_card_effects
function
rsval
.
indbae
(
str1
,
str2
)
if
not
str1
and
not
str2
then
str1
=
"Battle"
...
...
@@ -931,7 +931,7 @@ rscon.turns = scl.cond_during_your_turn
rscon
.
turno
=
scl
.
cond_during_opponents_turn
rscon
.
phmp
=
scl
.
cond_during_phase
(
"M1,M2"
)
rscon
.
phbp
=
scl
.
cond_during_phase
(
"BP"
)
rscon
.
prepup
=
scl
.
cond_
faceup_leaves
()
rscon
.
prepup
=
scl
.
cond_
previous_faceup
function
rstg
.
chnlim
(
sp
,
op
)
return
function
(
g
,
e
,
tp
)
Duel
.
SetChainLimit
(
rsval
.
chainlimit
(
sp
,
op
,
g
))
...
...
expansions/script/c11451638.lua
View file @
407a4981
...
...
@@ -14,7 +14,6 @@ function cm.initial_effect(c)
--set
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
11451631
,
6
))
e2
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
e2
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_O
)
e2
:
SetProperty
(
EFFECT_FLAG_DELAY
)
e2
:
SetRange
(
LOCATION_HAND
+
LOCATION_GRAVE
)
...
...
expansions/script/c40010612.lua
View file @
407a4981
...
...
@@ -57,13 +57,13 @@ function cm.spgfilter(c,e,tp)
return
c
:
IsAttribute
(
ATTRIBUTE_DARK
)
and
c
:
IsRace
(
RACE_ROCK
)
and
c
:
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
end
function
cm
.
tgop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
lg
=
Duel
.
GetMatchingGroup
(
cm
.
cfilter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TOGRAVE
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
tgfilter
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
)
if
g
:
GetCount
()
>
0
then
local
sg
=
Duel
.
GetMatchingGroup
(
cm
.
spgfilter
,
tp
,
LOCATION_HAND
,
0
,
nil
,
e
,
tp
)
if
Duel
.
SendtoGrave
(
g
,
REASON_EFFECT
)
>
0
then
if
sg
:
GetCount
()
>
0
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
m
,
1
))
and
lg
:
GetClassCount
(
Card
.
GetLevel
)
>=
3
then
if
Duel
.
SendtoGrave
(
g
,
REASON_EFFECT
)
~=
0
then
local
lg
=
Duel
.
GetMatchingGroup
(
cm
.
cfilter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
if
sg
:
GetCount
()
>
0
and
lg
:
GetClassCount
(
Card
.
GetLevel
)
>=
3
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
m
,
1
))
then
Duel
.
BreakEffect
()
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SPSUMMON
)
local
spg
=
sg
:
Select
(
tp
,
1
,
1
,
nil
)
...
...
expansions/script/c40010616.lua
View file @
407a4981
...
...
@@ -31,13 +31,13 @@ function cm.thfilter(c)
return
aux
.
IsCodeListed
(
c
,
40010618
)
and
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
IsAbleToHand
()
and
not
c
:
IsCode
(
m
)
end
function
cm
.
tgop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
lg
=
Duel
.
GetMatchingGroup
(
cm
.
cfilter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TOGRAVE
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
tgfilter
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
)
if
g
:
GetCount
()
>
0
then
local
tg
=
Duel
.
GetMatchingGroup
(
cm
.
thfilter
,
tp
,
LOCATION_DECK
,
0
,
nil
)
if
Duel
.
SendtoGrave
(
g
,
REASON_EFFECT
)
>
0
then
if
tg
:
GetCount
()
>
0
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
m
,
1
))
and
lg
:
GetClassCount
(
Card
.
GetLevel
)
>=
3
then
if
Duel
.
SendtoGrave
(
g
,
REASON_EFFECT
)
~=
0
then
local
lg
=
Duel
.
GetMatchingGroup
(
cm
.
cfilter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
if
tg
:
GetCount
()
>
0
and
lg
:
GetClassCount
(
Card
.
GetLevel
)
>=
3
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
m
,
1
))
then
Duel
.
BreakEffect
()
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
local
stg
=
tg
:
Select
(
tp
,
1
,
1
,
nil
)
...
...
expansions/script/c40010620.lua
View file @
407a4981
...
...
@@ -72,14 +72,16 @@ function cm.thfilter(c,e,tp)
return
c
:
IsType
(
TYPE_MONSTER
)
and
aux
.
IsCodeListed
(
c
,
40010618
)
and
not
c
:
IsCode
(
m
)
and
c
:
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
end
function
cm
.
spop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
lg
=
Duel
.
GetMatchingGroup
(
cm
.
cgfilter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
local
c
=
e
:
GetHandler
()
if
c
:
IsRelateToEffect
(
e
)
and
Duel
.
SpecialSummon
(
c
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
>
0
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
m
,
0
))
and
lg
:
GetClassCount
(
Card
.
GetLevel
)
>=
3
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
Duel
.
IsExistingMatchingCard
(
cm
.
thfilter
,
tp
,
LOCATION_DECK
,
0
,
1
,
nil
,
e
,
tp
)
then
if
c
:
IsRelateToEffect
(
e
)
and
Duel
.
SpecialSummon
(
c
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
~=
0
then
local
lg
=
Duel
.
GetMatchingGroup
(
cm
.
cgfilter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
if
lg
:
GetClassCount
(
Card
.
GetLevel
)
>=
3
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
Duel
.
IsExistingMatchingCard
(
cm
.
thfilter
,
tp
,
LOCATION_DECK
,
0
,
1
,
nil
,
e
,
tp
)
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
m
,
0
))
then
Duel
.
BreakEffect
()
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SPSUMMON
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
thfilter
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
,
e
,
tp
)
Duel
.
SpecialSummon
(
g
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
end
end
end
function
cm
.
fusop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
...
...
expansions/script/c59984652.lua
View file @
407a4981
...
...
@@ -104,13 +104,13 @@ function s.filter2(c)
return
c
:
IsSetCard
(
0xbd
)
and
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
IsAbleToHand
()
and
c
:
IsLevel
(
7
)
end
function
s
.
thtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
aux
.
NecroValleyFilter
(
s
.
filter1
),
tp
,
LOCATION_DECK
+
LOCATION_GRAVE
,
0
,
1
,
nil
)
and
Duel
.
IsExistingMatchingCard
(
aux
.
NecroValleyFilter
(
s
.
filter2
),
tp
,
LOCATION_DECK
+
LOCATION_GRAVE
,
0
,
1
,
nil
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
nil
,
2
,
tp
,
LOCATION_DECK
+
LOCATION_GRAVE
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
aux
.
NecroValleyFilter
(
s
.
filter1
),
tp
,
LOCATION_DECK
,
0
,
1
,
nil
)
and
Duel
.
IsExistingMatchingCard
(
aux
.
NecroValleyFilter
(
s
.
filter2
),
tp
,
LOCATION_DECK
,
0
,
1
,
nil
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
nil
,
2
,
tp
,
LOCATION_DECK
)
end
function
s
.
thop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
g1
=
Duel
.
GetMatchingGroup
(
aux
.
NecroValleyFilter
(
s
.
filter1
),
tp
,
LOCATION_DECK
+
LOCATION_GRAVE
,
0
,
nil
)
local
g2
=
Duel
.
GetMatchingGroup
(
aux
.
NecroValleyFilter
(
s
.
filter2
),
tp
,
LOCATION_DECK
+
LOCATION_GRAVE
,
0
,
nil
)
local
g1
=
Duel
.
GetMatchingGroup
(
aux
.
NecroValleyFilter
(
s
.
filter1
),
tp
,
LOCATION_DECK
,
0
,
nil
)
local
g2
=
Duel
.
GetMatchingGroup
(
aux
.
NecroValleyFilter
(
s
.
filter2
),
tp
,
LOCATION_DECK
,
0
,
nil
)
if
g1
:
GetCount
()
>
0
and
g2
:
GetCount
()
>
0
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
local
sg1
=
g1
:
Select
(
tp
,
1
,
1
,
nil
)
...
...
expansions/script/c60001142.lua
View file @
407a4981
...
...
@@ -11,6 +11,7 @@ function cm.initial_effect(c)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_O
)
e1
:
SetProperty
(
EFFECT_FLAG_DELAY
)
e1
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
e1
:
SetCountLimit
(
1
,
m
)
e1
:
SetCondition
(
cm
.
con1
)
e1
:
SetTarget
(
cm
.
tg1
)
e1
:
SetOperation
(
cm
.
op1
)
...
...
@@ -20,6 +21,7 @@ function cm.initial_effect(c)
e2
:
SetType
(
EFFECT_TYPE_QUICK_O
)
e2
:
SetCode
(
EVENT_FREE_CHAIN
)
e2
:
SetRange
(
LOCATION_GRAVE
)
e2
:
SetCountLimit
(
1
,
m
)
e2
:
SetCost
(
aux
.
bfgcost
)
e2
:
SetTarget
(
cm
.
tg2
)
e2
:
SetOperation
(
cm
.
op2
)
...
...
expansions/script/c60002119.lua
View file @
407a4981
...
...
@@ -28,7 +28,10 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
tgfilter
,
tp
,
LOCATION_EXTRA
,
0
,
1
,
1
,
nil
)
if
g
:
GetCount
()
>
0
then
Duel
.
SendtoGrave
(
g
,
REASON_EFFECT
)
end
if
Duel
.
GetTurnCount
()
>=
2
then
local
p
,
d
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
,
CHAININFO_TARGET_PARAM
)
Duel
.
Draw
(
p
,
d
,
REASON_EFFECT
)
end
end
end
\ No newline at end of file
expansions/script/c6100013.lua
View file @
407a4981
...
...
@@ -89,7 +89,7 @@ function cm.imop(e,tp,eg,ep,ev,re,r,rp)
local
c
=
e
:
GetHandler
()
local
tc
=
Duel
.
GetFirstTarget
()
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
tdfilter
,
tp
,
LOCATION_REMOVED
,
0
,
1
,
1
,
nil
)
if
tc
:
IsRelateToEffect
(
e
)
and
Duel
.
SendtoDeck
(
g
,
2
,
REASON_EFFECT
)
then
if
tc
:
IsRelateToEffect
(
e
)
and
Duel
.
SendtoDeck
(
g
,
nil
,
2
,
REASON_EFFECT
)
then
--cannot target
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
...
...
expansions/script/c79029817.lua
View file @
407a4981
...
...
@@ -79,7 +79,7 @@ function c79029817.dsop(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c79029817
.
xyzfilter
(
c
,
g
)
return
c
:
IsRace
(
RACE_MACHINE
)
and
c
:
IsXyzSummonable
(
g
)
return
c
:
IsRace
(
RACE_MACHINE
)
and
c
:
IsXyzSummonable
(
g
,
1
,
99
)
end
function
c79029817
.
xyztg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
g
=
Duel
.
GetMatchingGroup
(
Card
.
IsSetCard
,
tp
,
LOCATION_MZONE
,
0
,
nil
,
0xa991
)
...
...
@@ -92,7 +92,7 @@ function c79029817.xyzop(e,tp,eg,ep,ev,re,r,rp)
if
g
:
GetCount
()
>
0
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SPSUMMON
)
local
tg
=
g
:
Select
(
tp
,
1
,
1
,
nil
)
Duel
.
XyzSummon
(
tp
,
tg
:
GetFirst
(),
xg
)
Duel
.
XyzSummon
(
tp
,
tg
:
GetFirst
(),
xg
,
1
,
99
)
end
end
expansions/script/c79029819.lua
View file @
407a4981
...
...
@@ -54,8 +54,8 @@ function c79029819.ovfilter(c)
end
function
c79029819
.
xyzop
(
e
,
tp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c79029819
.
cfilter
,
tp
,
LOCATION_HAND
+
LOCATION_REMOVED
,
0
,
1
,
nil
)
end
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c79029819
.
cfilter
,
tp
,
LOCATION_HAND
+
LOCATION_REMOVED
,
0
,
1
,
1
,
nil
)
Duel
.
SendtoDeck
(
g
,
nil
,
2
,
REASON_COST
)
local
tc
=
Duel
.
SelectMatchingCard
(
tp
,
c79029819
.
cfilter
,
tp
,
LOCATION_HAND
+
LOCATION_REMOVED
,
0
,
1
,
1
,
nil
):
GetFirst
(
)
Duel
.
SendtoDeck
(
tc
,
nil
,
2
,
REASON_COST
)
end
function
c79029819
.
thcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
IsSummonType
(
SUMMON_TYPE_XYZ
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment