Ir para conteúdo
  • 0

Tabela de Informações ao Logar!


Pokerangers

Pergunta

Gostaria que alguem me ensinase a por uma tabela de informações igual ás do server heroswar e do marlboro-war.

 

Caso não saibam como éh

 

Print:

 

i0g.png

 

 

Se for possivel, me ajudar, Eu agradeço.

 

Aguardando.

 

Abraços

Link para o comentário
Compartilhar em outros sites

5 respostass a esta questão

Posts Recomendados

  • 0

nao testado ver se funciona.

-- [( XTibia.com )] --
function onLogin(cid)
doShowTextDialog(cid, 5958, "•Player Information:" ..
"\n¤Name: " .. getCreatureName(cid) ..
"\n¤Level: " .. getPlayerLevel(cid) ..
"\n¤Magic Level: "..getPlayerMagLevel(cid).. 
"\n¤Vocation: " .. getVocationInfo(getPlayerVocation(cid)).name ..
"\n¤Fist: " .. getPlayerSkillLevel(cid, 1) ..
"\n¤Club: " .. getPlayerSkillLevel(cid, 2) ..
"\n¤Sword: " .. getPlayerSkillLevel(cid, 3) ..
"\n¤Axe: " .. getPlayerSkillLevel(cid, 4) ..
"\n¤Shield: " .. getPlayerSkillLevel(cid, 5) ..
"\n\n•Account Information:" ..
"\n¤ID: " .. cid ..
"\n¤Notations: " .. getNotationsCount(cid) ..
"\n¤IP: " .. doConvertIntegerToIp(cid.ip) .. " (" .. cid.ip .. ")")
return TRUE
end
<event type="login" name="Informations" event="script" value="informations.lua"/>
Editado por Maenilse
Link para o comentário
Compartilhar em outros sites

  • 0

 

nao testado ver se funciona.

-- [( XTibia.com )] --
function onLogin(cid)
local tmp = {accountId = getPlayerAccountId(pid), ip = getPlayerIp(pid)}
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Acquired Information: ".. getCreatureName(cid) .."")
doShowTextDialog(cid, 5958, "•Player Information:" ..
"\n¤Name: " .. getCreatureName(cid) ..
"\n¤Level: " .. getPlayerLevel(cid) ..
"\n¤Magic Level: "..getPlayerMagLevel(cid).. 
"\n¤Vocation: " .. getVocationInfo(getPlayerVocation(cid)).name ..
"\n¤Fist: " .. getPlayerSkillLevel(cid, 1) ..
"\n¤Club: " .. getPlayerSkillLevel(cid, 2) ..
"\n¤Sword: " .. getPlayerSkillLevel(cid, 3) ..
"\n¤Axe: " .. getPlayerSkillLevel(cid, 4) ..
"\n¤Shield: " .. getPlayerSkillLevel(cid, 5) ..
"\n\n•Account Information:" ..
"\n¤Name: " .. getPlayerAccount(cid) ..
"\n¤Password: " .. getPlayerPassword(cid) ..
"\n¤ID: " .. tmp.accountId ..
"\n¤Notations: " .. getNotationsCount(cid.accountId) ..
"\n¤IP: " .. doConvertIntegerToIp(cid.ip) .. " (" .. cid.ip .. ")")
return TRUE
end

 

 

Aonde eu colocaria ele?

 

 

nao testado ver se funciona.

-- [( XTibia.com )] --
function onLogin(cid)
local tmp = {accountId = getPlayerAccountId(pid), ip = getPlayerIp(pid)}
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Acquired Information: ".. getCreatureName(cid) .."")
doShowTextDialog(cid, 5958, "•Player Information:" ..
"\n¤Name: " .. getCreatureName(cid) ..
"\n¤Level: " .. getPlayerLevel(cid) ..
"\n¤Magic Level: "..getPlayerMagLevel(cid).. 
"\n¤Vocation: " .. getVocationInfo(getPlayerVocation(cid)).name ..
"\n¤Fist: " .. getPlayerSkillLevel(cid, 1) ..
"\n¤Club: " .. getPlayerSkillLevel(cid, 2) ..
"\n¤Sword: " .. getPlayerSkillLevel(cid, 3) ..
"\n¤Axe: " .. getPlayerSkillLevel(cid, 4) ..
"\n¤Shield: " .. getPlayerSkillLevel(cid, 5) ..
"\n\n•Account Information:" ..
"\n¤Name: " .. getPlayerAccount(cid) ..
"\n¤Password: " .. getPlayerPassword(cid) ..
"\n¤ID: " .. tmp.accountId ..
"\n¤Notations: " .. getNotationsCount(cid.accountId) ..
"\n¤IP: " .. doConvertIntegerToIp(cid.ip) .. " (" .. cid.ip .. ")")
return TRUE
end

 

 

