• 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!
  • New resources must be posted under Resources tab. A discussion thread will be created automatically, you can't open threads manually anymore.

TalkAction Monster Outfit

Evil Hero

Legacy Member
TFS Developer
Joined
Dec 12, 2007
Messages
1,262
Solutions
28
Reaction score
737
Location
Germany
Hello everybody :D

This Script will make it able that you can change your outfit within a talkaction just by saying the monsters name like

/outfit "demon

The access atm is set to "1" Tutors or higher can use it :p

UPDATE! Now you can use it for evo or tfs and some not needed things are deleted.

If there are bugs post them here I'll try to make it work for you then :)

and here is the Script:

PHP:
--Monster Outfit V3.0 Made by Evil Hero (TFS)--
 
function onSay(cid, words, param)
    local counsellor = 1 --Access to use the Command
    local time = -1 --Infinity time at the moment
    if getPlayerGroupId(cid) >= counsellor then
        if param ~= "" then
            doSetMonsterOutfit(cid, param, time)
            doPlayerSendTextMessage(cid, 25, "You have changed your outfit to a ".. param ..".")
		else
			doPlayerSendCancel(cid,"Param can't be nil.")
		end
	else
        doPlayerSendCancel(cid,"You cannot execute this command.")
    end
	return FALSE
end

PHP:
--Monster Outfit V3.0 Made by Evil Hero (EVO)--
 
function onSay(cid, words, param)
    local counsellor = 1 --Access to use the Command
    local time = -1 --Infinity time at the moment
    if getPlayerAccess(cid) >= counsellor then
        if param ~= "" then
            doSetMonsterOutfit(cid, param, time)
            doPlayerSendTextMessage(cid, 25, "You have changed your outfit to a ".. param ..".")
		else
			doPlayerSendCancel(cid,"Param can't be nil.")
		end
	else
        doPlayerSendCancel(cid,"You cannot execute this command.")
    end
	return FALSE
end

and put this into "talkactions.xml"

Code:
<talkaction words="/outfit" script="outfit.lua" />

hope some people might enjoy this :)

kind regards, Evil Hero
 
Last edited:
Nice script!
Easier than using /newtype and having to guess the outfit's number :p
 
Check first post made a bug fix! :p

yours Evil Hero,
 
Like you can see no 1 really leaves a msg in this thread so it would be nice if you could tell me if it worked or not after you tested it :p

yours Evil Hero,
 
I'll answer that for him...
It works but what the hell is this:
Code:
        doPlayerSetAccess(cid,3)
No need for that to be included.
 
So this doesn't work with The Forgotten Server, They are using group id's and account types..?
 
Back
Top