Issue information

Issue ID
#5204
Status
Confirmed
Severity
Low
Started
Hercules Elf Bot
Jan 5, 2012 13:03
Last Post
Hercules Elf Bot
Jan 9, 2012 23:23
Confirmation
Yes (1)
No (0)

Hercules Elf Bot - Jan 5, 2012 13:03

Originally posted by [b]Gepard[/b]
The ability to change battle configuration settings on the fly (either by [i]@reloadbattlecon[/i]f command or [i]setbattleflag [/i]script command) is currently flawed.

Some of the configs, despite of being changed during runtime, will not be in effect due to the way they are handled internally. These include:[list]
[*]mob_count_rate (changing it at runtime will not change amount of monsters from spawnsets already processed)
[*][s]boss_delay_spawn, plant_delay_spawn, mob_delay_spawn (just like above)[/s] fixed in [rev=15416]
[/list]
and possibly more (need to find them all).

The solution is to change behaviour, so whenever possible, server would always read the current value of battle_config struct members.

[s]I'll commit a fix for *delay_spawn soon[/s] [size=2]done[/size]. Mob_count_rate, however, is a bit problematic. In my server, I've used the following solution:
[quote]
mob_count_rate is being applied the moment monsters are being spawned on the map (only in conjunction with dynamic_mobs) instead at script parsing.
When mob_count_rate is increased, on all maps that have mobs not removed (due to dynamic_mobs), additional monsters are being spawned. On empty maps, a new amount mobs will spawn as usual when players enters them.
When mob_count_rate is decreased, monsters over new spawn amount stay until they are: killed (will not respawn), or removed as usual by dynamic_mobs.
[/quote]
Opinions, suggestions on this one?

This post has been edited by Gepard on Jan 9, 2012 23:25

Hercules Elf Bot - Jan 5, 2012 16:48

Originally posted by [b]Ind[/b]
[s]I think being it's something not often changed rather than changing the behavior it could loop through spawn data upon reload and re-calculate as necessary, grab current spawn value before reload; then after reload use it against the new one to re-measure. in my opinion.[/s] whops. Gepard proved I was wrong.

This post has been edited by Ind on Jan 5, 2012 18:29

Hercules Elf Bot - Jan 9, 2012 23:23

Originally posted by [b]Gepard[/b]
*_delay_spawn fixed in [rev=15416].