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

The Forgotten Server v0.2rc9 (Mystic Spirit)

Status
Not open for further replies.
Hey Talaturen... small request for you. Can you add back 'animated colors'? In 0.2.8 release, when I changed gold I see COLOURED "$$$". But in this release and in latest rev. that colors when I change gold are black ;|. Can you add this back?
 
how?:>

I think you dont know what I'm talking about, I mean that yellow $$$ or blue $$$ animated in TFS 0.2.8. In 0.2.9 are black ...
 
how?:>

I think you dont know what I'm talking about, I mean that yellow $$$ or blue $$$ animated in TFS 0.2.8. In 0.2.9 are black ...

Get crystal.lua from version 0.2.8 and replace it for that you have on 0.2.9
 
Get crystal.lua from version 0.2.8 and replace it for that you have on 0.2.9

Its not possible, because 0.2.9 got that script from 0.2.8 ...
Here is the script:

Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
	if item.itemid == ITEM_GOLD_COIN and item.type == ITEMCOUNT_MAX then
		doChangeTypeItem(item.uid, item.type - item.type)
		doPlayerAddItem(cid, ITEM_PLATINUM_COIN, 1)
		doSendAnimatedText(fromPosition, "$$$", TEXTCOLOR_PLATINUM)
	elseif item.itemid == ITEM_PLATINUM_COIN and item.type == ITEMCOUNT_MAX then
		doChangeTypeItem(item.uid, item.type - item.type)
		doPlayerAddItem(cid, ITEM_CRYSTAL_COIN, 1)
		doSendAnimatedText(fromPosition, "$$$", TEXTCOLOR_CRYSTAL)
	elseif item.itemid == ITEM_PLATINUM_COIN and item.type < ITEMCOUNT_MAX then
		doChangeTypeItem(item.uid, item.type - 1)
		doPlayerAddItem(cid, ITEM_GOLD_COIN, ITEMCOUNT_MAX)
		doSendAnimatedText(fromPosition, "$$$", TEXTCOLOR_GOLD)
	elseif item.itemid == ITEM_CRYSTAL_COIN then
		doChangeTypeItem(item.uid, item.type - 1)
		doPlayerAddItem(cid, ITEM_PLATINUM_COIN, ITEMCOUNT_MAX)
		doSendAnimatedText(fromPosition, "$$$", TEXTCOLOR_PLATINUM)
	else
		return FALSE
	end
	return TRUE
end

As you can see for ex.
doSendAnimatedText(fromPosition, "$$$", TEXTCOLOR_PLATINUM)
TEXTCOLOR_PLATINUM - But its still black. <_<
 
Last edited:
Not sure where the var is, look for it either in global.lua or actions.lua (lib), and replace it's value with the color you want ;o
 
I dont understand what are you talking about ... I got latest actions.lua and global.lua then all gonna be OK, but it doesnt. Still same text :
 
Last edited:
Where is TFS 0.3.0 ?

Isn't released yet and before 3.0 version ill be a final 2.0 version with all bugs fixed, u can wait or then report bugs from latest revision of 2.x so the developers would release it more fast
 
<_< i tryed to compile but it screws up for me all the time cant anyone just share theres?????:thumbup:


P.S i got a problem
my old npc from evo has the function "buy" but it dont exist in tfs what shud i replace it with

Code:
local keywordHandler = KeywordHandler:new()
local npcHandler = NpcHandler:new(keywordHandler)
NpcSystem.parseParameters(npcHandler)



-- OTServ event handling functions start
function onCreatureAppear(cid) npcHandler:eek:nCreatureAppear(cid) end
function onCreatureDisappear(cid) npcHandler:eek:nCreatureDisappear(cid) end
function onCreatureSay(cid, type, msg) npcHandler:eek:nCreatureSay(cid, type, msg) end
function onThink() npcHandler:eek:nThink() end
-- OTServ event handling functions end

keywordHandler:addKeyword({'offer'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'I sell fluids, 8.1 runes, wands and rods.'})

local shopModule = ShopModule:new()
npcHandler:addModule(shopModule)

shopModule:addBuyableItem({'light wand', 'lightwand'}, 2163, 500, 'magic light wand')
shopModule:addBuyableItem({'mana fluid', 'manafluid'}, 2006, 50, 7, 'mana fluid')
shopModule:addBuyableItem({'life fluid', 'lifefluid'}, 2006, 10, 10, 'life fluid')