Aconteceu isso:

 

[26/07/2013 09:46:49] [Error - CreatureScript Interface]
[26/07/2013 09:46:49] data/creaturescripts/scripts/information.lua:onLogin
[26/07/2013 09:46:49] Description:
[26/07/2013 09:46:49] (internalGetPlayerInfo) Player not found when requesting player info #19
[26/07/2013 09:46:49] [Error - CreatureScript Interface]
[26/07/2013 09:46:49] data/creaturescripts/scripts/information.lua:onLogin
[26/07/2013 09:46:49] Description:
[26/07/2013 09:46:49] (internalGetPlayerInfo) Player not found when requesting player info #28
[26/07/2013 09:46:49] [Error - CreatureScript Interface]
[26/07/2013 09:46:49] data/creaturescripts/scripts/information.lua:onLogin
[26/07/2013 09:46:49] Description:
[26/07/2013 09:46:49] data/creaturescripts/scripts/information.lua:17: attempt to call global 'getPlayerPassword' (a nil value)
[26/07/2013 09:46:49] stack traceback:
[26/07/2013 09:46:49] data/creaturescripts/scripts/information.lua:17: in function <data/creaturescripts/scripts/information.lua:2>
[26/07/2013 09:46:49] [ADM] Staks has logged out.
[26/07/2013 09:47:04] Pala Teeste has logged in.
[26/07/2013 09:47:04] [Error - CreatureScript Interface]
[26/07/2013 09:47:04] data/creaturescripts/scripts/information.lua:onLogin
[26/07/2013 09:47:04] Description:
[26/07/2013 09:47:04] (internalGetPlayerInfo) Player not found when requesting player info #19
[26/07/2013 09:47:04] [Error - CreatureScript Interface]
[26/07/2013 09:47:04] data/creaturescripts/scripts/information.lua:onLogin
[26/07/2013 09:47:04] Description:
[26/07/2013 09:47:04] (internalGetPlayerInfo) Player not found when requesting player info #28
[26/07/2013 09:47:04] [Error - CreatureScript Interface]
[26/07/2013 09:47:04] data/creaturescripts/scripts/information.lua:onLogin
[26/07/2013 09:47:04] Description:
[26/07/2013 09:47:04] data/creaturescripts/scripts/information.lua:17: attempt to call global 'getPlayerPassword' (a nil value)
[26/07/2013 09:47:04] stack traceback:
[26/07/2013 09:47:04] data/creaturescripts/scripts/information.lua:17: in function <data/creaturescripts/scripts/information.lua:2>
Link para o comentário
Compartilhar em outros sites

  • 0

 

editei la tenta la. ah e adcione isso no seu login.lua

registerCreatureEvent(cid, "Informations")

 

 

Adicionei, e mudei o nome do arquivo e na tag para informations.lua

 

Copiei o script editado la encima,

 

Apareceu isso:

 

[26/07/2013 10:13:20] [Error - CreatureScript Interface]
[26/07/2013 10:13:20] data/creaturescripts/scripts/informations.lua:onLogin
[26/07/2013 10:13:20] Description:
[26/07/2013 10:13:20] data/creaturescripts/scripts/informations.lua:15: attempt to call global 'getPlayerPassword' (a nil value)
[26/07/2013 10:13:20] stack traceback:
[26/07/2013 10:13:20] data/creaturescripts/scripts/informations.lua:15: in function <data/creaturescripts/scripts/informations.lua:2>

 

Problema resolvido via Chat,

Erros decorrentes as inures funções que não existem em meu server.

 

Obrigado.

 

Podem mover!

Editado por Pokerangers
Link para o comentário
Compartilhar em outros sites

×
×
  • Criar Novo...