Raptor007 / aq2-tng

Action Quake 2: The Next Generation. Raptor007's sandbox for testing changes. When verified stable, this code is pushed to the official aq2-tng repo:
https://github.com/aq2-tng/aq2-tng/tree/bots
4 stars 2 forks source link

add a cvar to change maplist via rcon #51

Open m4son opened 7 years ago

m4son commented 7 years ago

Add an option to override maplist.ini rotation with something like g_maplist or sv_maplist "urban urban2 etc"

Raptor007 commented 7 years ago

@m4son Now that you guys have access to Peli again, is this still an important feature? It could be done but it's a little messy to untangle all the code assumptions that the map list is in a file, and I think maplistname is a better way for server admins to manage multiple map lists.

m4son commented 7 years ago

Well it is not just about Peli. There is a second option to make a q2admin lua script for this. But then it would be nice to have a cvar to enable/disable automatic map switch at the end of the match.

Raptor007 commented 4 years ago

I think adding 32 to dmflags should disable automatic map switch:

https://github.com/Raptor007/aq2-tng/blob/745bf3fc43f55879e6f03c39b85c9a5bf8916c17/source/q_shared.h#L1262

https://github.com/Raptor007/aq2-tng/blob/745bf3fc43f55879e6f03c39b85c9a5bf8916c17/source/g_main.c#L683-L689

m4son commented 4 years ago

Yea that works but it looks ugly since it says "Next map in the rotation is ." and then it restarts the map.
There must be a cleaner way ;) I don't think we need map restart there, just reset scores and drop clients to spectators... where they can pick a team and weapon again... What do you think?