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

Request: Npc that spawns monsters when first talked to.

Xikini

I whore myself out for likes
Senator
Joined
Nov 17, 2010
Messages
6,827
Solutions
586
Reaction score
5,409
Code:
The Forgotten Server, version 0.3.7_SVN (Crying Damson)
To make this short and simple, I need an NPC that when talked to the first time will spawn monsters around it in available squares, about 7 by 7 (48 available spaces to spawn, randomly each time) with about 10 monsters spawning.
The NPC should unfocus from players and say something such as 'Help intruder!'.
To help the NPC will be situated in an area with no monsters, so if a player has a battle sign the NPC will not talk to the player.

After talking with the npc for the first time the npc will act normally forever after, with the exception of not talking to players with a battle sign, simply saying 'Wash off the blood of your battles before talking to me'.

Below is some text to help guide the npc's direction.
Below that is a basic layout of a npc template I generally use.

I hope you have fun making the npc! I most definitely welcome everyone to give it a try!
And of course, a big thank you in advance for anyone willing to fill this request!

Code:
(wb) = with battle sign
(f)  = first time talking to npc

(wb) (f) Player: hi | NPC: Wash off the blood of your battles before talking to me. (unfocus)

     (f) Player: hi | NPC: Help, intruder! (in local chat) (unfocus) (spawn 10 unique monsters) | Rat,Troll,Minotaur, etc.

(wb)     Player: hi | NPC: Wash off the blood of your battles before talking to me. (unfocus)

         Player: hi | NPC: Well my battle heartened friend, what can I do for you?
Code:
local keywordHandler = KeywordHandler:new()
local npcHandler = NpcHandler:new(keywordHandler)
NpcSystem.parseParameters(npcHandler)
local talkState = {}

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

function creatureSayCallback(cid, type, msg)
  if(not npcHandler:isFocused(cid)) then
  return false
  end

local talkUser = NPCHANDLER_CONVBEHAVIOR == CONVERSATION_DEFAULT and 0 or cid





   return true
end

npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback)
npcHandler:addModule(FocusModule:new())
 
I have no clue about coding and scripting but couldnt you just take the orc kings or the Minotaur kings File and modify it the way you want it to be?
 
I have no clue about coding and scripting but couldnt you just take the orc kings or the Minotaur kings File and modify it the way you want it to be?
That is what I'm definitely looking for, however I looked and couldn't find them anywhere. So made this forum post hoping for some help in creating the base of those npc's. :/
 
That is what I'm definitely looking for, however I looked and couldn't find them anywhere. So made this forum post hoping for some help in creating the base of those npc's. :/
oh =/ well i hope you can find a solution, but arent there all the npc files from the real tibia somewhere? i mean, some rl map ots have them aswell ;o
 
oh =/ well i hope you can find a solution, but arent there all the npc files from the real tibia somewhere? i mean, some rl map ots have them aswell ;o
After you mentioned the orc king (I only remembered the mino king in mintwallin) I looked around but the npc files are all for old distro's back in 2010. I tried it quickly but got error's. Our distro just isn't compatible with the older functions.
So hopefully someone will help out and make the starting of this npc for fun. :) I'm attempting to make it as well, but who knows how long it will be. :p
 
Back
Top