• 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!
  • New resources must be posted under Resources tab. A discussion thread will be created automatically, you can't open threads manually anymore.

[The_Hide][RL Quest] Killing in the name of...(like rl tibia, quest log, dialogs etc)

The_Hide

Banned User
Joined
Dec 11, 2012
Messages
389
Reaction score
10
Password to all files is: seminari
Ok, first we must go to LIB and create: (btw you must edit in 22 line 'KITNO_PawAndFur_Holy_Icon_id =' and write here your itemid of Holy Icon)

KILLING_IN_THE_NAME_OF.lua

paste here:

Killing in the name of LIB by Seminari (The_Hide) - Pastebin.com

now, go to data/movements and create:

killing_in_the_name_of.lua

paste here:

Lua:
-- By Seminari (The_Hide) (Iranimes)

function onStepIn(cid, item, position, fromPosition)
	local function KITNO_lokalny_kickEvent(cid, guid_gracza, p_from_x, p_from_y, p_to_x, p_to_y, p_z, kick_pos, p_fire) 
	local m2={}
		for x=p_from_x, p_to_x do
			for y=p_from_y, p_to_y do
				local v=getTopCreature({x=x, y=y, z=p_z}).uid
				if v ~= 0 then
					if isMonster(v) then
							table.insert(m2, v)
					end
					if isPlayer(v) then
						if getPlayerGUID(v) == guid_gracza then
						doTeleportThing(cid, kick_pos, true)
						doRemoveItem(getThingfromPos(p_fire).uid, 1)
						for i=1, #m do
						doRemoveCreature(m[i])
						end
						return doCreatureSay(cid, 'You have been kicked out from boss room. (Auto kick after 10 minutes).', TALKTYPE_ORANGE_1, false, cid)
						elseif getPlayerGUID(v) ~= guid_gracza then
						return print('Task System [tasks.lua (movements)]: Inny gracz w pomieszczeniu')
						else
						return print('Task System [tasks.lua (movements)]: Error w kick event')
						end	
					end
				end
			end
		end
	end 
	
	
	local k = KITNO_BOSS_MOVEMENTS_TBL[item.uid]
	if k then
		if (not(isPlayer(cid))) then
			doSendMagicEffect(position, CONST_ME_TELEPORT)
			KITNO_TeleportThing(cid, fromPosition, 0)
			doSendMagicEffect(fromPosition, CONST_ME_TELEPORT)
			return true
		end
		if k.typ_tasku == "paw_and_fur" then
			local tabliczka = KITNO_Paw_and_Fur_tasks_tbl[k.task_name].bossek_tbl
			-- wychodzenie z roomu
			if k.wejscie_czy_wyjscie == "wyjscie" then
				doSendMagicEffect(position, CONST_ME_TELEPORT)
				KITNO_TeleportThing(cid, tabliczka.pozycja_wyrzucenia, 0)
				doSendMagicEffect(tabliczka.pozycja_wyrzucenia, CONST_ME_TELEPORT)
				if KITNO_getPlayerSTGValue(cid, KITNO_Paw_and_Fur_tasks_tbl[k.task_name].task_started_stg) ~= 3 then
					KITNO_setPlayerSTGValue(cid, KITNO_Paw_and_Fur_tasks_tbl[k.task_name].task_started_stg, -1)
					KITNO_send_player_white_text(cid, "You run out from the room. You won't kill boss now! Task is automatly canceled.")
				end
				stopEvent(KITNO_lokalny_pauseKick)
				return true
			-- wchodzenie do roomu
			elseif k.wejscie_czy_wyjscie == "wejscie" then
				if KITNO_getPlayerSTGValue(cid, KITNO_Paw_and_Fur_tasks_tbl[k.task_name].task_started_stg) ~= 2 then
					doSendMagicEffect(position, CONST_ME_TELEPORT)
					KITNO_TeleportThing(cid, fromPosition, 0)
					doSendMagicEffect(fromPosition, CONST_ME_TELEPORT)
					KITNO_send_player_white_text(cid, "You haven't got acces to get there.")
					return true
				elseif KITNO_getPlayerSTGValue(cid, KITNO_Paw_and_Fur_tasks_tbl[k.task_name].task_started_stg) == 2 then
					local m={}
						for x=tabliczka.from.x, tabliczka.to.x do
							for y=tabliczka.from.y, tabliczka.to.y do
							local v=getTopCreature({x=x, y=y, z=tabliczka.from.z}).uid
								if v ~= 0 then
									if isPlayer(v) then
										KITNO_TeleportThing(cid, fromPosition, 0)
										KITNO_send_player_white_text(cid, "Someone else is in the room.")
										return
									elseif isMonster(v) then
										table.insert(m, v)
									end
								end
							end
						end
					for i=1, #m do
						doRemoveCreature(m[i])
					end
					if getThingfromPos(tabliczka.ogien_pos).itemid == KITNO_BOSS_MOVEMENTS_CONFIG.special_fire_field_start_id then
						doRemoveItem(getThingfromPos(tabliczka.ogien_pos).uid, 1)
					end	
					doTeleportThing(cid, tabliczka.tp)
					doSendMagicEffect(position, CONST_ME_TELEPORT)
					doSendMagicEffect(tabliczka.tp, CONST_ME_TELEPORT)
					doCreateMonster(tabliczka.boss_name, tabliczka.spawn)
					doSendMagicEffect(tabliczka.spawn, CONST_ME_TELEPORT)
					doCreateItem(KITNO_BOSS_MOVEMENTS_CONFIG.special_fire_field_start_id, 1, tabliczka.ogien_pos)
					p_from_x = tabliczka.from.x
					p_from_y = tabliczka.from.y
					p_to_x = tabliczka.to.x
					p_to_y = tabliczka.to.y
					p_z = tabliczka.from.z
					kick_pos = tabliczka.pozycja_wyrzucenia
					p_fire = tabliczka.ogien_pos
					guid_gracza = getPlayerGUID(cid)
					
					KITNO_lokalny_pauseKick = addEvent(KITNO_lokalny_kickEvent, KITNO_BOSS_MOVEMENTS_CONFIG.czas * 1000, cid, guid_gracza, p_from_x, p_from_y, p_to_x, p_to_y, p_z, kick_pos, p_fire) 
					
					if KITNO_BOSS_MOVEMENTS_CONFIG.czas >= (1*60) then
						ile = KITNO_BOSS_MOVEMENTS_CONFIG.czas / 60
						minu = 'minutes'	
					elseif KITNO_BOSS_MOVEMENTS_CONFIG.czas < (1*60) then
						ile = KITNO_BOSS_MOVEMENTS_CONFIG.czas
						minu = 'seconds'
					end
					
					doCreatureSay(cid, 'You have ' .. ile ..' ' .. minu .. ' to kill and loot this boss, else you will lose that chance and will be kicked out.', TALKTYPE_ORANGE_1, false, cid)
					return
				end
			end
		end
	end	
	return true
