Generate a YGOPro Lua script for the following Yu-Gi-Oh card effect:
Each time a player rolls a die (or dice), you can choose 1 die result, and apply the appropriate effect, based on the result. ● 1, 3, or 5: The die result is treated as 6. ● 2, 4, or 6: The die result is treated as 1.
--出たら目
--That Six
local s,id=GetID()
function s.initial_effect(c)
	--Activate
	local e1=Effect.CreateEffect(c)
	e1:SetType(EFFECT_TYPE_ACTIVATE)
	e1:SetCode(EVENT_FREE_CHAIN)
	c:RegisterEffect(e1)
	--Change die result
	local e2=Effect.CreateEffect(c)
	e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
	e2:SetCode(EVENT_TOSS_DICE_NEGATE)
	e2:SetRange(LOCATION_SZONE)
	e2:SetOperation(s.diceop)
	c:RegisterEffect(e2)
end
function s.diceop(e,tp,eg,ep,ev,re,r,rp)
	local cc=Duel.GetCurrentChain()
	local cid=Duel.GetChainInfo(cc,CHAININFO_CHAIN_ID)
	if s[0]~=cid and Duel.SelectYesNo(tp,aux.Stringid(id,0)) then
			local dc={Duel.GetDiceResult()}
			local ac=1
			local ct=(ev&0xff)+(ev>>16)
			Duel.Hint(HINT_CARD,0,id)
			if ct>1 then
				local val,idx=Duel.AnnounceNumber(tp,table.unpack(dc,1,ct))
				ac=idx+1
			end
			if dc[ac]==1 or dc[ac]==3 or dc[ac]==5 then	dc[ac]=6
			else dc[ac]=1 end
		Duel.SetDiceResult(table.unpack(dc))
		s[0]=cid
	end
end