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

[Lua] getTime()

Joe Rod

Discord: joerod1
Joined
Mar 16, 2011
Messages
499
Solutions
2
Reaction score
172
GitHub
joerod1
Hi guys, i need a function who checks the hour, day and month, it would be something like this:

function getTime()
return str = "got on " ..day.. " of " ..month.. " at " ..hour..
end

Thanks in advance
Regards
 
check this example from login.lua
LUA:
	local accountManager = getPlayerAccountManager(cid)
	if(accountManager == MANAGER_NONE) then
		local lastLogin, str = getPlayerLastLoginSaved(cid), config.loginMessage
		if(lastLogin > 0) then
			doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str)
			str = "Your last visit was on " .. os.date("%a %b %d %X %Y", lastLogin) .. "."
		else
			str = str .. " Please choose your outfit."
			doPlayerSendOutfitWindow(cid)
		end

also you could check your 050-function from your lib folder.
 
Back
Top