Jump to content
The Dark Mod Forums

sessionCommand not working?


Recommended Posts

I'm trying to use a script to dump the console to a file (rather than asking the player to run a condump command on the console).

I'm using the following syntax to do this:

    sys.sessionCommand("condump ws6_stats.txt"); // print statistics to file

The problem is that I see no evidence that the file gets written. I look in my mod folder (where condump files are usually written) and there's nothing there.

Does anyone know if I'm using the correct syntax?

I've used sessionCommand before with other console commands, w/o any problems.

Thanks.
 

Link to post
Share on other sites

The condump file are usually saved at root installation directory, not in mod directory.

Also, do you use sessionCommand during gameplay, or before/after it? It might be that does not work properly outside gameplay.

Finally, I see that there is only one slot for sessionCommand, so if two happen at same frame, one would overwrite another. Although I don't think it is the problem.

UPDATE: sessionCommand is the event of idThread, and as far as I can see, its methods are usually called as sys.methodName(...). So the syntax looks correct to me.

Link to post
Share on other sites

For my work setup, condump  files are dumped in the mod folder. Perhaps when running a released pk4 living in the darkmod/fms/mymission/ folder, the files are dumped in the root installation folder.

(Tomorrow I'll try the latter, and see if sessionCommand works properly.)

I had checked the TDM folders anyway, but no joy there, either.

I'm invoking sessionCommand during gameplay. At the moment I have a test routine invoked by a button in the game.

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...