end


now, go to data/npsc/scripts/Grizzly Adams.lua

paste here:
Lua:
 Grizzly Adams by Seminari (The_Hide) - Pastebin.com[/url]


now go to data/creaturescripts/scripts and create:

killing_in_the_name_of.lua

and paste:

[code=lua]

function onKill(cid, target, lastHit)
	if(isPlayer(target) == true) then
        return true
    end
	if(isSummon(target) == true) then
        return true
    end
	local monsterek = KITNO_Monster_Killing_Counter_TBL[getCreatureName(target):lower()]
        if monsterek then
			if monsterek.typ_tasku == "paw_and_fur" then
				if KITNO_getPlayerSTGValue(cid, KITNO_Paw_and_Fur_tasks_tbl[monsterek.task_name].task_started_stg) >= 1 then
					if KITNO_getPlayerSTGValue(cid, KITNO_Paw_and_Fur_tasks_tbl[monsterek.task_name].task_counter_stg) < KITNO_Paw_and_Fur_tasks_tbl[monsterek.task_name].task_required_kills then
						KITNO_setPlayerSTGValue(cid, KITNO_Paw_and_Fur_tasks_tbl[monsterek.task_name].task_counter_stg, KITNO_getPlayerSTGValue(cid, KITNO_Paw_and_Fur_tasks_tbl[monsterek.task_name].task_counter_stg) + 1)
					end
				end
			elseif monsterek.typ_tasku == "boss_paw_and_fur" then
				if KITNO_getPlayerSTGValue(cid, KITNO_Paw_and_Fur_tasks_tbl[monsterek.task_name].task_started_stg) == 2 then
					KITNO_setPlayerSTGValue(cid, KITNO_Paw_and_Fur_tasks_tbl[monsterek.task_name].task_started_stg, 3)
					if KITNO_getPlayerSTGValue(cid, KITNO_Paw_and_Fur_tasks_tbl[monsterek.task_name].bossek_tbl.killed_bosses_counter_stg) < 0 then
						KITNO_setPlayerSTGValue(cid, KITNO_Paw_and_Fur_tasks_tbl[monsterek.task_name].bossek_tbl.killed_bosses_counter_stg, 0)
					end
					KITNO_setPlayerSTGValue(cid, KITNO_Paw_and_Fur_tasks_tbl[monsterek.task_name].bossek_tbl.killed_bosses_counter_stg, KITNO_getPlayerSTGValue(cid, KITNO_Paw_and_Fur_tasks_tbl[monsterek.task_name].bossek_tbl.killed_bosses_counter_stg) + 1)
					if KITNO_Paw_and_Fur_tasks_tbl[monsterek.task_name].bossek_tbl.achievement_name ~= nil then
						KITNO_addPlayerAchievement(cid, KITNO_Paw_and_Fur_tasks_tbl[monsterek.task_name].bossek_tbl.achievement_name)
					end
					KITNO_send_player_white_text(cid, "You killed ".. getCreatureName(target) .." boss of ".. monsterek.task_name .." report back to Grizzly Adams.")
				end
			end
		end	
	return true	
