Married System
:: Tibia :: Tibia Dicas/Tutoriais :: Tutoriais Otserv.
Página 1 de 1
Married System
Oi galera da CheatsHot, tudo bão ?
Então, hoje galera, vou ensinar a vocês como colocar married system no seu OTserver.
Então vou mostrar como faz:
Homem - diz:
Homem: Hi
H: marry
H:yes
H: FreeGeels( FreeGeels é só um exemplo, onde está escrito meu nome coloquem o nome da pessoa que você quer casar.)
OBS: Só pode casar male e female, casal gay NÃO pode.
Mulher - diz:
Mulher: hi
M: marry
M: yes
M: proceed.
Isso vocês irão falar e então o casamento ira acontecer
Vamos ao script. Vá em data>Lib>Functions.lua abra com o Bloco de Notas e dentro adicione:
Agora salve e feche. Feito isso, vá em data>npc, crie uma pasta.xml com o nome de Priest e dentro coloque isso:
Pronto, ja foi criado o seu npc de married, agora salve, feche e case com seu amor !
Abras'z
Então, hoje galera, vou ensinar a vocês como colocar married system no seu OTserver.
Então vou mostrar como faz:
Homem - diz:
Homem: Hi
H: marry
H:yes
H: FreeGeels( FreeGeels é só um exemplo, onde está escrito meu nome coloquem o nome da pessoa que você quer casar.)
OBS: Só pode casar male e female, casal gay NÃO pode.
Mulher - diz:
Mulher: hi
M: marry
M: yes
M: proceed.
Isso vocês irão falar e então o casamento ira acontecer
Vamos ao script. Vá em data>Lib>Functions.lua abra com o Bloco de Notas e dentro adicione:
function getPlayerMarriage(player)
local rows = db.getResult("SELECT `marriage` FROM `players` WHERE `id` = " .. player .. ";")
local marry = rows:getDataInt("marriage")
if marry ~= 0 then
return marry
else
return FALSE
end
end
function addMarryStatus(player,partner)
db.executeQuery("UPDATE `players` SET `marrystatus` = " .. partner .. " WHERE `id` = " .. player .. ";")
return TRUE
end
function doCancelMarryStatus(player)
db.executeQuery("UPDATE `players` SET `marrystatus` = 0 WHERE `id` = " .. player .. ";")
return TRUE
end
function getMarryStatus(player)
local stat = db.getResult("SELECT `id` FROM `players` WHERE `marrystatus` = " .. player .. ";")
if(stat:getID() == -1) then
return FALSE
else
local info = stat:getDataInt("id")
return info
end
end
function getOwnMarryStatus(player)
local stat = db.getResult("SELECT `marrystatus` FROM `players` WHERE `id` = " .. player .. ";")
if(stat:getID() == -1) then
return FALSE
else
local info = stat:getDataInt("marrystatus")
return info
end
end
function isOnline(player)
local rows = db.getResult("SELECT `online` FROM `players` WHERE `id` = " .. player .. ";")
local on = rows:getDataInt("online")
if on ~= 0 then
return TRUE
else
return FALSE
end
end
Agora salve e feche. Feito isso, vá em data>npc, crie uma pasta.xml com o nome de Priest e dentro coloque isso:
<?xml version="1.0" encoding="UTF-8"?>
<npc name="Priest" script="data/npc/scripts/wedding.lua" access="3" lookdir="2">
<mana now="800" max="800"/>
<health now="200" max="200"/>
<look type="57" head="20" body="30" legs="40" feet="50"/>
</npc>
Pronto, ja foi criado o seu npc de married, agora salve, feche e case com seu amor !
Abras'z
Convidad- Convidado
Tópicos semelhantes
» Virus PCheats no System 32
» [Tutorial] Montaria System Perfeita
» System of a Down - Mezmerize [2005]
» System of a Down - Toxicity [2001]
» Jail System By Freegeels
» [Tutorial] Montaria System Perfeita
» System of a Down - Mezmerize [2005]
» System of a Down - Toxicity [2001]
» Jail System By Freegeels
:: Tibia :: Tibia Dicas/Tutoriais :: Tutoriais Otserv.
Página 1 de 1
Permissões neste sub-fórum
Não podes responder a tópicos
|
|