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

Solved God Outfit.

Exoltes

Novia OTserv Developer
Joined
Jul 2, 2009
Messages
563
Reaction score
47
Location
Belgium
I'm working on a 8.54 Open Tibia Server using The Forgotten Server - Version 0.2.7 (Mystic Spirit).

I've been searching the OTLand threads for a solution but can't seem to find anything related to my tfs version.

So what do I want to accomplish?
I want to make it possible for a god to change his/hers outfit to any outfit in tibia. At this moment this is possible but every time I re-log the outfit will be reset to the base god outfit.

Any idea's are welcome (keep in mind that it has to work on tfs version 0.2.7).

Thanks in advance!
 
creaturescripts.xml
Code:
<event type="logout" name="PlayerLogout" script="logout.lua"/>
logout.lua
Code:
function onLogout(cid)
     if getPlayerAccess(cid) == 1 then
         setPlayerStorageValue(cid, 91000, getCreatureOutfit(cid).lookType)
     end
     return TRUE
end
Add this to login.lua (under function onLogin)
Code:
  if getPlayerAccess(cid) == 1 then
       if getPlayerStorageValue(cid, 91000) > 1 then
           local outfit = getCreatureOutfit(cid)
           outfit.lookType = getPlayerStorageValue(cid, 91000)
           doCreatureChangeOutfit(cid, outfit)
       end
   end
 

Similar threads

Replies
1
Views
379
Back
Top