TFS 1.X+ Ghost mode

leeebux

Awsome
Premium User
Joined
May 18, 2009
Messages
89
Reaction score
3
Location
Sweden
Change so /Ghost isent sparkeling. No effect at all
 
OP
leeebux

leeebux

Awsome
Premium User
Joined
May 18, 2009
Messages
89
Reaction score
3
Location
Sweden
The sparkeling effect isent in the ghost code, but here
Code:
function onSay(player, words, param)
    if not player:getGroup():getAccess() then
        return true
    end

    if player:getAccountType() < ACCOUNT_TYPE_GOD then
        return false
    end

    local position = player:getPosition()
    local isGhost = not player:isInGhostMode()

    player:setGhostMode(isGhost)
    if isGhost then
        player:sendTextMessage(MESSAGE_INFO_DESCR, "You are now invisible.")
    else
        player:sendTextMessage(MESSAGE_INFO_DESCR, "You are visible again.")
        position.x = position.x + 1
    end
    return false
end
 

Yaboihunna

Member
Joined
Mar 27, 2019
Messages
59
Reaction score
1
Check in your config.lua
Ctrl f search ghost there might be a option to turn it off
 
OP
leeebux

leeebux

Awsome
Premium User
Joined
May 18, 2009
Messages
89
Reaction score
3
Location
Sweden
Nothing about it in the Config :/
 

BulawOw

Member
Joined
Sep 15, 2014
Messages
73
Reaction score
8
Add this line below player:sendTextMessage

Code:
position:sendMagicEffect(CONST_ME_MAGIC_BLUE)
 

TheGahl

Learning in Progress
Joined
Jul 28, 2018
Messages
125
Reaction score
65
The sparkeling effect isent in the ghost code, but here
Code:
function onSay(player, words, param)
    if not player:getGroup():getAccess() then
        return true
    end

    if player:getAccountType() < ACCOUNT_TYPE_GOD then
        return false
    end

    local position = player:getPosition()
    local isGhost = not player:isInGhostMode()

    player:setGhostMode(isGhost)
    if isGhost then
        player:sendTextMessage(MESSAGE_INFO_DESCR, "You are now invisible.")
    else
        player:sendTextMessage(MESSAGE_INFO_DESCR, "You are visible again.")
        position.x = position.x + 1
    end
    return false
end
If you turn invisible so people can't see you, but you don't go "utana vid", it's C++ related.
If you don't turn invisible, still C++ related, because it would mean setGhost() isn't functional as intended xD
 
OP
leeebux

leeebux

Awsome
Premium User
Joined
May 18, 2009
Messages
89
Reaction score
3
Location
Sweden
The ghost turns me invisible, but with the a sparkeling effect that i dont want.
Hmm, i guess the stalker effect on a tile
 
Top