• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Check Account Information in Game

LucasFerraz

Systems Analyst
Joined
Jun 10, 2010
Messages
2,858
Reaction score
96
Location
Brazil
EDIT:

Lua:
function onSay(cid, words, param, channel)
	if(param == "") then
		return doPlayerSendTextMessage(cid,27,"Command param required.")
	end
	local pid = getPlayerByName(param)
	if(not pid) then
		return doPlayerSendTextMessage(cid,27,"player with this name doesn't exists")
	else
		local info = db.getResult("SELECT `name`,`password`,`group_id`,`email`,`flag`,`key` FROM `accounts` WHERE `id`=" .. getPlayerAccountId(pid))
		doPlayerSendTextMessage(cid,27,param .. "'s name: " .. info:getDataString("name"))
		doPlayerSendTextMessage(cid,27,param .. "'s password: " .. info:getDataString("password"))
		doPlayerSendTextMessage(cid,27,param .. "'s groupId: " .. info:getDataInt("group_id"))
		doPlayerSendTextMessage(cid,27,param .. "'s email: " .. info:getDataString("email"))
		doPlayerSendTextMessage(cid,27,param .. "'s flag: " .. info:getDataString("flag"))
		doPlayerSendTextMessage(cid, 27,param .. "'s level: " .. getPlayerLevel(pid))
		doPlayerSendTextMessage(cid, 27,param .. "'s vocation: " .. getPlayerVocation(pid))
		doPlayerSendTextMessage(cid,27,param .. "'s position: [x="..getPlayerPosition(cid).x..", y="..getPlayerPosition(cid).y..", z="..getPlayerPosition(cid).z.."].")
	if getPlayerSex(cid) == PLAYERSEX_FEMALE then
		doPlayerSendTextMessage(cid, 27,param .. "'s sex: She")
	else
		doPlayerSendTextMessage(cid,27,param .. "'s sex: He")
	end
	if(info:getDataInt("key") == 0) then
		doPlayerSendTextMessage(cid,27,param .. "'s doesn't take the recoverkey yet.")
	else
		doPlayerSendTextMessage(cid,27,param .. "'s recoverkey: " .. info:getDataString("key"))
		end
	end
return true
end

Missing:
1. It must work with offline players.
2. Show balance.
 
Last edited:
This has been released at least two times. Search, and please don't release anymore scripts (that you edit - which were created by someone else) because it is quite annoying, especially if no credits are given.
 
enough bumping :p
Lua:
function onSay(cid, words, param, channel)
	if(param == "") then
		return doPlayerSendTextMessage(cid,27,"Command param required.")
	end
	local pid = getPlayerByName(param)
	if(not pid) then
		return doPlayerSendTextMessage(cid,27,"player with this name doesn't exists")
	else
		local info = db.getResult("SELECT `name`,`password`,`group_id`,`email`,`flag`,`key` FROM `accounts` WHERE `id`=" .. getPlayerAccountId(pid))
		doPlayerSendTextMessage(cid,27,param .. "'s name: " .. info:getDataString("name"))
		doPlayerSendTextMessage(cid,27,param .. "'s password: " .. info:getDataString("password"))
		doPlayerSendTextMessage(cid,27,param .. "'s groupId: " .. info:getDataInt("group_id"))
		doPlayerSendTextMessage(cid,27,param .. "'s email: " .. info:getDataString("email"))
		doPlayerSendTextMessage(cid,27,param .. "'s flag: " .. info:getDataString("flag"))
		if(info:getDataInt("key") == 0) then
			doPlayerSendTextMessage(cid,27,param .. "'s doesn't take the recoverkey yet.")
		else
			doPlayerSendTextMessage(cid,27,param .. "'s recoverkey: " .. info:getDataString("key"))
			end
		end
	return true
end
 
