Hiya!
Here you have a very comical script which will let you talk THROUGH any player xD:
First:
Type this into your data/talkactions/talkactions.xml file:
Then, go to data/talkactions/scripts/ and create a .lua file called parrot.lua. Within it, paste this using Notepad or any text editor:
Where:
idgroup
is the minimun group id to use this command.
Then, ingame, type this to make a player say whatever you want:
/parrot "playername,text
If you find any bug, just tell it to me.
Greetz
Here you have a very comical script which will let you talk THROUGH any player xD:
First:
Type this into your data/talkactions/talkactions.xml file:
PHP:
<talkaction words="/parrot" script="parrot.lua"/>
Then, go to data/talkactions/scripts/ and create a .lua file called parrot.lua. Within it, paste this using Notepad or any text editor:
PHP:
local idgroup = 5 --Min Group Access
function onSay(cid, words, param)
if getPlayerGroupId(cid) < idgroup then
doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, "You aren't allowed to use this command")
elseif param ~= "" then
if string.find(param, ',') ~= nil then
local sep1 = string.find(param, ',')
local param1 = string.sub(param, 1, sep1-1)
local param2 = string.sub(param,sep1+1,string.len(param))
local target = getPlayerByName(param1)
if target == FALSE then
doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, "A player with that name is not online")
elseif param1 == "" then
doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, "You must type a player")
elseif (param2 == "") then
doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, "You must type some text")
elseif words == "/parrot" then
player = getCreatureName(target)
text = param2
doCreatureSay(target,text,1)
doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, player.. " has said: "..text)
end
else
doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, "Wrong format: /parrot \"Player,Text")
end
else
doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, "You must type a player and some text")
end
end
Where:
idgroup
is the minimun group id to use this command.
Then, ingame, type this to make a player say whatever you want:
/parrot "playername,text
If you find any bug, just tell it to me.
Greetz
Last edited: