

amarelax
-
Content Count
19 -
Joined
-
Last visited
Content Type
Profiles
Forums
Calendar
Posts posted by amarelax
-
-
-
local talk = TalkAction("!mudarpvp") function talk.onSay(player, words, param) local mode = player:getStorageValue(15500) if mode == 1 then setMode = 0 else setMode = 1 end if player:isPzLocked() == false and player:getSkull() == SKULL_NONE then player:setStorageValue(15500, setMode) if setMode == 1 then player:sendTextMessage(19, "Você ativou o modo no-pvp!") else player:sendTextMessage(19, "Você ativou o modo pvp!") end else player:sendCancelMessage("Você não pode mudar o pvp em quando tiver com a caveira!") end return false end talk:register()
Eu tenho essa parte do sistema que tenho de mudar pvp do player por talkactions, só que eu queria por esse scripts para player alterar o modo pvp dele a cada 3 dias e aparecer a mensagem que n pode alterar o pvp daki 3 dias.
se alguem conseguir me ajuda agradeço.
-
Em 19/12/2016 em 18:05, Ed.Specter disse:
adiciona a função que citei.
e vê se funciona esse aqui:
talkactions
function onSay(cid, words, param, param2, channel) local t = string.explode(param, ",") local target = getCreatureByName(t[1]) local points = tonumber(t[2]) local item = 2233 local storage = 21223 if(param == '') then return doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Command requires param.") end if (target ~= nil) and isPlayer(target) and not isPlayerGhost(target) then if (points ~= nil) and (type(points) == 'number') and (points>0) then if getPlayerVipPoints(cid) > points then local addItem = doPlayerAddItem(cid, item, 1) doStartTrade(cid, target, addItem) doItemSetAttribute(addItem, "description", "Transferência de "..points.." premium points.") doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Você deu trade no jogador "..getPlayerName(target)..", com a intenção de trocar "..points.." premium points.") doPlayerSendTextMessage(target, MESSAGE_INFO_DESCR, "O Jogador "..getPlayerName(cid).." deu trade em você, e está disposto a trocar "..points.." premium points.") setPlayerStorageValue(cid, storage, points) else doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Você não tem essa quantidade de premium points.") end else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Invalid param specified.") end else doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Invalid param specified.") end return true end
creaturescripts:
function onTradeAccept(cid, target, item) local storage = 21223 local sto = getPlayerStorageValue(cid, storage) if sto > 0 then doPlayerRemoveVipPoints(cid, sto) doPlayerAddVipPoints(target, sto) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Você trocou "..sto.." premium points, Parabéns.") doPlayerSendTextMessage(target, MESSAGE_STATUS_CONSOLE_BLUE, "Você realizou uma troca e adquiriu "..sto.." premium points, Parabéns.") setPlayerStorageValue(cid, storage, 0) end return true end
nesse caso você vai usar !trade NomeDoOutroPlayer, Quantidade de points. Exemplo: !trade Eduardo, 3
acho que deu pra ter uma boa base de como funciona..
não entendi direito esse do npcDesculpe reviver o tópico, alguém consegue passar esse scripts para tfs 1.3, eu já passei a função doStartTrade para tfs 1.3 só preciso do scripts agr.
-
Em 25/06/2018 em 18:24, Marco Oliveira disse:
Olá, estou deixando minha contribuição para o open-tibia, fornecendo a versão mais recente do meu site.
Compatível com a versão mais recente do TFS e OTX.
O layout é semelhante ao tibia.com, mas não contém todos os recursos.
Conto com a contribuição de todos neste projeto.
Algumas funcionalidades:Highscores NEW PagSeguro Lightbox New Tickets NEW Suporte https
Créditos:
Gesior.pl
Felipe MonteiroMarco Oliveira
Ricardo SouzaLink para download ou contribuição: GITHUB
Como eu faço funcionar pagseguro? pq não estou conseguindo.
-
1 hora atrás, movie disse:
Estou estudando o melhor jeito para fazê-lo, logo volto com o script para você testar.
@amarelax serão premium points ou dias de premium?
BLZ tranquilo, Serão dias premium.
-
@movie Sim vender os dias premium dele para outro player, to atras disso a muito tempo se tu conseguir tu e foda!
-
Queria um scripts de vender premium por talkactions.
EX:/sellpremium nomedoplayer,tantodepremium,valor
Ex 2 Daí fica tipo /sellpremium João,10,100
Daí para o player que esta comprando teria que ter o tanto de dinheiro no banco e falar /aceitar para finalizar a venda.
Para tfs 1.3 - 10.98
Fico MT MT grato se conseguir fazer!!!
-
Obrigado fusionou perfeitamente!
-
Base: The Forgotten Server 1.3, Versão: 10.98.
Olá queria uma ajuda, fiz um nova vocação com outfit diferente e mudei o corpse da outfit da nova vocação, so que quando personagem feminino morre, ele morre com corpse masculino.
Spoilerlocal array = {
[1] = 6080,
[2] = 6080,
[3] = 6080,
[4] = 6080,
[5] = 6080,
[6] = 6080,
[7] = 6080,
[8] = 6080,
[9] = 6080,
[10] = 6080,
[11] = 6080,
[12] = 6080,
[13] = 6080,
[14] = 6080,
[15] = 6080,
[16] = 6080,
[17] = 6080,
[18] = 6080,
[19] = 6080,
[20] = 6080,
[21] = 6003,
[22] = 6003,
[23] = 6003,
[24] = 6003,
[25] = 5966,
[26] = 5966,
[27] = 5966,
[28] = 5966,
[29] = 5966,
[30] = 5966
}
function onDeath(cid, corpse)
doTransformItem(corpse.uid, array[getPlayerVocation(cid)], 1)
doDecayItem(corpse.uid)
return true
endesse e meu script para mudar corpse, queria que a nova vocação morresse com novo corpse, mais tbm as outras vocações morresse como masculino corpse masculino e feminino corpse feminino.
-
olá se alguem pudesse me ajuda a criar um comando na source para poder funcionar esse scripts, tfs 1.2.
O scripts e para ver informações do Player!
function onSay(player, words, param) local config = { name = player:getName(), -- checa o nome do player level = player:getLevel(), -- checa o level do player vocation = player:getVocation():getName(), -- checa a vocação do player vip = player:getPremiumDays() -- checa a quantidade de dias premium } local armadura = 0 local earth = 0 local fire = 0 local ice = 0 local physical = 0 local holy = 0 local death = 0 local energy = 0 for i=1, 10 do local item = player:getSlotItem(i) if item.uid > 0 then if i == getItemInfo(item.itemid).wieldPosition then local att = getItemInfo(item.itemid).defense if att == 0 then att = getItemInfo(item.itemid).armor end armadura = armadura + att earth = earth + getItemInfo(item.itemid).absorbPercentEarth fire = fire + getItemInfo(item.itemid).absorbPercentFire ice = ice + getItemInfo(item.itemid).absorbPercentIce physical = physical + getItemInfo(item.itemid).absorbPercentPhysical holy = holy + getItemInfo(item.itemid).absorbPercentHoly death = death + getItemInfo(item.itemid).absorbPercentDeath energy = energy + getItemInfo(item.itemid).absorbPercentEnergy end end end player:popupFYI(cid, "Name: "..config.name.."\nLevel: "..config.level.."\nVocation: "..config.vocation.."\nArmadura: "..armadura.."\nVip: "..config.vip.." Days\nEarth: "..earth.."\nFire: "..fire.."\nIce: "..ice.."\nPhysical: "..physical.."\nHoly: "..holy.."\nDeath: "..death.."\nEnergy: "..energy) return true end
-
FlavioHulk poderia passar o scripts pra min ? to tentando achar a muito tempo
-
Olá queria saber se existe uma forma, de cada vocaçao ter um outfit so dela!
exemplo druid ter só a outfit mage, knight ter so outfit warrior....
para tfs 1.3
-
54 minutos atrás, Wakon disse:
@amarelax, testa ai:
function onUse(player, item, fromPosition, target, toPosition, isHotkey) if (player:getLevel() < 20) then return false end item:transform(2786) item:decay() Game.createItem(2677, 3, fromPosition) return true end
fucionou mais teria como por para aparecer uma messagem tipo somente level 20 ?
-
TFS 1.3
Eu queria por level pra pegar blueberryes
function onUse(player, item, fromPosition, target, toPosition, isHotkey)
item:transform(2786)
item:decay()
Game.createItem(2677, 3, fromPosition)
return true
end -
Mais eu alterei não acontece nada quando tento dar ./ir e o nome.
-
@Dwarfer vlw
1 hora atrás, Dwarfer disse:local places = { ["kazordoon"] = Position(1,1,1), ["mines"] = Position(1,1,1), ["gnomebase"] = Position(1,1,1) } function getPlaces() local str,n = "~~ Places to go ~~\n\n",1 for place, pos in pairs(places) do str = str..n.." - "..place.."\n" n = n + 1 end return str end function onSay(player, words, param) local param, p = param:lower(), player:getPosition() if param == "" then player:popupFYI(getPlaces()) player:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "Use /ir place name to go.") return true end local goTo = places[param] if not goTo then player:sendCancelMessage("You can not go to this place.") p:sendMagicEffect(CONST_ME_POFF) return true end player:teleportTo(goTo) goTo:sendMagicEffect(CONST_ME_TELEPORT) return true end
No talkactions.xml, adicione a tag: <talkaction words="/ir" separator=" " script="NOMEDOARQUIVO.lua" />
Testei o seu e não deu escrevo /ir aparece os lugares mais /ir e o nome do lugar não acontece nada.:(
Tentei este abaixo tb aconteceu a mesma coisa /ir aparece os lugares mais /ir e o nome do lugar não acontece nada.
function onSay(cid, words, param)
local config = {
pz = false, -- players precisam estar em protection zone para usar? (true or false)
battle = true, -- players deve estar sem battle (true or false)
custo = false, -- se os teleport irão custa (true or false)
need_level = false, -- se os teleport irão precisar de level (true or false)
premium = false -- se precisa ser premium account (true or false)
}
--[[ Config lugares]]--
local lugar = {
["bloodcity"] ={ -- bloodcity
pos = {x=482, y=1086, z=7},level = 1,price = 0},
["skyland"] ={ -- skyland
pos = {x=1941, y=325, z=7},level = 1,price = 0},
["roaring"] ={ -- roaring
pos = {x=573, y=150, z=7},level = 1,price = 0},
["smigol"] ={ -- smigol
pos = {x=1813, y=624, z=6},level = 1,price = 0},
["allukard"] ={ -- allukard
pos = {x=1561, y=857, z=7},level = 1,price = 0},
["cerberus"] ={ -- cerberus
pos = {x=1716, y=430, z=7},level = 1,price = 0},
["ancalagon"] ={ -- ancalagon
pos = {x=1683, y=1102, z=10},level = 1,price = 0},
["grimvip"] ={ -- grimvip
pos = {x=1308, y=1434, z=8},level = 1,price = 0},
["lizard"] ={ -- lizard
pos = {x=289, y=330, z=5},level = 1,price = 0},
["demonvip"] ={ -- demonvip
pos = {x=1337, y=640, z=8},level = 1,price = 0},
["anfallas"] = { -- nome do lugar
pos = {x=982, y=1298, z=7},level = 1,price = 0},
["dol"] = { -- nome do lugar
pos = {x=1206, y=753, z=7},level = 1,price = 0},
["edoras"] = { -- nome do lugar
pos = {x=1066, y=1008, z=5},level = 1,price = 0},
["bree"] = { -- nome do lugar
pos = {x=742, y=537, z=7},level = 1,price = 0},
["belfallas"] = { -- nome do lugar
pos = {x=1187, y=1514, z=7},level = 1,price = 0},
["ashenport"] = { -- nome do lugar
pos = {x=334, y=611, z=6},level = 1,price = 0},
["esg"] = { -- nome do lugar
pos = {x=1413, y=502, z=7},level = 1,price = 0},
["argond"] = { -- nome do lugar
pos = {x=607, y=867, z=7},level = 1,price = 0},
["moria"] = { -- nome do lugar
pos = {x=1018, y=636, z=7},level = 1,price = 0},
["forod"] = { -- nome do lugar
pos = {x=709, y=105, z=7},level = 1,price = 0},
["condado"] = { -- nome do lugar
pos = {x=621, y=533, z=7},level = 1,price = 0},
["dunedain"] = { -- nome do lugar
pos = {x=1591, y=371, z=6},level = 1,price = 0},
["minas"] = { -- nome do lugar
pos = {x=1345, y=1371, z=6},level = 1,price = 0},
["troll1"] = { -- nome do lugar
pos = {x=1071, y=877, z=8},level = 1,price = 0},
["troll2"] = { -- nome do lugar
pos = {x=1168, y=922, z=8},level = 1,price = 0},
["rot"] = { -- nome do lugar
pos = {x=1152, y=930, z=9},level = 1,price = 0},
["pirata"] = { -- nome do lugar
pos = {x=193, y=651, z=7},level = 1,price = 0},
["mino1"] = { -- nome do lugar
pos = {x=740, y=415, z=8},level = 1,price = 0},
["mino2"] = { -- nome do lugar
pos = {x=556, y=570, z=7},level = 1,price = 0},
["pantano"] = { -- nome do lugar
pos = {x=1247, y=1074, z=7},level = 1,price = 0},
["eriador"] = { -- nome do lugar
pos = {x=825, y=724, z=7},level = 1,price = 0},
["dwarf1"] = { -- nome do lugar
pos = {x=1410, y=438, z=7},level = 1,price = 0},
["dwarf2"] = { -- nome do lugar
pos = {x=1000, y=617, z=7},level = 1,price = 0},
["macacos1"] = { -- nome do lugar
pos = {x=1270, y=753, z=7},level = 1,price = 0},
["macacos2"] = { -- nome do lugar
pos = {x=624, y=610, z=7},level = 1,price = 0},
["slime1"] = { -- nome do lugar
pos = {x=1362, y=1426, z=6},level = 1,price = 0},
["slime2"] = { -- nome do lugar
pos = {x=1365, y=475, z=7},level = 1,price = 0},
["slime3"] = { -- nome do lugar
pos = {x=433, y=651, z=7},level = 1,price = 0},
["ghoul"] = { -- nome do lugar
pos = {x=1136, y=1052, z=7},level = 1,price = 0},
["bandit1"] = { -- nome do lugar
pos = {x=1120, y=1090, z=7},level = 1,price = 0},
["bandit2"] = { -- nome do lugar
pos = {x=710, y=383, z=7},level = 1,price = 0},
["cyc1"] = { -- nome do lugar
pos = {x=1038, y=869, z=7},level = 1,price = 0},
["cyc2"] = { -- nome do lugar
pos = {x=1104, y=788, z=10},level = 1,price = 0},
["cyc3"] = { -- nome do lugar
pos = {x=1276, y=914, z=6},level = 1,price = 0},
["stonegolem"] = { -- nome do lugar
pos = {x=1324, y=1047, z=7},level = 1,price = 0},
["dworc1"] = { -- nome do lugar
pos = {x=640, y=214, z=7},level = 1,price = 0},
["eregion"] = { -- nome do lugar
pos = {x=901, y=725, z=7},level = 1,price = 0},
["promoOrc"] = { -- nome do lugar
pos = {x=1696, y=1278, z=7},level = 1,price = 0},
["rhun"] = { -- nome do lugar
pos = {x=1759, y=813, z=7},level = 1,price = 0},
["dragonvip"] = { -- nome do lugar
pos = {x=1539, y=723, z=6},level = 1,price = 0},
["erebor"] = { -- nome do lugar
pos = {x=1415, y=424, z=4},level = 1,price = 0},
["mirkwood"] = { -- nome do lugar
pos = {x=1253, y=637, z=7},level = 1,price = 0},
["forochel"] = { -- nome do lugar
pos = {x=507, y=116, z=6},level = 1,price = 0},
["carn"] = { -- nome do lugar
pos = {x=676, y=199, z=6},level = 1,price = 0},
["enedwaith"] = { -- nome do lugar
pos = {x=867, y=1004, z=7},level = 1,price = 0},
["elven"] = { -- nome do lugar
pos = {x=999, y=582, z=2},level = 1,price = 0},
["wyvern"] = { -- nome do lugar
pos = {x=823, y=354, z=6},level = 1,price = 0},
["corsario"] = { -- nome do lugar
pos = {x=872, y=1472, z=6},level = 1,price = 0},
["dunland"] = { -- nome do lugar
pos = {x=808, y=930, z=7},level = 1,price = 0},
["beleghost"] = { -- nome do lugar
pos = {x=182, y=589, z=6},level = 1,price = 0},
["evendim"] = { -- nome do lugar
pos = {x=580, y=242, z=6},level = 1,price = 0},
["bonebeast1"] = { -- nome do lugar
pos = {x=1302, y=658, z=7},level = 1,price = 0},
["bonebeast2"] = { -- nome do lugar
pos = {x=1327, y=1300, z=5},level = 1,price = 0},
["blacknight1"] = { -- nome do lugar
pos = {x=861, y=416, z=7},level = 1,price = 0},
["blacknight2"] = { -- nome do lugar
pos = {x=1257, y=1371, z=5},level = 1,price = 0},
["hero1"] = { -- nome do lugar
pos = {x=1137, y=1453, z=7},level = 1,price = 0},
["hero2"] = { -- nome do lugar
pos = {x=1200, y=1440, z=7},level = 1,price = 0},
["hero3"] = { -- nome do lugar
pos = {x=1257, y=1367, z=5},level = 1,price = 0},
["hydra1"] = { -- nome do lugar
pos = {x=667, y=724, z=6},level = 1,price = 0},
["hydra2"] = { -- nome do lugar
pos = {x=526, y=641, z=6},level = 1,price = 0},
["hydra3"] = { -- nome do lugar
pos = {x=498, y=686, z=6},level = 1,price = 0},
["lich"] = { -- nome do lugar
pos = {x=1470, y=1034, z=7},level = 1,price = 0},
["icewitch1"] = { -- nome do lugar
pos = {x=723, y=74, z=7},level = 1,price = 0},
["crystal"] = { -- nome do lugar
pos = {x=696, y=80, z=7},level = 1,price = 0},
["barbarian"] = { -- nome do lugar
pos = {x=951, y=98, z=7},level = 1,price = 0},
["dragon1"] = { -- nome do lugar
pos = {x=679, y=327, z=7},level = 1,price = 0},
["dragon2"] = { -- nome do lugar
pos = {x=368, y=660, z=7},level = 1,price = 0},
["vamp"] = { -- nome do lugar
pos = {x=1275, y=1382, z=7},level = 1,price = 0},
["turtle"] = { -- nome do lugar
pos = {x=452, y=509, z=7},level = 1,price = 0},
["purga"] = { -- nome do lugar
pos = {x=1085, y=346, z=7},level = 1,price = 0},
["northern"] = { -- nome do lugar
pos = {x=1541, y=142, z=7},level = 1,price = 0},
["northern2"] = { -- nome do lugar
pos = {x=1541, y=118, z=7},level = 1,price = 0},
["ered"] = { -- nome do lugar
pos = {x=1282, y=90, z=7},level = 1,price = 0},
["orodruin"] = { -- nome do lugar
pos = {x=1578, y=1208, z=0},level = 1,price = 0},
["ice"] = { -- nome do lugar
pos = {x=859, y=127, z=7},level = 1,price = 0},
["nimrais"] = { -- nome do lugar
pos = {x=740, y=1210, z=0},level = 1,price = 0},
["defiler"] = { -- nome do lugar
pos = {x=642, y=492, z=7},level = 1,price = 0},
["behedemon"] = { -- nome do lugar
pos = {x=996, y=611, z=10},level = 1,price = 0},
["harlond"] = { -- nome do lugar
pos = {x=379, y=812, z=5},level = 1,price = 0},
["erech"] = { -- nome do lugar
pos = {x=681, y=1294, z=5},level = 1,price = 0},
["riv"] = { -- nome do lugar
pos = {x=1052, y=541, z=4},level = 1,price = 0},
["mordor"] = { -- nome do lugar
pos = {x=1510, y=1235, z=7},level = 1,price = 0},
["orc"] = { -- nome do lugar
pos = {x=1275, y=804, z=7},level = 1,price = 0},
["icewitch2"] = { -- nome do lugar
pos = {x=1306, y=1290, z=3},level = 1,price = 0},
}
local a = lugar[param]
if not(a) then
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "As cidades que você pode ir são: edoras, belfallas, ashenport, bree, riv, dol, esg, argond, moria, mordor, forod, condado, dunedain, anfallas, minas")
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "As hunts que você pode ir são:")
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Até Level 30: troll1, troll2, rot, pirata, mino1, mino2, pantano, eriador, dwarf1, dwarf2, macacos1, macacos2, slime1, slime2, slime3, ghoul, bandit1, bandit2, cyc1, cyc2, cyc3, stonegolem, dworc1, eregion, promoOrc")
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "De level 31 a 100: rhun, dragonvip, erebor, mirkwood, forochel, carn, enedwaith, elven, wyvern, corsario, dunland, beleghost, evendim, bonebeast1, bonebeast2, orc, blacknight1, blacknight2, hero1, hero2, hero3, hydra1, hydra2, hydra3, lich, icewitch1, icewitch2, crystal, barbarian, dragon1, dragon2, vamp, turtle, purga, quara")
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Level maior que 100: northern, ered, orodruin, ice, nimrais, defiler, behedemon, harlond, northern2, erech")
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Level maior que 200: lizard, cerberus, ancalagon, demonvip, grimvip, allukard, roaring, smigol, skyland, bloodcity. ")doSendMagicEffect(getCreaturePosition(cid), CONST_ME_POFF)
return TRUE
elseif config.premium == true and not isPremium(cid) then
doPlayerSendTextMessage(cid, MESSAGE_EVENT_DEFAULT, "Apenas contas vip tem esse recurso.")
return TRUE
elseif config.battle == true and getCreatureCondition(cid, CONDITION_INFIGHT) == TRUE then
doPlayerSendTextMessage(cid, MESSAGE_EVENT_DEFAULT, "Você não pode se teleportar em uma batalha.")
return TRUE
end
doSendMagicEffect(getPlayerPosition(cid),27)
doTeleportThing(cid, a.pos)
doSendMagicEffect(getPlayerPosition(cid),40)
return TRUE
end -
Como o titulo já diz quero um comando que quando escrevo /ir Apareça os lugares onde posso ir dai para ir para aquele lugar eu escrevo /ir E o nome do lugar. OBS que funcione em otserver 10.98 . vlws.
player info ajuda
in Tibia Otserv Support
Posted
Olá tenho esse scripts de mostrar bônus de Experiência do player só que eu precisava q o bônus = 30 se juntasse só com bonus1 = 25 e o bônus = 0 se juntasse só com o bonus1 = -25 se alguém puder me ajuda agradeço.