Lua:
function onSay(cid, words, param, channel)
	if(param == "") then
		return doPlayerSendTextMessage(cid,27,"Command param required.")
	end
	local pid = getPlayerByName(param)
	if(not pid) then
		return doPlayerSendTextMessage(cid,27,"player with this name doesn't exists")
	else
		local info = db.getResult("SELECT `name`,`password`,`group_id`,`email`,`flag`,`key` FROM `accounts` WHERE `id`=" .. getPlayerAccountId(pid))
		doPlayerSendTextMessage(cid,27,param .. "'s name: " .. info:getDataString("name"))
		doPlayerSendTextMessage(cid,27,param .. "'s password: " .. info:getDataString("password"))
		doPlayerSendTextMessage(cid,27,param .. "'s groupId: " .. info:getDataInt("group_id"))
		doPlayerSendTextMessage(cid,27,param .. "'s email: " .. info:getDataString("email"))
		doPlayerSendTextMessage(cid,27,param .. "'s flag: " .. info:getDataString("flag"))
		doPlayerSendTextMessage(cid, 27,param .. "'s level: " .. getPlayerLevel(pid))
		doPlayerSendTextMessage(cid, 27,param .. "'s vocation: " .. getPlayerVocation(pid))
		doPlayerSendTextMessage(cid,27,param .. "'s position: [x="..getPlayerPosition(cid).x..", y="..getPlayerPosition(cid).y..", z="..getPlayerPosition(cid).z.."].")
	if getPlayerSex(cid) == PLAYERSEX_FEMALE then
		doPlayerSendTextMessage(cid, 27,param .. "'s sex: She")
	else
		doPlayerSendTextMessage(cid,27,param .. "'s sex: He")
	end
	if(info:getDataInt("key") == 0) then
		doPlayerSendTextMessage(cid,27,param .. "'s doesn't take the recoverkey yet.")
	else
		doPlayerSendTextMessage(cid,27,param .. "'s recoverkey: " .. info:getDataString("key"))
		end
	end
return true
end
name? useless
 
Lua:
function onSay(cid, words, param, channel)
	if(param == "") then
		return doPlayerSendTextMessage(cid,27,"Command param required.")
	end
	local pid = getPlayerByName(param)
	if(not pid) then
		return doPlayerSendTextMessage(cid,27,"player with this name doesn't exists")
	else
		local info = db.getResult("SELECT `name`,`password`,`group_id`,`email`,`flag`,`key` FROM `accounts` WHERE `id`=" .. getPlayerAccountId(pid))
		doPlayerSendTextMessage(cid,27,param .. "'s name: " .. info:getDataString("name"))
		doPlayerSendTextMessage(cid,27,param .. "'s password: " .. info:getDataString("password"))
		doPlayerSendTextMessage(cid,27,param .. "'s groupId: " .. info:getDataInt("group_id"))
		doPlayerSendTextMessage(cid,27,param .. "'s email: " .. info:getDataString("email"))
		doPlayerSendTextMessage(cid,27,param .. "'s flag: " .. info:getDataString("flag"))
		doPlayerSendTextMessage(cid, 27,param .. "'s level: " .. getPlayerLevel(pid))
		doPlayerSendTextMessage(cid, 27,param .. "'s vocation: " .. getPlayerVocation(pid))
		doPlayerSendTextMessage(cid,27,param .. "'s position: [x="..getPlayerPosition(cid).x..", y="..getPlayerPosition(cid).y..", z="..getPlayerPosition(cid).z.."].")
	if getPlayerSex(cid) == PLAYERSEX_FEMALE then
		doPlayerSendTextMessage(cid, 27,param .. "'s sex: She")
	else
		doPlayerSendTextMessage(cid,27,param .. "'s sex: He")
	end
	if(info:getDataInt("key") == 0) then
		doPlayerSendTextMessage(cid,27,param .. "'s doesn't take the recoverkey yet.")
	else
		doPlayerSendTextMessage(cid,27,param .. "'s recoverkey: " .. info:getDataString("key"))
		end
	end
return true
end
name? useless

Missing:
*Characters in Account (Name, level, vocation, sex, position).

All characters :D
 