end



:)

What do you think about that? ;]

-----
Update!

How to generate your own quest log? Just use this talkaction and u will see your quest log in logs/quests.txt

Lua:
function onSay(cid, words, param, channel)	
	local calosc = "Quest log to tasks by Seminari(The_Hide)(Iranimes)"
	for k,v in pairs(KITNO_Paw_and_Fur_tasks_tbl) do
		if k then
		task_name = k
		task_storage = v.task_started_stg
		counter_storage = v.task_counter_stg
		required_kills = v.task_required_kills
		if v.boss then
			boss_name = v.bossek_tbl.boss_name
		else 
			boss_name = 0
		end
		first_line = '<mission name="Paw and Fur - '.. task_name ..'" storageid="'.. task_storage ..'" startvalue="1" endvalue="2">'
		second_line = '\t <missionstate id="0" description="You already hunted |STORAGE:'.. counter_storage ..'|/'.. required_kills ..' '.. task_name ..'."/>'
		third_line = '\t <missionstate id="1" description="Report back to Grizzly Adams."/>'
		if boss_name ~= nil and boss_name ~= 0 then
			fourth_line = '\t <missionstate id="2" description="Find and kill '.. boss_name ..'"/>'
			fifth_line = '\t <missionstate id="3" description="Report back your task to Grizzly Adams."/>'
		end
		last_line = '</mission>'
		if fourth_line ~= nil and fifth_line ~= nil then
			calosc = ''.. first_line ..'\n'.. second_line ..'\n'.. third_line ..'\n'.. fourth_line ..'\n'.. fifth_line ..'\n'.. last_line ..'\n'
		else
			calosc = ''.. first_line ..'\n'.. second_line ..'\n'.. third_line ..'\n'.. last_line ..'\n'
		end
		f = assert(io.open("./data/logs/quests.txt", "a+"))
		f = io.open("./data/logs/quests.txt", "a+")
		f:write("\n"..calosc .."")
		f:close()
		end
	end
	return true
