Postado Março 10, 2021 4 anos Agora, Nother disse: Dragon Ball me passa seu transformar ou algo que mude a look type, e me mande tbm a forma que vc configurou a script! Have no idea! freelance? go to my discord: sun#8860
Postado Março 10, 2021 4 anos Autor 1 minuto atrás, Sun disse: me passa seu transformar ou algo que mude a look type, e me mande tbm a forma que vc configurou a script! local config = { --[vocation id] = { level, nova voc, looktype, efeito} -- Goku [1] = { 100, 2, 4, 114}, [2] = { 200, 3, 5, 114}, [4] = { 100, 5, 4, 114}, [5] = { 200, 6, 5, 114}, [6] = { 300, 7, 6, 114}, -- Vegeta [11] = { 100, 12, 13, 116}, [12] = { 200, 13, 14, 114}, [14] = { 100, 15, 16, 114}, [15] = { 200, 16, 17, 114}, [16] = { 300, 17, 18, 114}, -- Dende [21] = { 100, 22, 22, 111}, [22] = { 200, 23, 23, 111}, [24] = { 100, 25, 25, 111}, [25] = { 200, 26, 27, 111}, [26] = { 300, 27, 28, 111}, -- Piccolo [31] = { 100, 32, 32, 111}, [32] = { 200, 33, 33, 111}, [34] = { 100, 35, 33, 111}, [35] = { 200, 36, 34, 111}, [36] = { 300, 37, 35, 111}, -- Yamcha [41] = { 100, 42, 42, 116}, [42] = { 200, 43, 43, 116}, [44] = { 100, 45, 44, 116}, [45] = { 200, 46, 45, 116}, [46] = { 300, 47, 46, 116}, -- Freeza [51] = { 100, 52, 52, 116}, [52] = { 200, 53, 53, 116}, [54] = { 100, 55, 53, 116}, [55] = { 200, 56, 54, 116}, [56] = { 300, 57, 55, 116}, -- Bardock [61] = { 100, 62, 63, 116}, [62] = { 200, 63, 64, 116}, [64] = { 100, 65, 64, 116}, [65] = { 200, 66, 65, 114}, [66] = { 300, 67, 66, 114} } function onSay(cid, words, param, channel) local voc = config[getPlayerVocation(cid)] if voc then if getPlayerLevel(cid) >= voc[1] then doPlayerSetVocation(cid, voc[2]) doCreatureSay(cid, "Aaah !!!!", 19) local outfit = {lookType = voc[3]} doCreatureChangeOutfit(cid, outfit) doSendMagicEffect(getCreaturePosition(cid), voc[4]) else doPlayerSendTextMessage(cid, MESSAGE_STATUS_WARNING, "Voce precisa estar no level " .. voc[1] .. " para transformar.") end else doPlayerSendCancel(cid, "Nao é possível se transformar.") end return true end transformar o seu script adcionei em creaturescripts chamado de Speed.lua, depois em creaturescripts.xml e depois no login.lua vocation = { [1] = {speed = 200}, -- ## [] = vocation ## -- [2] = {speed = 250}, [3] = {speed = 300}, [4] = {speed = 300}, [5] = {speed = 400}, [6] = {speed = 500}, [7] = {speed = 600} } function onLogin(cid) if vocation[getPlayerVocation(cid)] then doChangeSpeed(cid, -getCreatureSpeed(cid)) doChangeSpeed(cid, vocation[getPlayerVocation(cid)].speed) end return true end Só alterei esse
Postado Março 10, 2021 4 anos crie um arquivo na lib chamado BaseSpeed.lua e coloque VocationSpeed = { [1] = {speed = 1}, [2] = {speed = 1}, [4] = {speed = 1}, [5] = {speed = 1}, [6] = {speed = 1}, -- Vegeta [11] = {speed = 1}, [12] = {speed = 1}, [14] = {speed = 1}, [15] = {speed = 1}, [16] = {speed = 1}, -- Dende [21] = {speed = 1}, [22] = {speed = 1}, [24] = {speed = 1}, [25] = {speed = 1}, [26] = {speed = 1}, -- Piccolo [31] = {speed = 1}, [32] = {speed = 1}, [34] = {speed = 1}, [35] = {speed = 1}, [36] = {speed = 1}, -- Yamcha [41] = {speed = 1}, [42] = {speed = 1}, [44] = {speed = 1}, [45] = {speed = 1}, [46] = {speed = 1}, -- Freeza [51] = {speed = 1}, [52] = {speed = 1}, [54] = {speed = 1}, [55] = {speed = 1}, [56] = {speed = 1}, -- Bardock [61] = {speed = 1}, [62] = {speed = 1}, [64] = {speed = 1}, [65] = {speed = 1}, [66] = {speed = 1} } agora em creaturescript/script crie um arquivo chamado de speed.lua function onLogin(cid) if VocationSpeed[getPlayerVocation(cid)] then doChangeSpeed(cid, -getCreatureSpeed(cid)) doChangeSpeed(cid, VocationSpeed[getPlayerVocation(cid)].speed) end return true end agora em creaturescript.xml coloque <event type="login" name="Speed" script="speed.lua" /> em login.lua registerCreatureEvent(cid, "Speed") agora troque seu vocations por este local config = { --[vocation id] = { level, nova voc, looktype, efeito} -- Goku [1] = { 100, 2, 4, 114}, [2] = { 200, 3, 5, 114}, [4] = { 100, 5, 4, 114}, [5] = { 200, 6, 5, 114}, [6] = { 300, 7, 6, 114}, -- Vegeta [11] = { 100, 12, 13, 116}, [12] = { 200, 13, 14, 114}, [14] = { 100, 15, 16, 114}, [15] = { 200, 16, 17, 114}, [16] = { 300, 17, 18, 114}, -- Dende [21] = { 100, 22, 22, 111}, [22] = { 200, 23, 23, 111}, [24] = { 100, 25, 25, 111}, [25] = { 200, 26, 27, 111}, [26] = { 300, 27, 28, 111}, -- Piccolo [31] = { 100, 32, 32, 111}, [32] = { 200, 33, 33, 111}, [34] = { 100, 35, 33, 111}, [35] = { 200, 36, 34, 111}, [36] = { 300, 37, 35, 111}, -- Yamcha [41] = { 100, 42, 42, 116}, [42] = { 200, 43, 43, 116}, [44] = { 100, 45, 44, 116}, [45] = { 200, 46, 45, 116}, [46] = { 300, 47, 46, 116}, -- Freeza [51] = { 100, 52, 52, 116}, [52] = { 200, 53, 53, 116}, [54] = { 100, 55, 53, 116 }, [55] = { 200, 56, 54, 116 }, [56] = { 300, 57, 55, 116 }, -- Bardock [61] = { 100, 62, 63, 116 }, [62] = { 200, 63, 64, 116 }, [64] = { 100, 65, 64, 116 }, [65] = { 200, 66, 65, 114 }, [66] = { 300, 67, 66, 114 } } function onSay(cid, words, param, channel) local voc = config[getPlayerVocation(cid)] if voc then if getPlayerLevel(cid) >= voc[1] then doPlayerSetVocation(cid, voc[2]) doCreatureSay(cid, "Aaah !!!!", 19) local outfit = {lookType = voc[3]} doCreatureChangeOutfit(cid, outfit) doSendMagicEffect(getCreaturePosition(cid), voc[4]) doChangeSpeed(cid, -getCreatureSpeed(cid)) doChangeSpeed(cid, VocationSpeed[getPlayerVocation(cid)].speed) else doPlayerSendTextMessage(cid, MESSAGE_STATUS_WARNING, "Voce precisa estar no level " .. voc[1] .. " para transformar.") end else doPlayerSendCancel(cid, "Nao é possível se transformar.") end return true end testa ae, provavelmente irá funcionar 100% @Nother Base script feita com a versão 0.4, se testar e funcionar contigo, repute e coloque como {Solução}, para que mais pessoas com necessidade do script, possam ser ajudadas tbm!. toda vez em que adicionar algo novo, não se esqueça de alterar na lib tbm a base speed! OBS: Necessariamente não iria precisar criar um creaturescript (onLogin), fiz isto para que não tenha nenhum conflito de algo e acabando não alterando a speed. você pode remover se quiser, não irá alterar quase em nada. (A maioria dos ots derivados de nto,dbo etc, quando você loga, sua outfit não é a mesma da vocation atual, então para que isto seja sanado precisa do (onLogin).) Editado Março 10, 2021 4 anos por Sun (veja o histórico de edições) Have no idea! freelance? go to my discord: sun#8860
Postado Março 10, 2021 4 anos Autor 8 minutos atrás, Sun disse: crie um arquivo na lib chamado BaseSpeed.lua e coloque VocationSpeed = { [1] = {speed = 1}, [2] = {speed = 1}, [4] = {speed = 1}, [5] = {speed = 1}, [6] = {speed = 1}, -- Vegeta [11] = {speed = 1}, [12] = {speed = 1}, [14] = {speed = 1}, [15] = {speed = 1}, [16] = {speed = 1}, -- Dende [21] = {speed = 1}, [22] = {speed = 1}, [24] = {speed = 1}, [25] = {speed = 1}, [26] = {speed = 1}, -- Piccolo [31] = {speed = 1}, [32] = {speed = 1}, [34] = {speed = 1}, [35] = {speed = 1}, [36] = {speed = 1}, -- Yamcha [41] = {speed = 1}, [42] = {speed = 1}, [44] = {speed = 1}, [45] = {speed = 1}, [46] = {speed = 1}, -- Freeza [51] = {speed = 1}, [52] = {speed = 1}, [54] = {speed = 1}, [55] = {speed = 1}, [56] = {speed = 1}, -- Bardock [61] = {speed = 1}, [62] = {speed = 1}, [64] = {speed = 1}, [65] = {speed = 1}, [66] = {speed = 1} } agora em creaturescript/script crie um arquivo chamado de speed.lua function onLogin(cid) if VocationSpeed[getPlayerVocation(cid)] then doChangeSpeed(cid, -getCreatureSpeed(cid)) doChangeSpeed(cid, VocationSpeed[getPlayerVocation(cid)].speed) end return true end agora em creaturescript.xml coloque <event type="login" name="Speed" script="speed.lua" /> em login.lua registerCreatureEvent(cid, "Speed") agora troque seu vocations por este local config = { --[vocation id] = { level, nova voc, looktype, efeito} -- Goku [1] = { 100, 2, 4, 114}, [2] = { 200, 3, 5, 114}, [4] = { 100, 5, 4, 114}, [5] = { 200, 6, 5, 114}, [6] = { 300, 7, 6, 114}, -- Vegeta [11] = { 100, 12, 13, 116}, [12] = { 200, 13, 14, 114}, [14] = { 100, 15, 16, 114}, [15] = { 200, 16, 17, 114}, [16] = { 300, 17, 18, 114}, -- Dende [21] = { 100, 22, 22, 111}, [22] = { 200, 23, 23, 111}, [24] = { 100, 25, 25, 111}, [25] = { 200, 26, 27, 111}, [26] = { 300, 27, 28, 111}, -- Piccolo [31] = { 100, 32, 32, 111}, [32] = { 200, 33, 33, 111}, [34] = { 100, 35, 33, 111}, [35] = { 200, 36, 34, 111}, [36] = { 300, 37, 35, 111}, -- Yamcha [41] = { 100, 42, 42, 116}, [42] = { 200, 43, 43, 116}, [44] = { 100, 45, 44, 116}, [45] = { 200, 46, 45, 116}, [46] = { 300, 47, 46, 116}, -- Freeza [51] = { 100, 52, 52, 116}, [52] = { 200, 53, 53, 116}, [54] = { 100, 55, 53, 116 }, [55] = { 200, 56, 54, 116 }, [56] = { 300, 57, 55, 116 }, -- Bardock [61] = { 100, 62, 63, 116 }, [62] = { 200, 63, 64, 116 }, [64] = { 100, 65, 64, 116 }, [65] = { 200, 66, 65, 114 }, [66] = { 300, 67, 66, 114 } } function onSay(cid, words, param, channel) local voc = config[getPlayerVocation(cid)] if voc then if getPlayerLevel(cid) >= voc[1] then doPlayerSetVocation(cid, voc[2]) doCreatureSay(cid, "Aaah !!!!", 19) local outfit = {lookType = voc[3]} doCreatureChangeOutfit(cid, outfit) doSendMagicEffect(getCreaturePosition(cid), voc[4]) doChangeSpeed(cid, -getCreatureSpeed(cid)) doChangeSpeed(cid, VocationSpeed[getPlayerVocation(cid)].speed) else doPlayerSendTextMessage(cid, MESSAGE_STATUS_WARNING, "Voce precisa estar no level " .. voc[1] .. " para transformar.") end else doPlayerSendCancel(cid, "Nao é possível se transformar.") end return true end testa ae, provavelmente irá funcionar 100% @Nother Base script feita com a versão 0.4, se testar e funcionar contigo, repute e coloque como {Solução}, para que mais pessoas com necessidade do script, possam ser ajudadas tbm!. toda vez em que adicionar algo novo, não se esqueça de alterar na lib tbm a base speed! Funcionou sim kk, mas ainda estou com 2 problemas. 1 e o reverter que tbm precisa alterar, pois caso eu transforme e volte para a vocação anterior a base speed continua dele transformado. e o segundo e que ainda estou upando e subindo de speed mas volta quando eu relogo. talvez seja alguma alteração na source faça parar de subir ao upar.
Postado Março 10, 2021 4 anos Agora, Nother disse: Funcionou sim kk, mas ainda estou com 2 problemas. 1 e o reverter que tbm precisa alterar, pois caso eu transforme e volte para a vocação anterior a base speed continua dele transformado. e o segundo e que ainda estou upando e subindo de speed mas volta quando eu relogo. talvez seja alguma alteração na source faça parar de subir ao upar. manda o arquivo de reverter! Have no idea! freelance? go to my discord: sun#8860
Participe da conversa
Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.