Server Help

ASSS Questions - Module in a specific arena.

50% Packetloss - Sun Apr 03, 2005 4:31 am
Post subject: Module in a specific arena.
I'm wishing to have a specific module be available only in the public arenas (Public 0). I tried a few things but had no luck. I would go code-diving, but I'm lazy and figured that it would be easier to just ask the experts. A short tutorial would be excellent, I am grateful for whatever information can be provided.
Anonymous - Sun Apr 03, 2005 5:52 am
Post subject:
um....attach the module in arenas/(public) only instead of default?
D1st0rt - Sun Apr 03, 2005 9:32 am
Post subject:
arena.conf:

Code: Show/Hide
[ Modules ]
; this key holds the names of the modules that will take effect in this
; arena. typical things to put here are modules for scoring, special
; game types, flag guards, etc.
AttachModules = \
   fm_normal \
   points_kill \
   points_flag \
   points_goal

Anonymous - Sun Apr 03, 2005 9:35 am
Post subject:
I think explody meant something else....that question was easy enough for ME to answer...which is not likely with alot of questions tongue.gif
Purge - Sun Apr 03, 2005 11:26 am
Post subject:
Also, ?attmod to attach the modules to the current arena while in-game.
50% Packetloss - Sun Apr 03, 2005 4:44 pm
Post subject:
I place the module in the module.conf file and it seems to be global for all arenas, no matter what I place in the arena folders. I tried the attmod command and it seems to fail. The module is a custom one, so I specified both the dllname and the entry point (seperated by a colon).
Anonymous - Sun Apr 03, 2005 4:58 pm
Post subject:
50, mind if i take a look?

Procedure: ?cd bin, ?putfile name:name, ?cd arenas/(public), ?getfile arena.conf, edit the attach modules section, put "name \" on the list, ?putfile arena.conf, ?cd conf, ?getfile modules.conf, add it to the list, ?putfile modules.conf, and if you need to, add the commands to whichever file in the groupdef.dir directory, then hit ?shutdown -r (just to make sure), when it comes back up, do a nice ?lsmod -a, if the name is there then ?go (some other arena) and ?lsmod -a, if its there, then you have a problem, if not, then good job

make sure not to attach the module in default's arena.conf, and also...sorry for mistaking you for explody tongue.gif
50% Packetloss - Sun Apr 03, 2005 5:51 pm
Post subject:
Thanks chambahs, those help a lot. But I should have specified that the module is all ?commands (no callbacks). So even though it's only attached to one arena, the commands are able to be accessed globally throughout the zone. Is there a way to limit commands to specific arenas?

Unassociated to the above, I also got a "M <security> {scf} [50% Packetloss] map checksum mismatch" with a continuum client, not sure if that is rare or not, I wasn't doing anything out of the ordinary, (was alt-tabbed and then switched arenas and then returned to the game).
Bak - Sun Apr 03, 2005 6:12 pm
Post subject:
code the module such that it ignores commands when the player is in an arena such that the module is not attached.
Dr Brain - Sun Apr 03, 2005 7:11 pm
Post subject:
When you specify which arenas to enable the commands in, don't choose ALLARENAS. Move it out of the MM_LOAD and MM_UNLOAD and into MM_ATTACH and MM_DETACH and use the passed arena.
Anonymous - Sun Apr 03, 2005 7:18 pm
Post subject:
aww 50 is so nice, instead of saying, that didnt help at all because its not what was needed he said it nicely, lol...

anyway ....err was just about to post what bak suggested, thats what i would do....and uhh 50, you were just sitting there doing nothing and got a map checksum error?? also, was it just 1 or was it multiple errors?
Purge - Sun Apr 03, 2005 7:38 pm
Post subject:
He's most likely getting more than 1 error since checksums keep messaging until the problem is resolved.
50% Packetloss - Sun Apr 03, 2005 8:42 pm
Post subject:
Thanks brain, I figured that, but having the cmdman allocate a pointer for each arena that the module is attached to seemed a little wasteful.
Might be better if there was a ALLATTACHED define (like the ALLARENAS) that could be passed to AddCommand() so that it would search through ModuleData->attached for any command that it got. Just an idea. It would require a new module manager function that passed ModuleData* pointers, seeing how this hasn't been done already, there is probably a reason for it.

Yah, about the map checksum. I wasn't doing anything. It had nothing to do with the module I had loaded, it runs perfect and I'll probably post it here tommarow or something. I tried recreating it but didn't have any luck, so it was probably nothing.
Grelminar - Sun Apr 03, 2005 9:01 pm
Post subject:
Dr Brain's answer is correct: if you're writing a module, you have to decide whether you want it to automatically take effect everywhere, or require attaching. If you want to require attaching, you have to do your registration work in the MM_ATTACH/DETACH action, and don't use ALLARENAS. Any wasteful overhead is my problem, not yours. And really, it's insignificant.

The map checksum mismatch is a know bug, it's my fault, and it'll be fixed in the next release.
Anonymous - Mon Apr 04, 2005 9:32 am
Post subject:
which will be soon hopefully? tongue.gif
D1st0rt - Mon Apr 04, 2005 7:02 pm
Post subject:
I said put them in arena.conf, but nobody listened sa_tongue.gif
Cyan~Fire - Mon Apr 04, 2005 10:31 pm
Post subject:
It wasn't the solution to the problem, silly.
D1st0rt - Tue Apr 05, 2005 7:30 pm
Post subject:
Chamby wrote:
?getfile arena.conf, edit the attach modules section, put "name \" on the list, ?putfile arena.conf

Fiddycent Ploss wrote:
Thanks chambahs


Oh well, whatever, it was a start
Anonymous - Wed Apr 06, 2005 1:26 pm
Post subject:
D1, your just mad 50 loves me more! pfft (pushes away)
All times are -5 GMT
View topic
Powered by phpBB 2.0 .0.11 © 2001 phpBB Group