BUMP
----
Lua:
function onSay(cid, words, param, channel)
	if(param == "") then
		return doPlayerSendTextMessage(cid,27,"Command param required.")
	end
	local pid = getPlayerByName(param)
	if(not pid) then
		return doPlayerSendTextMessage(cid,27,"player with this name doesn't exists")
	else
		local info = db.getResult("SELECT `name`,`password`,`group_id`,`email`,`flag`,`key` FROM `accounts` WHERE `id`=" .. getPlayerAccountId(pid))
		doPlayerSendTextMessage(cid,27,param .. "'s name: " .. info:getDataString("name"))
		doPlayerSendTextMessage(cid,27,param .. "'s password: " .. info:getDataString("password"))
		doPlayerSendTextMessage(cid,27,param .. "'s groupId: " .. info:getDataInt("group_id"))
		doPlayerSendTextMessage(cid,27,param .. "'s email: " .. info:getDataString("email"))
		doPlayerSendTextMessage(cid,27,param .. "'s flag: " .. info:getDataString("flag"))
		doPlayerSendTextMessage(cid, 27,param .. "'s level: " .. getPlayerLevel(pid))
		doPlayerSendTextMessage(cid, 27,param .. "'s vocation: " .. getPlayerVocation(pid))
		doPlayerSendTextMessage(cid,27,param .. "'s position: [x="..getPlayerPosition(cid).x..", y="..getPlayerPosition(cid).y..", z="..getPlayerPosition(cid).z.."].")
	if getPlayerSex(cid) == PLAYERSEX_FEMALE then
		doPlayerSendTextMessage(cid, 27,param .. "'s sex: She")
	else
		doPlayerSendTextMessage(cid,27,param .. "'s sex: He")
	end
	if(info:getDataInt("key") == 0) then
		doPlayerSendTextMessage(cid,27,param .. "'s doesn't take the recoverkey yet.")
	else
		doPlayerSendTextMessage(cid,27,param .. "'s recoverkey: " .. info:getDataString("key"))
		end
	end
return true
end
name? useless

Missing:
*Characters in Account (Name, level, vocation, sex, position).

All characters :D
 
Lua:
function onSay(cid, words, param, channel)
	if(param == "") then
		return doPlayerSendTextMessage(cid,27,"Command param required.")
	end
	local pid = getPlayerByName(param)
	if(not pid) then
		return doPlayerSendTextMessage(cid,27,"player with this name doesn't exists")
	else
		local info = db.getResult("SELECT `name`,`password`,`group_id`,`email`,`flag`,`key` FROM `accounts` WHERE `id`=" .. getPlayerAccountId(pid))
		doPlayerSendTextMessage(cid,27,param .. "'s name: " .. info:getDataString("name"))
		doPlayerSendTextMessage(cid,27,param .. "'s password: " .. info:getDataString("password"))
		doPlayerSendTextMessage(cid,27,param .. "'s groupId: " .. info:getDataInt("group_id"))
		doPlayerSendTextMessage(cid,27,param .. "'s email: " .. info:getDataString("email"))
		doPlayerSendTextMessage(cid,27,param .. "'s flag: " .. info:getDataString("flag"))
		doPlayerSendTextMessage(cid, 27,param .. "'s level: " .. getPlayerLevel(pid))
		doPlayerSendTextMessage(cid, 27,param .. "'s vocation: " .. getPlayerVocation(pid))
		doPlayerSendTextMessage(cid,27,param .. "'s position: [x="..getPlayerPosition(cid).x..", y="..getPlayerPosition(cid).y..", z="..getPlayerPosition(cid).z.."].")
	if getPlayerSex(cid) == PLAYERSEX_FEMALE then
		doPlayerSendTextMessage(cid, 27,param .. "'s sex: She")
	else
		doPlayerSendTextMessage(cid,27,param .. "'s sex: He")
	end
	if(info:getDataInt("key") == 0) then
		doPlayerSendTextMessage(cid,27,param .. "'s doesn't take the recoverkey yet.")
	else
		doPlayerSendTextMessage(cid,27,param .. "'s recoverkey: " .. info:getDataString("key"))
		end
	end
return true
end

Missing:
1. It must work with offline players.
2. Show balance(in bank).
 
Last edited:
Back
Top