shopModule:addBuyableItem({'heavy magic missile', 'hmm'}, 2311, 50, 10, 'heavy magic missile rune')
shopModule:addBuyableItem({'great fireball', 'gfb'}, 2304, 100, 4, 'great fireball rune')
shopModule:addBuyableItem({'explo', 'xpl'}, 2313, 120, 6, 'explosion rune')
shopModule:addBuyableItem({'ultimate healing', 'uh'}, 2273, 100, 2, 'ultimate healing rune')
shopModule:addBuyableItem({'sudden death', 'sd'}, 2268, 150, 2, 'sudden death rune')
shopModule:addBuyableItem({'blank', 'asdasasa'}, 2260, 1, 'blank rune')
shopModule:addBuyableItem({'mana', 'manarune'}, 2267, 10000, 'mana rune')
shopModule:addBuyableItem({'ice', 'icicle'}, 2275, 10000, 'icicle')
shopModule:addBuyableItem({'ava', 'avalanche'}, 2276, 10000, 'avalanche')
shopModule:addBuyableItem({'stone', 'stone Shower'}, 2288, 10000, 'stone Shower')
shopModule:addBuyableItem({'thunder', 'thunder storm'}, 2314, 10000, 'thunder storm')

shopModule:addBuyableItem({'wand of plague', 'plague'}, 2188, 2500, 'wand of plague')
shopModule:addBuyableItem({'wand of cosmic energy', 'cosmic energy'}, 2189, 5000, 'wand of cosmic energy')
shopModule:addBuyableItem({'wand of vortex', 'vortex'}, 2190, 500, 'wand of cosmic energy')
shopModule:addBuyableItem({'wand of dragonbreath', 'dragonbreath'}, 2191, 1000, 'wand of dragonbreath')

shopModule:addBuyableItem({'quagmire rod', 'quagmire'}, 2181, 2500, 'quagmire rod')
shopModule:addBuyableItem({'snakebite rod', 'snakebite'}, 2182, 500, 'snakebite rod')
shopModule:addBuyableItem({'volcanic rod', 'volcanic'}, 2185, 5000, 'volcanic rod')
shopModule:addBuyableItem({'moonlight rod', 'moonlight'}, 2186, 1000, 'moonlight rod')

npcHandler:addModule(FocusModule:new())
Code:


data/npc/lib/npcsystem/modules.lua:669: attempt to index global 'npcHandler' (a nil value)

can anyone help me fix this???? :(:(
 
Please! Use
Code:
 Tags!!

Anyway, that NPC should work with TFS to, since it's Jiddo's NPC system.
 
nope it dont work
data/npc/lib/npcsystem/modules.lua:669: attempt to index global 'npcHandler' (a nil value)

but i seem to have a soft boot npc tht works with npchandler


i have 1 problem with another npc :( which is the function "buy" what should i replace it with?
 
Code:
shopModule:addBuyableItem({'light wand', 'lightwand'}, 				2163, 500, 		'magic light wand')

I have this, and it works. So meybe, you have edited something?
 
Here's the script I use, and I know it works.
Code:
local keywordHandler = KeywordHandler:new()
local npcHandler = NpcHandler:new(keywordHandler)
NpcSystem.parseParameters(npcHandler)

function onCreatureAppear(cid)        npcHandler:onCreatureAppear(cid)        end
function onCreatureDisappear(cid)    npcHandler:onCreatureDisappear(cid)        end
function onCreatureSay(cid, type, msg)    npcHandler:onCreatureSay(cid, type, msg)    end
function onThink()            npcHandler:onThink()                end

local shopModule = ShopModule:new()
npcHandler:addModule(shopModule)

shopModule:addBuyableItem({'light wand', 'lightwand'},         2163, 500,         'magic light wand')
shopModule:addBuyableItem({'mana fluid', 'manafluid'},         2006, 55,     7,     'mana fluid')
shopModule:addBuyableItem({'life fluid', 'lifefluid'},         2006, 50,     10,    'life fluid')
shopModule:addBuyableItem({'heavy magic missile', 'hmm'},     2311, 300,     20,    'heavy magic missile rune')
shopModule:addBuyableItem({'great fireball', 'gfb'},         2304, 500,     20,     'great fireball rune')
shopModule:addBuyableItem({'explo', 'xpl'},             2313, 800,     20,     'explosion rune')
shopModule:addBuyableItem({'ultimate healing', 'uh'},         2273, 700,     20,     'ultimate healing rune')
shopModule:addBuyableItem({'sudden death', 'sd'},         2268, 1000,     20,     'sudden death rune')
shopModule:addBuyableItem({'blank', 'rune'},             2260, 10,         'blank rune')

npcHandler:addModule(FocusModule:new())

Just modify it with the rest of the things you want.
 
nope it dont work
data/npc/lib/npcsystem/modules.lua:669: attempt to index global 'npcHandler' (a nil value)

but i seem to have a soft boot npc tht works with npchandler


i have 1 problem with another npc :( which is the function "buy" what should i replace it with?

This error happens in an older version of 2.9 and it has been fixed in the latest SVN sources. It was an issue with a value in the npc system. If you compile the latest sources you should clear this issue.
 
<_< :( i tryed to compile but it doesnt happen for me does anyone release it????
 
I still need some help ? I mean that $$$ in black colour. There is no way to change this into any other colour? :>
 
Status
Not open for further replies.
Back
Top