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

[Vip Effect] small problem

tsb0314

New Member
Joined
Oct 21, 2009
Messages
220
Reaction score
4
well i just got the vip effect but whenever one of my staff goes ghost. it still blinks up "vip" and when it pops up it is blue and i would like it to be red here is my script if someone could please fix it for me. and if you dont already know by looking at the script i cqnt remove days because i never actually added days so i dont know how to get the vip pop up off my ghost gods
thanks


function onThink(interval, lastExecution)
for _, name in ipairs(getOnlinePlayers()) do
local cid = getPlayerByName(name)
if getPlayerStorageValue(cid, 11551) >= 1 then
doSendMagicEffect(getPlayerPosition(cid), 27)
doSendAnimatedText(getPlayerPosition(cid), "V.I.P.!", 23)
end
end
return true
end
 
Last edited:
this should work, but its a bad way to do it, it'll lag alot

LUA:
function onThink(interval, lastExecution)
	for _, name in ipairs(getOnlinePlayers()) do
		local cid = getPlayerByName(name)
		if getPlayerStorageValue(cid, 11551) >= 1 and not getPlayerGhostAccess(cid) then
			doSendMagicEffect(getPlayerPosition(cid), 27)
			doSendAnimatedText(getPlayerPosition(cid), "V.I.P.!", 180)
		end
	end
	return true
end
 
Last edited:
why doesn't it work? Does it give an error or it doesn't do what its supposed?
what TFS version you have?

Try to give us all the information you can, just saying it doesn't work doesn't help us help you
 
ok well i am working with tfs 0.3 6 and when i did your script (@up) i didnt have any error or effect it was like the script was never there
 
there isn't any function to return true when you are invisible, so either make one in sources, or just disable the effects for GMs by using getPlayerAccess(cid) >= 3 or w/e your access level is :)

Replace the "not getPlayerGhostAccess(cid)" with "getPlayerAccess(cid) >= 3"
 
Back
Top