• 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!

[MOD] Characters Market System (In Game)

Dalt0n

Hiho:)
Joined
Dec 14, 2011
Messages
536
Reaction score
31
Location
Italia
Hi otland users,
I found this system and I found very good,
Market is a system for characters,

That is, you can buy characters for money, and transferred ea automatically remember your account
This system is configurable, and can be edited to remove rather than money, remove points and auto add on page.

marketchar.xml
XML:
<?xml version="1.0" encoding="ISO-8859-1"?>
<mod name="Characters Market System" version="1.0" author="LuckOake" contact="none" enabled="yes">
------------------------------------------------------------------------------------
<config name="market"><![CDATA[
price = 27112
owner = 27113
level = 30 -- Level min of character.--
min_price = 100 -- Price min of character--
max_price = 1000000 -- Price maximum of character--
 
function doTransferCharacter(cid, accId)
        return db.executeQuery("UPDATE `players` SET `account_id` = "..accId.." WHERE `id` = "..getPlayerGUIDByName(cid).."")
end
 
function doOfflinePlayerAddMoney(guid, money)
        return db.executeQuery("UPDATE `players` SET `balance` = `balance` + '"..money.."' WHERE `id` = '"..getPlayerGUIDByName(guid).."';")
end
 
function setOfflinePlayerStorageValue(name, key, value)
        local result = db.getResult("SELECT * FROM `player_storage` WHERE `player_id` = ".. getPlayerGUIDByName(name) .." AND `key` = ".. key ..";")
        if result:getID() == -1 then
                return db.executeQuery("INSERT INTO `player_storage` (`player_id`, `key`, `value`) VALUES (".. getPlayerGUIDByName(name) ..", ".. key ..", ".. value ..");")
        else
                result:free()
                return db.executeQuery("UPDATE `player_storage` SET `value` = ".. value .." WHERE `player_id` = ".. getPlayerGUIDByName(name) .." AND `key` = ".. key ..";")
        end
end
 
function getOfflinePlayerStorageValue(name, key)
        local result, ret = db.getResult("SELECT `value` FROM `player_storage` WHERE `player_id` = '".. getPlayerGUIDByName(name) .."' AND `key` = ".. key ..";")
        if result:getID() == -1 then
                return nil
        end
        ret = result:getDataInt("value")
        result:free()
        return ret
end
 
function getOfflinePlayerValue(name, value)
        local result, ret = db.getResult("SELECT `"..value.."` FROM `players` WHERE `id` = "..getPlayerGUIDByName(name)..";")
        ret = result:getDataInt(value)
        result:free()
        return ret
end
 
function isCharacterForSale(name)
        if not getOfflinePlayerStorageValue(name, price) or getOfflinePlayerStorageValue(name, price) < 1 then
        return false
        else
        return true
        end
end
]]></config>
------------------------------------------------------------------------------------
<talkaction words="!character" event="buffer"><![CDATA[
domodlib('market')
        local t = string.explode(param, ",")
       
        if t[1] == "sell" then
                if not t[3] or not tonumber(t[3]) or t[4] or tonumber(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Incorrect Params. Specify the character name and the price.") return true
                elseif getPlayerAccountId(cid) ~= getAccountIdByName(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This is not your character.") return true
                elseif isCharacterForSale(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This character is already for sale.") return true
                elseif getPlayerGUIDByName(t[2]) == getPlayerGUID(cid) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "You cannot sell yourself.") return true
                elseif getPlayerByName(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "The character must be offline to be sold.") return true
                elseif getOfflinePlayerValue(t[2], "level") < level then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Your character can't be sold until it has level "..level..".") return true
                elseif tonumber(t[3]) < min_price then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Sorry, but the minimum price for selling a character is "..min_price..".") return true
                elseif tonumber(t[3]) > max_price then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Sorry, but the maximum price for selling a character is "..max_price..".") return true
                end
       
                        setOfflinePlayerStorageValue(t[2], price, t[3])
                        setOfflinePlayerStorageValue(t[2], owner, getPlayerGUID(cid))
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'Your character "'..t[2]..'" is now for sale for the price of "'..t[3]..'" gold coins.')
        elseif t[1] == "buy" then
                if not t[2] then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Incorrect Params. Specify the character name.") return true
                elseif not playerExists(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This character doesn't exist.") return true
                elseif getPlayerAccountId(cid) == getAccountIdByName(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "You can't buy your own character.") return true
                elseif not isCharacterForSale(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This character is not for sale.") return true
                elseif not doPlayerRemoveMoney(cid, getOfflinePlayerStorageValue(t[2], price)) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Not enough money. This character's price is "..getOfflinePlayerStorageValue(t[2], price).." gold coins.") return true
                end
                       
                if not getPlayerByGUID(getOfflinePlayerStorageValue(t[2], owner)) then
                        doOfflinePlayerAddMoney(getPlayerNameByGUID(getOfflinePlayerStorageValue(t[2], owner)), getOfflinePlayerStorageValue(t[2], price))
                        setOfflinePlayerStorageValue(getPlayerNameByGUID(getOfflinePlayerStorageValue(t[2], owner)), 41792, getPlayerGUIDByName(t[2]))
                else
                        doPlayerAddMoney(getPlayerByGUID(getOfflinePlayerStorageValue(t[2], owner)), getOfflinePlayerStorageValue(t[2], price))
                        doPlayerSendTextMessage(getPlayerByGUID(getOfflinePlayerStorageValue(t[2], owner)), MESSAGE_STATUS_CONSOLE_BLUE, 'Your character "'..t[2]..'" has been sold for the price of '..getOfflinePlayerStorageValue(t[2], price)..' gold coins.')
                end
                        doTransferCharacter(t[2], getPlayerAccountId(cid))
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'You bought the character "'..t[2]..'" for the price of '..getOfflinePlayerStorageValue(t[2], price)..' gold coins.')
                        setOfflinePlayerStorageValue(t[2], owner, -1)
                        setOfflinePlayerStorageValue(t[2], price, -1) return true
        elseif t[1] == "remove" then
                if not t[2] then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Incorrect Params. Specify the character name.") return true
                elseif getPlayerAccountId(cid) ~= getAccountIdByName(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This is not your character.") return true
                elseif not isCharacterForSale(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This character is not for sale.") return true
                end
               
                        setOfflinePlayerStorageValue(t[2], price, -1)
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'You removed the character "'..t[2]..'" from the Characters Market.') return true
        elseif t[1] == "list" then
                local result = db.getResult("SELECT `name` FROM `players`")
                if result:getID() == -1 then
                        return true
                end
                local msg = "Characters for Sale:\n\n"
                while true do
                        local name = result:getDataString("name")
                        if isCharacterForSale(name) then
                        local sex = getOfflinePlayerValue(name, "sex") == 1 and "Male" or "Female"
                                msg = ""..msg.." - ".. name .." (Level: "..getOfflinePlayerValue(name, "level").." / Vocation: "..getVocationInfo(getOfflinePlayerValue(name, "vocation")).name.." / Sex: "..sex.." / Owner: "..getPlayerNameByGUID(getOfflinePlayerStorageValue(name, owner))..") [Price: "..getOfflinePlayerStorageValue(name, price).."] \n"
                        end
                        if not result:next() then
                                break
                        end
                end
                        doPlayerPopupFYI(cid, msg) return true
        elseif not t[1] or t[1] ~= "buy" or t[1] ~= "sell" or t[1] ~= "remove" or t[1] ~= "list" then
                doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Incorrect params. You can only 'buy' or 'sell' a character, 'remove' it from the Characters Market or see the 'list' of characters for sale.") return true
        end
return true
]]></talkaction>
------------------------------------------------------------------------------------
<event type="login" name="MarketLogin" event="script"><![CDATA[
function onLogin(cid)
domodlib('market')
        if getPlayerStorageValue(cid, price) > 0 then return false
        elseif getPlayerStorageValue(cid, 41792) ~= -1 then
                doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "You sold the character "..getPlayerNameByGUID(getPlayerStorageValue(cid, 41792))..". The money is in your bank account.")
                setPlayerStorageValue(cid, 41792, -1)
        end
return true
end
]]></event>
</mod>

If you get the error of UTF-8..
Then change:
Code:
<?xml version="1.0" encoding="UTF-8"?>
to
Code:
<?xml version="1.0" encoding="ISO-8859-1"?>

Screens:
cmdsi.png

listzh.png

cmds2.png

charsd.png


Commands:
!character buy,name -- buy one character
!character sell,name,price --sell character
!character remove,name -- remove character of characterList
!character list -- see the list of characters

Créditos:
LuckOake
Oneshot
Demonbholder
 
Up and dobleup: Test ..

Code:
<?xml version="1.0" encoding="ISO-8859-1"?>
<mod name="Characters Market System" version="1.0" author="LuckOake" contact="none" enabled="yes">
------------------------------------------------------------------------------------
<config name="market"><![CDATA[
price = 27112
owner = 27113
level = 30 -- Level min of character.--
min_price = 1 -- Price min of character--
max_price = 100 -- Price maximum of character--
 
function doTransferCharacter(cid, accId)
        return db.executeQuery("UPDATE `players` SET `account_id` = "..accId.." WHERE `id` = "..getPlayerGUIDByName(cid).."")
end
 
function doOfflinePlayerAddMoney(guid, money)
        return db.executeQuery("UPDATE `players` SET `balance` = `balance` + '"..money.."' WHERE `id` = '"..getPlayerGUIDByName(guid).."';")
end
 
function setOfflinePlayerStorageValue(name, key, value)
        local result = db.getResult("SELECT * FROM `player_storage` WHERE `player_id` = ".. getPlayerGUIDByName(name) .." AND `key` = ".. key ..";")
        if result:getID() == -1 then
                return db.executeQuery("INSERT INTO `player_storage` (`player_id`, `key`, `value`) VALUES (".. getPlayerGUIDByName(name) ..", ".. key ..", ".. value ..");")
        else
                result:free()
                return db.executeQuery("UPDATE `player_storage` SET `value` = ".. value .." WHERE `player_id` = ".. getPlayerGUIDByName(name) .." AND `key` = ".. key ..";")
        end
end
 
function getOfflinePlayerStorageValue(name, key)
        local result, ret = db.getResult("SELECT `value` FROM `player_storage` WHERE `player_id` = '".. getPlayerGUIDByName(name) .."' AND `key` = ".. key ..";")
        if result:getID() == -1 then
                return nil
        end
        ret = result:getDataInt("value")
        result:free()
        return ret
end
 
function getOfflinePlayerValue(name, value)
        local result, ret = db.getResult("SELECT `"..value.."` FROM `players` WHERE `id` = "..getPlayerGUIDByName(name)..";")
        ret = result:getDataInt(value)
        result:free()
        return ret
end
 
function isCharacterForSale(name)
        if not getOfflinePlayerStorageValue(name, price) or getOfflinePlayerStorageValue(name, price) < 1 then
        return false
        else
        return true
        end
end
]]></config>
------------------------------------------------------------------------------------
<talkaction words="!character" event="buffer"><![CDATA[
domodlib('market')
        local t = string.explode(param, ",")
 
        if t[1] == "sell" then
                if not t[3] or not tonumber(t[3]) or t[4] or tonumber(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Incorrect Params. Specify the character name and the price.") return true
                elseif getPlayerAccountId(cid) ~= getAccountIdByName(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This is not your character.") return true
                elseif isCharacterForSale(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This character is already for sale.") return true
                elseif getPlayerGUIDByName(t[2]) == getPlayerGUID(cid) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "You cannot sell yourself.") return true
                elseif getPlayerByName(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "The character must be offline to be sold.") return true
                elseif getOfflinePlayerValue(t[2], "level") < level then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Your character can't be sold until it has level "..level..".") return true
                elseif tonumber(t[3]) < min_price then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Sorry, but the minimum price for selling a character is "..min_price..".") return true
                elseif tonumber(t[3]) > max_price then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Sorry, but the maximum price for selling a character is "..max_price..".") return true
                end
 
                        setOfflinePlayerStorageValue(t[2], price, t[3])
                        setOfflinePlayerStorageValue(t[2], owner, getPlayerGUID(cid))
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'Your character "'..t[2]..'" is now for sale for the price of "'..t[3]..'" gold coins.')
        elseif t[1] == "buy" then
                if not t[2] then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Incorrect Params. Specify the character name.") return true
                elseif not playerExists(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This character doesn't exist.") return true
                elseif getPlayerAccountId(cid) == getAccountIdByName(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "You can't buy your own character.") return true
                elseif not isCharacterForSale(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This character is not for sale.") return true
                elseif not doRemovePoints(cid, getOfflinePlayerStorageValue(t[2], price)) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Not enough points. This character's price is "..getOfflinePlayerStorageValue(t[2], price).." premium points.") return true
                end
 
                if not getPlayerByGUID(getOfflinePlayerStorageValue(t[2], owner)) then
                        doOfflinePlayerAddMoney(getPlayerNameByGUID(getOfflinePlayerStorageValue(t[2], owner)), getOfflinePlayerStorageValue(t[2], price))
                        setOfflinePlayerStorageValue(getPlayerNameByGUID(getOfflinePlayerStorageValue(t[2], owner)), 41792, getPlayerGUIDByName(t[2]))
                else
                        doPlayerAddMoney(getPlayerByGUID(getOfflinePlayerStorageValue(t[2], owner)), getOfflinePlayerStorageValue(t[2], price))
                        doPlayerSendTextMessage(getPlayerByGUID(getOfflinePlayerStorageValue(t[2], owner)), MESSAGE_STATUS_CONSOLE_BLUE, 'Your character "'..t[2]..'" has been sold for the price of '..getOfflinePlayerStorageValue(t[2], price)..' gold coins.')
                end
                        doTransferCharacter(t[2], getPlayerAccountId(cid))
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'You bought the character "'..t[2]..'" for the price of '..getOfflinePlayerStorageValue(t[2], price)..' gold coins.')
                        setOfflinePlayerStorageValue(t[2], owner, -1)
                        setOfflinePlayerStorageValue(t[2], price, -1) return true
        elseif t[1] == "remove" then
                if not t[2] then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Incorrect Params. Specify the character name.") return true
                elseif getPlayerAccountId(cid) ~= getAccountIdByName(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This is not your character.") return true
                elseif not isCharacterForSale(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This character is not for sale.") return true
                end
 
                        setOfflinePlayerStorageValue(t[2], price, -1)
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'You removed the character "'..t[2]..'" from the Characters Market.') return true
        elseif t[1] == "list" then
                local result = db.getResult("SELECT `name` FROM `players`")
                if result:getID() == -1 then
                        return true
                end
                local msg = "Characters for Sale:\n\n"
                while true do
                        local name = result:getDataString("name")
                        if isCharacterForSale(name) then
                        local sex = getOfflinePlayerValue(name, "sex") == 1 and "Male" or "Female"
                                msg = ""..msg.." - ".. name .." (Level: "..getOfflinePlayerValue(name, "level").." / Vocation: "..getVocationInfo(getOfflinePlayerValue(name, "vocation")).name.." / Sex: "..sex.." / Owner: "..getPlayerNameByGUID(getOfflinePlayerStorageValue(name, owner))..") [Price: "..getOfflinePlayerStorageValue(name, price).."] \n"
                        end
                        if not result:next() then
                                break
                        end
                end
                        doPlayerPopupFYI(cid, msg) return true
        elseif not t[1] or t[1] ~= "buy" or t[1] ~= "sell" or t[1] ~= "remove" or t[1] ~= "list" then
                doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Incorrect params. You can only 'buy' or 'sell' a character, 'remove' it from the Characters Market or see the 'list' of characters for sale.") return true
        end
return true
]]></talkaction>
------------------------------------------------------------------------------------
<event type="login" name="MarketLogin" event="script"><![CDATA[
function onLogin(cid)
domodlib('market')
        if getPlayerStorageValue(cid, price) > 0 then return false
        elseif getPlayerStorageValue(cid, 41792) ~= -1 then
                doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "You sold the character "..getPlayerNameByGUID(getPlayerStorageValue(cid, 41792))..". The money is in your bank account.")
                setPlayerStorageValue(cid, 41792, -1)
        end
return true
end
]]></event>
</mod>
 
When i try to start the server send me an error "Unexpect error near "<"

Im new in this, what is happening?
i didnt change anything

[09/11/2012 19:51:56] [Error - LuaScriptInterface::loadFile] data/talkactions/scripts/character.lua:1: unexpected symbol near '<'
[09/11/2012 19:51:56] [Warning - Event::loadScript] Cannot load script (data/talkactions/scripts/character.lua)
[09/11/2012 19:51:56] data/talkactions/scripts/character.lua:1: unexpected symbol near '<'


I put this in talkaction.XML :

Code:
<talkaction value="character.lua" event="script" words="!character"/>

And this in character.lua (inside of "scripts"

Code:
<talkaction words="!character" event="buffer"><![CDATA[
domodlib('market')
        local t = string.explode(param, ",")
 
        if t[1] == "sell" then
                if not t[3] or not tonumber(t[3]) or t[4] or tonumber(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Incorrect Params. Specify the character name and the price.") return true
                elseif getPlayerAccountId(cid) ~= getAccountIdByName(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This is not your character.") return true
                elseif isCharacterForSale(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This character is already for sale.") return true
                elseif getPlayerGUIDByName(t[2]) == getPlayerGUID(cid) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "You cannot sell yourself.") return true
                elseif getPlayerByName(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "The character must be offline to be sold.") return true
                elseif getOfflinePlayerValue(t[2], "level") < level then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Your character can't be sold until it has level "..level..".") return true
                elseif tonumber(t[3]) < min_price then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Sorry, but the minimum price for selling a character is "..min_price..".") return true
                elseif tonumber(t[3]) > max_price then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Sorry, but the maximum price for selling a character is "..max_price..".") return true
                end
 
                        setOfflinePlayerStorageValue(t[2], price, t[3])
                        setOfflinePlayerStorageValue(t[2], owner, getPlayerGUID(cid))
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'Your character "'..t[2]..'" is now for sale for the price of "'..t[3]..'" gold coins.')
        elseif t[1] == "buy" then
                if not t[2] then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Incorrect Params. Specify the character name.") return true
                elseif not playerExists(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This character doesn't exist.") return true
                elseif getPlayerAccountId(cid) == getAccountIdByName(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "You can't buy your own character.") return true
                elseif not isCharacterForSale(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This character is not for sale.") return true
                elseif not doPlayerRemoveMoney(cid, getOfflinePlayerStorageValue(t[2], price)) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Not enough money. This character's price is "..getOfflinePlayerStorageValue(t[2], price).." gold coins.") return true
                end
 
                if not getPlayerByGUID(getOfflinePlayerStorageValue(t[2], owner)) then
                        doOfflinePlayerAddMoney(getPlayerNameByGUID(getOfflinePlayerStorageValue(t[2], owner)), getOfflinePlayerStorageValue(t[2], price))
                        setOfflinePlayerStorageValue(getPlayerNameByGUID(getOfflinePlayerStorageValue(t[2], owner)), 41792, getPlayerGUIDByName(t[2]))
                else
                        doPlayerAddMoney(getPlayerByGUID(getOfflinePlayerStorageValue(t[2], owner)), getOfflinePlayerStorageValue(t[2], price))
                        doPlayerSendTextMessage(getPlayerByGUID(getOfflinePlayerStorageValue(t[2], owner)), MESSAGE_STATUS_CONSOLE_BLUE, 'Your character "'..t[2]..'" has been sold for the price of '..getOfflinePlayerStorageValue(t[2], price)..' gold coins.')
                end
                        doTransferCharacter(t[2], getPlayerAccountId(cid))
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'You bought the character "'..t[2]..'" for the price of '..getOfflinePlayerStorageValue(t[2], price)..' gold coins.')
                        setOfflinePlayerStorageValue(t[2], owner, -1)
                        setOfflinePlayerStorageValue(t[2], price, -1) return true
        elseif t[1] == "remove" then
                if not t[2] then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Incorrect Params. Specify the character name.") return true
                elseif getPlayerAccountId(cid) ~= getAccountIdByName(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This is not your character.") return true
                elseif not isCharacterForSale(t[2]) then
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "This character is not for sale.") return true
                end
 
                        setOfflinePlayerStorageValue(t[2], price, -1)
                        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'You removed the character "'..t[2]..'" from the Characters Market.') return true
        elseif t[1] == "list" then
                local result = db.getResult("SELECT `name` FROM `players`")
                if result:getID() == -1 then
                        return true
                end
                local msg = "Characters for Sale:\n\n"
                while true do
                        local name = result:getDataString("name")
                        if isCharacterForSale(name) then
                        local sex = getOfflinePlayerValue(name, "sex") == 1 and "Male" or "Female"
                                msg = ""..msg.." - ".. name .." (Level: "..getOfflinePlayerValue(name, "level").." / Vocation: "..getVocationInfo(getOfflinePlayerValue(name, "vocation")).name.." / Sex: "..sex.." / Owner: "..getPlayerNameByGUID(getOfflinePlayerStorageValue(name, owner))..") [Price: "..getOfflinePlayerStorageValue(name, price).."] \n"
                        end
                        if not result:next() then
                                break
                        end
                end
                        doPlayerPopupFYI(cid, msg) return true
        elseif not t[1] or t[1] ~= "buy" or t[1] ~= "sell" or t[1] ~= "remove" or t[1] ~= "list" then
                doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Incorrect params. You can only 'buy' or 'sell' a character, 'remove' it from the Characters Market or see the 'list' of characters for sale.") return true
        end
return true
]]></talkaction>
------------------------------------------------------------------------------------
<event type="login" name="MarketLogin" event="script"><![CDATA[
function onLogin(cid)
domodlib('market')
        if getPlayerStorageValue(cid, price) > 0 then return false
        elseif getPlayerStorageValue(cid, 41792) ~= -1 then
                doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "You sold the character "..getPlayerNameByGUID(getPlayerStorageValue(cid, 41792))..". The money is in your bank account.")
                setPlayerStorageValue(cid, 41792, -1)
        end
return true
end
]]></event>
</mod>
 
Last edited:
u mad?

data/talkactions/scripts/character.lua:1:

LOL??

this code is MOD

placed in the folder MODS
 
then you no can used this script..
0.3+ and 0.4 have folder mod in folder exe,confic.lua,dlls..
 
for what mod? >.< he can cut from mod some lines and paste they in new scripts in talkactions/npc etc.
 
This MOD have litle bug...
Type !character list... in console bug
Code:
[18/11/2012 18:27:9] local cid = 268476496
[18/11/2012 18:27:9] local words = "!character"
[18/11/2012 18:27:9] local param = "list"
[18/11/2012 18:27:9] local channel = 65534
[18/11/2012 18:27:9] domodlib('market')
[18/11/2012 18:27:9]         local t = string.explode(param, ",")
[18/11/2012 18:27:9]       
[18/11/2012 18:27:9]         if t[1] == "sell" then
[18/11/2012 18:27:9]                 if not t[3] or not tonumber(t[3]) or t[4] or tonumber(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Parametro Incorrecto, Especifique el nombre del Char y el precio.") return true
[18/11/2012 18:27:9]                 elseif getPlayerAccountId(cid) ~= getAccountIdByName(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Este no es su Char.") return true
[18/11/2012 18:27:9]                 elseif isCharacterForSale(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Este Char ya se vendio.") return true
[18/11/2012 18:27:9]                 elseif getPlayerGUIDByName(t[2]) == getPlayerGUID(cid) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "No te puedes vender tu mismo.") return true
[18/11/2012 18:27:9]                 elseif getPlayerByName(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "The character must be offline to be sold.") return true
[18/11/2012 18:27:9]                 elseif getOfflinePlayerValue(t[2], "level") < level then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Your character can't be sold until it has level "..level..".") return true
[18/11/2012 18:27:9]                 elseif tonumber(t[3]) < min_price then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Disculpa, pero el precio minimo a la venta de los char es "..min_price..".") return true
[18/11/2012 18:27:9]                 elseif tonumber(t[3]) > max_price then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Disculpa, pero el precio Maximo a la venta de los char es "..max_price..".") return true
[18/11/2012 18:27:9]                 end
[18/11/2012 18:27:9]       
[18/11/2012 18:27:9]                         setOfflinePlayerStorageValue(t[2], price, t[3])
[18/11/2012 18:27:9]                         setOfflinePlayerStorageValue(t[2], owner, getPlayerGUID(cid))
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'Tu Char "'..t[2]..'" esta ahora en venta por el precio de "'..t[3]..'" gold coins.')
[18/11/2012 18:27:9]         elseif t[1] == "buy" then
[18/11/2012 18:27:9]                 if not t[2] then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Parametro Incorrecto, Especifique el nombre del Char. ") return true
[18/11/2012 18:27:9]                 elseif not playerExists(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Este Char no Existe.") return true
[18/11/2012 18:27:9]                 elseif getPlayerAccountId(cid) == getAccountIdByName(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "No puedes comprar tu mismo Char.") return true
[18/11/2012 18:27:9]                 elseif not isCharacterForSale(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Este char no esta a la venta.") return true
[18/11/2012 18:27:9]                 elseif not doPlayerRemoveMoney(cid, getOfflinePlayerStorageValue(t[2], price)) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "No tienes dinero. Este char se vende en "..getOfflinePlayerStorageValue(t[2], price).." gold coins.") return true
[18/11/2012 18:27:9]                 end
[18/11/2012 18:27:9]                       
[18/11/2012 18:27:9]                 if not getPlayerByGUID(getOfflinePlayerStorageValue(t[2], owner)) then
[18/11/2012 18:27:9]                         doOfflinePlayerAddMoney(getPlayerNameByGUID(getOfflinePlayerStorageValue(t[2], owner)), getOfflinePlayerStorageValue(t[2], price))
[18/11/2012 18:27:9]                         setOfflinePlayerStorageValue(getPlayerNameByGUID(getOfflinePlayerStorageValue(t[2], owner)), 41792, getPlayerGUIDByName(t[2]))
[18/11/2012 18:27:9]                 else
[18/11/2012 18:27:9]                         doPlayerAddMoney(getPlayerByGUID(getOfflinePlayerStorageValue(t[2], owner)), getOfflinePlayerStorageValue(t[2], price))
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(getPlayerByGUID(getOfflinePlayerStorageValue(t[2], owner)), MESSAGE_STATUS_CONSOLE_BLUE, 'Your character "'..t[2]..'" has been sold for the price of '..getOfflinePlayerStorageValue(t[2], price)..' gold coins.')
[18/11/2012 18:27:9]                 end
[18/11/2012 18:27:9]                         doTransferCharacter(t[2], getPlayerAccountId(cid))
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'Tu Has comprado el Char "'..t[2]..'" `por el precio de '..getOfflinePlayerStorageValue(t[2], price)..' gold coins.')
[18/11/2012 18:27:9]                         setOfflinePlayerStorageValue(t[2], owner, -1)
[18/11/2012 18:27:9]                         setOfflinePlayerStorageValue(t[2], price, -1) return true
[18/11/2012 18:27:9]         elseif t[1] == "remove" then
[18/11/2012 18:27:9]                 if not t[2] then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Parametro Incorrecto, Especifique el nombre del Char ") return true
[18/11/2012 18:27:9]                 elseif getPlayerAccountId(cid) ~= getAccountIdByName(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Este no es tu char.") return true
[18/11/2012 18:27:9]                 elseif not isCharacterForSale(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Este char no esta a la venta.") return true
[18/11/2012 18:27:9]                 end
[18/11/2012 18:27:9]               
[18/11/2012 18:27:9]                         setOfflinePlayerStorageValue(t[2], price, -1)
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'You removed the character "'..t[2]..'" from the Characters Market.') return true
[18/11/2012 18:27:9]         elseif t[1] == "list" then
[18/11/2012 18:27:9]                 local result = db.getResult("SELECT `name` FROM `players`")
[18/11/2012 18:27:9]                 if result:getID() == -1 then
[18/11/2012 18:27:9]                         return true
[18/11/2012 18:27:9]                 end
[18/11/2012 18:27:9]                 local msg = "Characters for Sale:\n\n"
[18/11/2012 18:27:9]                 while true do
[18/11/2012 18:27:9]                         local name = result:getDataString("name")
[18/11/2012 18:27:9]                         if isCharacterForSale(name) then
[18/11/2012 18:27:9]                         local sex = getOfflinePlayerValue(name, "sex") == 1 and "Male" or "Female"
[18/11/2012 18:27:9]                                 msg = ""..msg.." - ".. name .." (Level: "..getOfflinePlayerValue(name, "level").." / Vocation: "..getVocationInfo(getOfflinePlayerValue(name, "vocation")).name.." / Sex: "..sex.." / Owner: "..getPlayerNameByGUID(getOfflinePlayerStorageValue(name, owner))..") [Price: "..getOfflinePlayerStorageValue(name, price).."] \n"
[18/11/2012 18:27:9]                         end
[18/11/2012 18:27:9]                         if not result:next() then
[18/11/2012 18:27:9]                                 break
[18/11/2012 18:27:9]                         end
[18/11/2012 18:27:9]                 end
[18/11/2012 18:27:9]                         doPlayerPopupFYI(cid, msg) return true
[18/11/2012 18:27:9]         elseif not t[1] or t[1] ~= "buy" or t[1] ~= "sell" or t[1] ~= "remove" or t[1] ~= "list" then
[18/11/2012 18:27:9]                 doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Incorrect params. You can only 'buy' or 'sell' a character, 'remove' it from the Characters Market or see the 'list' of characters for sale.") return true
[18/11/2012 18:27:9]         end
[18/11/2012 18:27:9] return true

[18/11/2012 18:27:9] Description: 
[18/11/2012 18:27:9] [string "price = 27112..."]:26: attempt to concatenate a nil value

=( Please Help me
 
look i put a char on market for 100k but when i logged in to my other acc and was going to buy that char i did receive the character that i bought but i didn't get the money on the other acc...

Help me!
 
look i put a char on market for 100k but when i logged in to my other acc and was going to buy that char i did receive the character that i bought but i didn't get the money on the other acc...

Help me!

Check the bank or dp of the other account.
 
Wait, how can i fix the error !character list, it sends me a huge a$$ error in console and doesnt show any list ingame

Code:
[18/11/2012 18:27:9] local cid = 268476496
[18/11/2012 18:27:9] local words = "!character"
[18/11/2012 18:27:9] local param = "list"
[18/11/2012 18:27:9] local channel = 65534
[18/11/2012 18:27:9] domodlib('market')
[18/11/2012 18:27:9]         local t = string.explode(param, ",")
[18/11/2012 18:27:9]       
[18/11/2012 18:27:9]         if t[1] == "sell" then
[18/11/2012 18:27:9]                 if not t[3] or not tonumber(t[3]) or t[4] or tonumber(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Parametro Incorrecto, Especifique el nombre del Char y el precio.") return true
[18/11/2012 18:27:9]                 elseif getPlayerAccountId(cid) ~= getAccountIdByName(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Este no es su Char.") return true
[18/11/2012 18:27:9]                 elseif isCharacterForSale(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Este Char ya se vendio.") return true
[18/11/2012 18:27:9]                 elseif getPlayerGUIDByName(t[2]) == getPlayerGUID(cid) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "No te puedes vender tu mismo.") return true
[18/11/2012 18:27:9]                 elseif getPlayerByName(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "The character must be offline to be sold.") return true
[18/11/2012 18:27:9]                 elseif getOfflinePlayerValue(t[2], "level") < level then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Your character can't be sold until it has level "..level..".") return true
[18/11/2012 18:27:9]                 elseif tonumber(t[3]) < min_price then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Disculpa, pero el precio minimo a la venta de los char es "..min_price..".") return true
[18/11/2012 18:27:9]                 elseif tonumber(t[3]) > max_price then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Disculpa, pero el precio Maximo a la venta de los char es "..max_price..".") return true
[18/11/2012 18:27:9]                 end
[18/11/2012 18:27:9]       
[18/11/2012 18:27:9]                         setOfflinePlayerStorageValue(t[2], price, t[3])
[18/11/2012 18:27:9]                         setOfflinePlayerStorageValue(t[2], owner, getPlayerGUID(cid))
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'Tu Char "'..t[2]..'" esta ahora en venta por el precio de "'..t[3]..'" gold coins.')
[18/11/2012 18:27:9]         elseif t[1] == "buy" then
[18/11/2012 18:27:9]                 if not t[2] then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Parametro Incorrecto, Especifique el nombre del Char. ") return true
[18/11/2012 18:27:9]                 elseif not playerExists(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Este Char no Existe.") return true
[18/11/2012 18:27:9]                 elseif getPlayerAccountId(cid) == getAccountIdByName(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "No puedes comprar tu mismo Char.") return true
[18/11/2012 18:27:9]                 elseif not isCharacterForSale(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Este char no esta a la venta.") return true
[18/11/2012 18:27:9]                 elseif not doPlayerRemoveMoney(cid, getOfflinePlayerStorageValue(t[2], price)) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "No tienes dinero. Este char se vende en "..getOfflinePlayerStorageValue(t[2], price).." gold coins.") return true
[18/11/2012 18:27:9]                 end
[18/11/2012 18:27:9]                       
[18/11/2012 18:27:9]                 if not getPlayerByGUID(getOfflinePlayerStorageValue(t[2], owner)) then
[18/11/2012 18:27:9]                         doOfflinePlayerAddMoney(getPlayerNameByGUID(getOfflinePlayerStorageValue(t[2], owner)), getOfflinePlayerStorageValue(t[2], price))
[18/11/2012 18:27:9]                         setOfflinePlayerStorageValue(getPlayerNameByGUID(getOfflinePlayerStorageValue(t[2], owner)), 41792, getPlayerGUIDByName(t[2]))
[18/11/2012 18:27:9]                 else
[18/11/2012 18:27:9]                         doPlayerAddMoney(getPlayerByGUID(getOfflinePlayerStorageValue(t[2], owner)), getOfflinePlayerStorageValue(t[2], price))
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(getPlayerByGUID(getOfflinePlayerStorageValue(t[2], owner)), MESSAGE_STATUS_CONSOLE_BLUE, 'Your character "'..t[2]..'" has been sold for the price of '..getOfflinePlayerStorageValue(t[2], price)..' gold coins.')
[18/11/2012 18:27:9]                 end
[18/11/2012 18:27:9]                         doTransferCharacter(t[2], getPlayerAccountId(cid))
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'Tu Has comprado el Char "'..t[2]..'" `por el precio de '..getOfflinePlayerStorageValue(t[2], price)..' gold coins.')
[18/11/2012 18:27:9]                         setOfflinePlayerStorageValue(t[2], owner, -1)
[18/11/2012 18:27:9]                         setOfflinePlayerStorageValue(t[2], price, -1) return true
[18/11/2012 18:27:9]         elseif t[1] == "remove" then
[18/11/2012 18:27:9]                 if not t[2] then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Parametro Incorrecto, Especifique el nombre del Char ") return true
[18/11/2012 18:27:9]                 elseif getPlayerAccountId(cid) ~= getAccountIdByName(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Este no es tu char.") return true
[18/11/2012 18:27:9]                 elseif not isCharacterForSale(t[2]) then
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Este char no esta a la venta.") return true
[18/11/2012 18:27:9]                 end
[18/11/2012 18:27:9]               
[18/11/2012 18:27:9]                         setOfflinePlayerStorageValue(t[2], price, -1)
[18/11/2012 18:27:9]                         doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'You removed the character "'..t[2]..'" from the Characters Market.') return true
[18/11/2012 18:27:9]         elseif t[1] == "list" then
[18/11/2012 18:27:9]                 local result = db.getResult("SELECT `name` FROM `players`")
[18/11/2012 18:27:9]                 if result:getID() == -1 then
[18/11/2012 18:27:9]                         return true
[18/11/2012 18:27:9]                 end
[18/11/2012 18:27:9]                 local msg = "Characters for Sale:\n\n"
[18/11/2012 18:27:9]                 while true do
[18/11/2012 18:27:9]                         local name = result:getDataString("name")
[18/11/2012 18:27:9]                         if isCharacterForSale(name) then
[18/11/2012 18:27:9]                         local sex = getOfflinePlayerValue(name, "sex") == 1 and "Male" or "Female"
[18/11/2012 18:27:9]                                 msg = ""..msg.." - ".. name .." (Level: "..getOfflinePlayerValue(name, "level").." / Vocation: "..getVocationInfo(getOfflinePlayerValue(name, "vocation")).name.." / Sex: "..sex.." / Owner: "..getPlayerNameByGUID(getOfflinePlayerStorageValue(name, owner))..") [Price: "..getOfflinePlayerStorageValue(name, price).."] \n"
[18/11/2012 18:27:9]                         end
[18/11/2012 18:27:9]                         if not result:next() then
[18/11/2012 18:27:9]                                 break
[18/11/2012 18:27:9]                         end
[18/11/2012 18:27:9]                 end
[18/11/2012 18:27:9]                         doPlayerPopupFYI(cid, msg) return true
[18/11/2012 18:27:9]         elseif not t[1] or t[1] ~= "buy" or t[1] ~= "sell" or t[1] ~= "remove" or t[1] ~= "list" then
[18/11/2012 18:27:9]                 doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Incorrect params. You can only 'buy' or 'sell' a character, 'remove' it from the Characters Market or see the 'list' of characters for sale.") return true
[18/11/2012 18:27:9]         end
[18/11/2012 18:27:9] return true

[18/11/2012 18:27:9] Description: 
[18/11/2012 18:27:9] [string "price = 27112..."]:26: attempt to concatenate a nil value
 
Back
Top