Dungeon scripten

01/05/2014 02:55 Yiv#1
Hallo liebe Community,

ich scripte derzeit ein Dungeon und, da es mein Erster ist, brauche ich eure Hilfe.

Ich bin auf der "Enter-Map" und warpe alle Spieler mit
Code:
d.new_jump_all(MAPINDEX, X, Y)
in den Dungeon.

1. Nun möchte ich, dass eine regen-File geladen wird und gewartet wird, bis alle Mobs tot sind. Wie kann ich das bewerkstelligen?
2. Wie kann ich noch einen Timer einbauen, der für alle User im aktuellen Dungeon gilt? Sprich: Wenn der abgelaufen ist, soll für jeden Spieler eine Questfunktion ausgeführt werden.

Vielen Dank für eure Hilfe! :handsdown:

MfG
01/05/2014 04:18 .Shōgun#2
I suggest you look at deviltower_zone.quest there are examples of what you ask.
01/05/2014 04:49 Yiv#3
I looked at this quest but have some problems.

What is the function of these functions?
Code:
d.new_jump_all(int map_index, int x, int y) | creating new dungeon and warp all player on map into it
d.regen_file(string path) | loading the regen file
d.set_warp_at_eliminate(?) | ?
d.check_eliminated(?) | ?
d.get_map_index() | returns the map_index of the dungeon (between map_index*10000 and (map_index+1)*10000)
d.set_unique(?) | ?
d.spawn_mob(int mob, int x, int y) | spawning mob at given position
d.setf(string flag, int i) | setting flag of dungeon
d.select(?) | ?
d.notice(string message) | gives out message for each player in dungeon
d.clear_regen(?) | ? (maybe clears regen file)
d.exit_all(?) | ? (maybe cancel dungeon - what happens to player?)
d.is_unique_dead(string unique) | check for dead of unique
d.getf(string flag) | returns value of flag
d.unique_get_hp_perc(string unique) | returns percent of hp of unique
d.purge_unique(string unique) | purges unique
d.purge(?) | ?
d.jump_all(int x, int y) | maybe jumps to position (without leaving dungeon)
d.kill_all(?) | ? (kill all what?)
All written by myself. Maybe there are missing some functions :o

Hope you can help me ...

Sorry for not so good english.

Regards
01/05/2014 04:59 .Shōgun#4
Since I don't feel like making a function guide at this hour I will answere your original questions...

d.check_eliminated()

This checks if all the mobs in the current regen are dead, if not it returns

The timer:

server_timer("mytimer", minutes, get_server_timer_arg())

when my_timer.server_timer begin
syschat("Booh!")
end
01/05/2014 05:11 Yiv#5
Quote:
Originally Posted by .Shōgun View Post
Since I don't feel like making a function guide at this hour I will answere your original questions...

d.check_eliminated()

This checks if all the mobs in the current regen are dead, if not it returns

The timer:

server_timer("mytimer", minutes, get_server_timer_arg())

when my_timer.server_timer begin
syschat("Booh!")
end
Quote:
making a function guide
This was not my intention that you do a guide. :o I just wanted to tell what I found out already.

Thank you very much!

Regards

€dit: Just one last thing: What does
Code:
d.set_warp_at_eliminate
01/05/2014 05:57 .Shōgun#6
Quote:
Originally Posted by DaJuBi View Post
This was not my intention that you do a guide. :o I just wanted to tell what I found out already.

Thank you very much!

Regards

€dit: Just one last thing: What does
Code:
d.set_warp_at_eliminate
Warps the players to a new location (and loads a regen file) when all the mobs of the current regen file are dead