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

4 script please

johny5608

johny
Joined
Oct 5, 2008
Messages
120
Reaction score
0
Location
Wien
Hello,
I'm looking for Scripter which these scripts will do me!
This communication is successful ago dam: REP, + GOD on my OTS!

INFO:
Engine: The Forgotten Server
Client: 8.41
Verion: GUI 0.3.3

1. The script on the vessel including the [Boat] (eg as in the Carlin!) Which sail after 1 minute and comes back in 10.
The vessel must not only swim even they disappeared
Specifically:
Ship after 1 min suddenly disappears, and after 10 min again comed the Ship back with a npc on it!

2. [Moveevents] There are a tile and next to the tile stand a NPC if the player does't have a ticket and stand on tile then NPC says: Sorry, But i don't have the Ticket!
If a Player hae ticket then he
goes further!

3. [NPC] Name: Ticket Seller
Description: The player buys a ticket form him!

4. [ticket] (search a ticket in order to look cool)
As a player has a ticket and klick on it then he can pass through the tile (as in number 2) But! This ticket is expected to take only 5 minutes!
ticket has to be separate Destription: "Left [time] to complete the validity of the ticket"!
and as there are no longer important: "Your ticket has lost the expiry date!"
Please help and Thank you!
 
Last edited:
This is the npc-script, NOT tested and i don't remember if the function "getNpcCid()" exist.

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



-- OTServ event handling functions start
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
-- OTServ event handling functions end

local carlinPos = {x=10, y=10, z=7}
local travelMoney = 300
local time = 10 -- in minutes

function creatureSayCallback(cid, type, msg)
	if(not npcHandler:isFocused(cid)) then
		return false
	end
	local talkUser = NPCHANDLER_CONVBEHAVIOR == CONVERSATION_PRIVATE and 0 or cid
	if(msgcontains(msg, 'carlin')) then
		selfSay('Are you sure that do you want travel to Carlin for ' .. travelMoney .. ' gold coins?.', cid)
		talkState[talkUser] = 1
	elseif(msgcontains(msg, 'yes') and talkState[talkUser] == 1) then
		if(doPlayerRemoveMoney(cid, travelMoney) == TRUE) then
			doTeleportThing(cid, carlinPos)
			selfSay('Set the sails.!', cid)
			doRemoveCreature(getNpcCid())
			addEvent(createNpc, (time*60))
		else
			selfSay('Sorry, you do not have enough money.!', cid)
		end
	end
end

function createNpc()
local npcName = Captain Niptor
local npcPos = {x=10, y=10, z=7}
	doCreateNpc(npcName, npcPos)
end



-- Makes sure the npc reacts when you say hi, bye etc.
npcHandler:addModule(FocusModule:new())
 
Thx! but i have a problem:

[23/04/2009 18:49:02] [Warning - NpcScript::NpcScript] Can not load script: data/npc/scripts/test.lua
[23/04/2009 18:49:02] data/npc/scripts/tickets.lua:40: '=' expected near 'local'

yet only been: Moveevetns, Npc Ticket Seller, Boat Script ,...
 
Back
Top