end
 
Last edited:
in
Podaj hasło:

u must write
seminari

Sorry for that i will change links to lua code, sec.

- - - Updated - - -

Ok i changed links to Pastebin.
 
I had to make some changes and add in quest log but this very good thanks!! a question, you know how to put the arrays automatically reset to 20h npc "Commander Stone" special task? Just missing this for min leaves the script 100%.
 
I had to make some changes and add in quest log but this very good thanks!! a question, you know how to put the arrays automatically reset to 20h npc "Commander Stone" special task? Just missing this for min leaves the script 100%.

why u asking me about my gnomebase script in thread with my killing in the name of script?XD
reputation tasks in gnomebase, you can config delay in LIB
 
20:15 Grizzly Adams: Sorry, but in table there is no lvl on which u are (8) <-- this lvl isn't in task table.

There's some error, this is the table
KITNO_Paw_and_Fur_tasks_for_lvl = {
[{lvl_min = 1, lvl_max = 49}] = {talk_to_take_task = 101, tasks = {"crocodiles", "badgers", "tarantulas", "carniphilas", "stone golems", "mammoths", "gnarlhounds", "terramites", "apes", "thornback tortoises", "gargoyles"}},
[{lvl_min = 50, lvl_max = 79}] = {talk_to_take_task = 102, tasks = {"ice golems", "quara scouts", "mutated rats", "ancient scarabs", "wyverns", "lancer beetles", "wailing widows", "killer caimans", "bonebeasts", "crystal spiders", "mutated tigers"}},
[{lvl_min = 80, lvl_max = 129}] = {talk_to_take_task = 103, tasks = {"underwater quaras", "giant spiders", "werewolves", "nightmares", "hellspawns", "high class lizards", "stampors", "brimstone bugs", "mutated bats"}},
[{lvl_min = 130, lvl_max = 9999}] = {talk_to_take_task = 104, tasks = {"hydras", "serpent spawns", "medusae", "behemoths", "sea serpents", "hellhounds", "ghastly dragons", "drakens", "destroyers", "undead dragons"}},
}

But it's only possible to get tasks after level 80, which is underwater quaras, gs, and stuff, help please Hide!
Testing in another character I could get the first set of tasks, but not the level 50 and so on...please help !
Using OTX Chronodia
 
Last edited:
lol u can generate it self by using simple talkaction xD
w8 i'll create it

- - - Updated - - -

paste it as talkaction, and use in game, after that it should create quest log in logs/quests.txt

Lua:
function onSay(cid, words, param, channel)	
	local calosc = "Quest log to tasks by Seminari(The_Hide)(Iranimes)"
	for k,v in pairs(KITNO_Paw_and_Fur_tasks_tbl) do
		if k then
		task_name = k
		task_storage = v.task_started_stg
		counter_storage = v.task_counter_stg
		required_kills = v.task_required_kills
		if v.boss then
			boss_name = v.bossek_tbl.boss_name
		else 
			boss_name = 0
		end
		first_line = '<mission name="Paw and Fur - '.. task_name ..'" storageid="'.. task_storage ..'" startvalue="1" endvalue="2">'
		second_line = '\t <missionstate id="0" description="You already hunted |STORAGE:'.. counter_storage ..'|/'.. required_kills ..' '.. task_name ..'."/>'
		third_line = '\t <missionstate id="1" description="Report back to Grizzly Adams."/>'
		if boss_name ~= nil and boss_name ~= 0 then
			fourth_line = '\t <missionstate id="2" description="Find and kill '.. boss_name ..'"/>'
			fifth_line = '\t <missionstate id="3" description="Report back your task to Grizzly Adams."/>'
		end
		last_line = '</mission>'
		if fourth_line ~= nil and fifth_line ~= nil then
			calosc = ''.. first_line ..'\n'.. second_line ..'\n'.. third_line ..'\n'.. fourth_line ..'\n'.. fifth_line ..'\n'.. last_line ..'\n'
		else
			calosc = ''.. first_line ..'\n'.. second_line ..'\n'.. third_line ..'\n'.. last_line ..'\n'
		end
		f = assert(io.open("./data/logs/quests.txt", "a+"))
		f = io.open("./data/logs/quests.txt", "a+")
		f:write("\n"..calosc .."")
		f:close()
		end
	end
	return true
