• 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!
  • 2026 staff recruitment is open! Check it out and consider applying!

[Poszukuję] NPC Uzgod od obsidian knife TFS 0.3

Koci1994

Banned User
Joined
Dec 27, 2008
Messages
807
Reaction score
1
Witam poszukuję NPC Uzgod od którego na RL można zdobyć Obsidian knife. NPC musi dziłać na TFS 0.3+
Z góry Dzięki.
 
Był taki temat na otland
Prosze:
<?xml version="1.0" encoding="UTF-8"?>
<npc name="Uzgod" script="data/npc/scripts/default.lua" walkinterval="0" floorchange="0">
<health now="100" max="100"/>
<look type="134" head="116" body="114" legs="39" feet="39" addons="0" corpse="2212"/>
<parameters>
<parameter key="message_greet" value="Hiya |PLAYERNAME|! I am here for {Blessed Wooden Stake} and {Obsidian Knife}, you know! just say {trade}." />
<parameter key="module_shop" value="1"/>
<parameter key="shop_buyable" value="blessed wooden stake,5942,10000;obsidian knife,5908,5000"/>
</parameters>
</npc>
Nie wiem czy działa!
 
Chodzi o takiego żeby sie do niego pisało :
Gracz: hi
Uzgod: Hiho Player! Wanna weapon, eh?
Gracz: piece of draconian steel
Uzgod: You bringing me draconian steel and obsidian lance in exchange for obsidian knife?
Gracz: yes
Uzgod: Here you have it.
Gracz: bye
Uzgod: Guut bye. Coming back soon.
 
OMG!
ciężko napisać w lua takie coś?

piszesz żeby sprawdziło czy ma ktoś item xxxx i xxxx jesli tak to true i wymienia jeśli nie to false i wywala żebyś przyniósł itemy.
Ciężkie?
 
Prosze:
<?xml version="1.0" encoding="UTF-8"?>
<npc name="Yaman" script="data/npc/scripts/obknife.lua" walkinterval="2000" floorchange="0">
<health now="100" max="100"/>
<look type="103" head="0" body="0" legs="0" feet="0" addons="0"/>
<parameters>
<parameter key="message_greet" value="Hiho |PLAYERNAME|! Wanna weapon, eh?" />
<parameter key="message_farewell" value="Guut bye. Coming back soon." />
<parameter key="message_onsell" value="Thank you, human." />
<parameter key="message_walkaway" value="Guut bye. Coming back soon." />

</parameters>
</npc>

i....

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

-- NPC START --
function AssassinFirst(cid, message, keywords, parameters, node)

if(not npcHandler:isFocused(cid)) then
return false
end

if getPlayerItemCount(cid,5889) >= 1 then
if doPlayerRemoveItem(cid,5889,1) then
npcHandler:say('Here you have it.', cid)
doPlayerAddItem(cid,5908,1)
end
else
npcHandler:say('You don\'t have these items!', cid)
end
end

-- NPC END --

keywordHandler:addKeyword({'help'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = "I can draconian steel for obsidian knife."})

local node1 = keywordHandler:addKeyword({'piece of draconian steel'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'You bringing me draconian steel in exchange for obsidian knife? '})
node1:addChildKeyword({'yes'}, AssassinFirst, {npcHandler = npcHandler, onlyFocus = true, reset = true})
node1:addChildKeyword({'no'}, StdModule.say, {npcHandler = npcHandler, onlyFocus = true, text = 'Alright then. Come back when you got the neccessary items.', reset = true})

npcHandler:addModule(FocusModule:new())


Działa?? Jeśli tak to rep sam sie nie doda :PP
 
Last edited:
Back
Top