Jamster26
2016-02-07T13:44:48Z
Hey,

So I wanted to know if any scripters out there would be able to script a card for me(which I imagine would work like an invisible field spell that activates at the start of the duel), that allows the person the option to summon monsters in face up defense position.

This is used allot in the anime and is actually pretty integral to allot of strategies.

I guess this would work using the base effect of Light of Intervention?

I am no scripter though and have no idea how to do this. If anyone would be able to help me with this, I would very much appreciate it.

EDIT: I had a look around the forum, and it seems someone attempted to make this script three years ago, however, when I add the script and pack.cdb into expansions folder, the card appears as ??? in the game with no picture. Here is the script, can anyone help modify it?

function c99999999.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_DISABLE_CHAIN)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_PHASE_START+PHASE_DRAW)
e1:SetCountLimit(1)
e1:SetRange(LOCATION_HAND+LOCATION_DECK)
e1:SetTarget(c99999999.target)
e1:SetOperation(c99999999.operation)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetRange(LOCATION_REMOVED)
e2:SetCode(EFFECT_DEVINE_LIGHT)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetTargetRange(1,1)
c:RegisterEffect(e2)
end
function c99999999.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(1)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
end
function c99999999.operation(e,tp,eg,ep,ev,re,r,rp)
if chk==0 then return e:GetHandler():IsAbleToRemoveAsCost() end
Duel.Remove(e:GetHandler(),POS_FACEUP,REASON_COST)
if e:GetHandler():IsPreviousLocation(LOCATION_HAND) then
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Draw(p,d,REASON_EFFECT)
end
end
YGOPRO Tournament Groups:
Evolve Group 
Facebook Group 
[YOL]Edo9300
2016-02-07T19:30:27Z
Originally Posted by: Jamster26 

Hey,

So I wanted to know if any scripters out there would be able to script a card for me(which I imagine would work like an invisible field spell that activates at the start of the duel), that allows the person the option to summon monsters in face up defense position.

This is used allot in the anime and is actually pretty integral to allot of strategies.

I guess this would work using the base effect of Light of Intervention?

I am no scripter though and have no idea how to do this. If anyone would be able to help me with this, I would very much appreciate it.

EDIT: I had a look around the forum, and it seems someone attempted to make this script three years ago, however, when I add the script and pack.cdb into expansions folder, the card appears as ??? in the game with no picture. Here is the script, can anyone help modify it?

function c99999999.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_DISABLE_CHAIN)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_PHASE_START+PHASE_DRAW)
e1:SetCountLimit(1)
e1:SetRange(LOCATION_HAND+LOCATION_DECK)
e1:SetTarget(c99999999.target)
e1:SetOperation(c99999999.operation)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetRange(LOCATION_REMOVED)
e2:SetCode(EFFECT_DEVINE_LIGHT)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetTargetRange(1,1)
c:RegisterEffect(e2)
end
function c99999999.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(1)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
end
function c99999999.operation(e,tp,eg,ep,ev,re,r,rp)
if chk==0 then return e:GetHandler():IsAbleToRemoveAsCost() end
Duel.Remove(e:GetHandler(),POS_FACEUP,REASON_COST)
if e:GetHandler():IsPreviousLocation(LOCATION_HAND) then
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Draw(p,d,REASON_EFFECT)
end
end



i checked the script, and the only ones things missing i've found are the conditions that doesn't allow you to set monster. Maybe you have a wrong cdb file, so the card isn't shown properly. This is the modified script:
Quote:

function c99999999.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_CANNOT_DISABLE+EFFECT_DISABLE_CHAIN)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_PHASE_START+PHASE_DRAW)
e1:SetCountLimit(1)
e1:SetRange(LOCATION_HAND+LOCATION_DECK)
e1:SetTarget(c99999999.target)
e1:SetOperation(c99999999.operation)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetRange(LOCATION_REMOVED)
e2:SetCode(EFFECT_DEVINE_LIGHT)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetTargetRange(1,1)
c:RegisterEffect(e2)
--cannot mset
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD)
e3:SetRange(LOCATION_REMOVED)
e3:SetCode(EFFECT_CANNOT_MSET)
e3:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e3:SetTargetRange(1,1)
c:RegisterEffect(e3)
--cannot turn set
local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD)
e4:SetCode(EFFECT_CANNOT_TURN_SET)
e4:SetRange(LOCATION_REMOVED)
e4:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE)
c:RegisterEffect(e4)
end
function c99999999.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(1)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
end
function c99999999.operation(e,tp,eg,ep,ev,re,r,rp)
if chk==0 then return e:GetHandler():IsAbleToRemoveAsCost() end
Duel.Remove(e:GetHandler(),POS_FACEUP,REASON_COST)
if e:GetHandler():IsPreviousLocation(LOCATION_HAND) then
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Draw(p,d,REASON_EFFECT)
end
end



P.S. you've posted in the wrong section, the correct section is this: https://www.ygopro.co/Forum/tabid/95/g/topics/f/16/Card-scripts 
Gamemaster719
2016-03-23T00:18:27Z
Ok on this topic i wanted to do the same thing - the ability to set monsters face up-

so I see a script above- but can some one provide a bit more of an explanation on getting this to work-

such as a card-cdb with this card ...


or even the data input ( I can manually enter it in sqlite-) id say id trial and error it but figured asking would be good so if someone else wants to know they could read the explanation-


Thanks-