end

- - - Updated - - -

I fixed talkaction, look at my edited post ;p
 
Last edited:
HELP PLz


[3:54:02.654] [Warning - LuaInterface::initState] Cannot load data/lib/
[3:54:02.662] [Error - LuaInterface::loadFile] data/lib/KILLING_IN_THE_NAME_OF.lua:1: unexpected symbol near 'ï'
[3:54:02.662] [Warning - LuaInterface::initState] Cannot load data/lib/
[3:54:02.670] [Error - LuaInterface::loadFile] data/lib/KILLING_IN_THE_NAME_OF.lua:1: unexpected symbol near 'ï'
[3:54:02.670] [Warning - LuaInterface::initState] Cannot load data/lib/
[3:54:02.678] [Error - LuaInterface::loadFile] data/lib/KILLING_IN_THE_NAME_OF.lua:1: unexpected symbol near 'ï'
[3:54:02.678] [Warning - LuaInterface::initState] Cannot load data/lib/
[3:54:02.686] [Error - LuaInterface::loadFile] data/lib/KILLING_IN_THE_NAME_OF.lua:1: unexpected symbol near 'ï'
[3:54:02.686] [Warning - LuaInterface::initState] Cannot load data/lib/
[3:54:02.694] [Error - LuaInterface::loadFile] data/lib/KILLING_IN_THE_NAME_OF.lua:1: unexpected symbol near 'ï'
[3:54:02.694] [Warning - LuaInterface::initState] Cannot load data/lib/
[3:54:02.702] [Error - LuaInterface::loadFile] data/lib/KILLING_IN_THE_NAME_OF.lua:1: unexpected symbol near 'ï'
[3:54:02.702] [Warning - LuaInterface::initState] Cannot load data/lib/
 
20:15 Grizzly Adams: Sorry, but in table there is no lvl on which u are (8) <-- this lvl isn't in task table.

There's some error, this is the table


But it's only possible to get tasks after level 80, which is underwater quaras, gs, and stuff, help please Hide!
Testing in another character I could get the first set of tasks, but not the level 50 and so on...please help !
Using OTX Chronodia

I have the same problem, please help.
 
Last edited:
I have the same problem, please help.

did u change something in lib or npc?

did u change something in this (in lib) :

Lua:
KITNO_Paw_and_Fur_tasks_for_lvl = {
        [{lvl_min = 1, lvl_max = 49}] = {talk_to_take_task = 101, tasks = {"crocodiles", "badgers", "tarantulas", "carniphilas", "stone golems", "mammoths", "gnarlhounds", "terramites", "apes", "thornback tortoises", "gargoyles"}},
        [{lvl_min = 50, lvl_max = 79}] = {talk_to_take_task = 102, tasks = {"ice golems", "quara scouts", "mutated rats", "ancient scarabs", "wyverns", "lancer beetles", "wailing widows", "killer caimans", "bonebeasts", "crystal spiders", "mutated tigers"}},
        [{lvl_min = 80, lvl_max = 129}] = {talk_to_take_task = 103, tasks = {"underwater quaras", "giant spiders", "werewolves", "nightmares", "hellspawns", "high class lizards", "stampors", "brimstone bugs", "mutated bats"}},
        [{lvl_min = 130, lvl_max = 9999}] = {talk_to_take_task = 104, tasks = {"hydras", "serpent spawns", "medusae", "behemoths", "sea serpents", "hellhounds", "ghastly dragons", "drakens", "destroyers", "undead dragons"}},
        }

???
 
Back
Top