Forum

> > CS2D > Scripts > [Tibia]Monster respawn
ForenübersichtCS2D-Übersicht Scripts-ÜbersichtEinloggen, um zu antworten

Englisch [Tibia]Monster respawn

10 Antworten
Zum Anfang Vorherige 1 Nächste Zum Anfang

alt Re: [Tibia]Monster respawn

Ashley
BANNED Off Offline

Zitieren
Lua Does not have ms10000000000

Time Hooks :

Ms100
Second
Minute
and i think some others


You Should use one of them for your Tibia

alt Re: [Tibia]Monster respawn

Yates
Reviewer Off Offline

Zitieren
Go to monsters.lua, copy/paste the for loop that loops through the monster table. Then use the monster:die () function (make sure to add the monster id parameter in the function) and kill it. I think the monster may drop items and money but I'm not sure.

If you need any help with the tibia script I've done almost everything you can think of so PM me any time. I won't be able to script for a few hours now as I'm off to work.

alt Re: [Tibia]Monster respawn

NeverLast
User Off Offline

Zitieren
I would like the monster every 30 minutes to die.^

This?
1
2
3
4
5
6
7
8
9
10
11
12
13
if self.health <= 0 then
		if not PLAYERS[id].Tutorial.killm then
			message(id, "Congratulation! You have killed your first monster. You can proceed to pick up the loot by using the drop weapon button (default G)", "255000000")
			PLAYERS[id].Tutorial.killm = true
		end
		addexp(id, math.floor(self.exp*CONFIG.EXPRATE))
		self:die()
	else
		parse('effect "colorsmoke" ' .. self.x .. ' ' .. self.y .. ' 0 ' .. self.scaley .. ' ' .. (self.r and (self.r .. ' ' .. self.g .. ' ' .. self.b) or '192 0 0'))
	end
	radiussound("weapons/machete_hit.wav", self.x, self.y)
	return true
end
1× editiert, zuletzt 09.03.14 21:25:14

alt Re: [Tibia]Monster respawn

yuncemm
User Off Offline

Zitieren
all monster delete
no have 100000ms
Notice >
Mehr >

alt Re: [Tibia]Monster respawn

Yates
Reviewer Off Offline

Zitieren
1
2
3
4
5
6
7
8
9
10
11
yourshitmonsterkillonminutevariable = 0

function yourshitminutehooktokillsomeshitmonsters()
	yourshitmonsterkillonminutevariable = yourshitmonsterkillonminutevariable + 1
	if yourshitmonsterkillonminutevariable == 30 then
		for _, everyshitassmonsteryouwanttokill in ipairs(MONSTERS) do
			everyshitassmonsteryouwanttokill:destroy()
		end
	end
end
addhook("minute","yourshitminutehooktokillsomeshitmonsters")

Paste into hooks.lua

[monsterID]:destroy() removes the monster, [monsterID]:kill() drops items and shit.

alt Re: [Tibia]Monster respawn

NeverLast
User Off Offline

Zitieren
This works to 50%
1
2
3
4
5
6
7
8
9
10
11
12
13
yourshitmonsterkillonminutevariable = 0

function yourshitminutehooktokillsomeshitmonsters()
     yourshitmonsterkillonminutevariable = yourshitmonsterkillonminutevariable + 1
     if yourshitmonsterkillonminutevariable == 1 then
          for _, everyshitassmonsteryouwanttokill in ipairs(MONSTERS) do
               everyshitassmonsteryouwanttokill:destroy()
			   		msg("©255000000Monster Reseted!")
					yourshitmonsterkillonminutevariable = 0
          end
     end
end
addhook("minute","yourshitminutehooktokillsomeshitmonsters")
No all monster will destroy

alt Re: [Tibia]Monster respawn

Yates
Reviewer Off Offline

Zitieren
I tested it. It kills all the monsters. Due to the ms100 hook which spawns new monsters they respawn almost instantly.

It works. Stop complaining.
Zum Anfang Vorherige 1 Nächste Zum Anfang
Einloggen, um zu antworten Scripts-ÜbersichtCS2D-ÜbersichtForenübersicht