Inside3D!
     

Centerprint logging issue

 
Post new topic   Reply to topic    Inside3d Forums Forum Index -> Engine Programming
View previous topic :: View next topic  
Author Message
mh



Joined: 12 Jan 2008
Posts: 909

PostPosted: Tue Jun 30, 2009 9:59 pm    Post subject: Centerprint logging issue Reply with quote

Anyone come across this one? There are a number of mods out there which use persistent centerprints for displaying menus and stats in-game. In an engine with centerprint logging, we get the console basically flooded, rendering it pretty useless.

So is there a solution? In an ideal world these mods would be rewritten to use CSQC which every engine would have support for, but I'm afraid we're going to have to accept second best. Do we remove centerprint logging, or do we accept the console spamming, or is there a third option that can detect when centerprints are used in this manner and adjust accordingly?
_________________
DirectQ Engine - New release 1.8.666a, 9th August 2010
MHQuake Blog (General)
Direct3D 8 Quake Engines
Back to top
View user's profile Send private message Visit poster's website
ceriux



Joined: 06 Sep 2008
Posts: 968
Location: Florida, USA

PostPosted: Tue Jun 30, 2009 10:03 pm    Post subject: Reply with quote

couldnt you just make a new print type and have that not be logged? maybe rprint? (prints on the top right?) maybe one for each corner of the screen lol?
_________________
QuakeDB - Quake ModDB Group
Back to top
View user's profile Send private message Yahoo Messenger
Spike



Joined: 05 Nov 2004
Posts: 944
Location: UK

PostPosted: Tue Jun 30, 2009 10:21 pm    Post subject: Reply with quote

mods like TF have a lot of leading new lines in order to align the centerprint with the statusbar.
mods like CustomTF will tend to use [1] or 1. or something to show the user which keys bind to which option.
mods like runequake which just shove the text in the middle of the screen regardless won't change text very often (don't print if its the same as the last print that was printed), but you probably do want it logged, in this case.

Alternatively, if the string is present in the ent file, log it.

At the end of the day, there's nothing really that you can do that is fully reliable.

Either way, you'll get the console spammed with messages simply by standing in a trigger_multiple on the start map. Albeit more slowly.

ceriux: the problem is that existing mods both spam centerprints for menus and certain events like pressing buttons.
_________________
What's a signature?
Back to top
View user's profile Send private message Visit poster's website
metlslime



Joined: 05 Feb 2008
Posts: 177

PostPosted: Tue Jun 30, 2009 10:50 pm    Post subject: Reply with quote

Fitzquake does two things to help mitigate this:

- by default it only happens in single player, but you can enable it for multiplayer too (since multiplayer mods are the main culprits)

- if the new string is identical to the previous string, it's not logged.

The idea of checking to see if the string is in the bsp or progs is an interesting one. What are the drawbacks to this? Are there any code-generated strings that we ought to be logging that would be missed by this?
Back to top
View user's profile Send private message
mh



Joined: 12 Jan 2008
Posts: 909

PostPosted: Tue Jun 30, 2009 11:01 pm    Post subject: Reply with quote

@Spike - that's it exactly, there's no point in a solution that doesn't take existing mods into account.

Anyway, I think I have a fix, which is to only log a centerprint if the previous one has already been cleared (i.e. scr_centertime_off is less than something like 0.01) - I can see it breaking where two different centerprints in quick succession are intentional, so maybe use (scr_centertime.value - 0.1) instead would be better?
_________________
DirectQ Engine - New release 1.8.666a, 9th August 2010
MHQuake Blog (General)
Direct3D 8 Quake Engines
Back to top
View user's profile Send private message Visit poster's website
r00k



Joined: 13 Nov 2004
Posts: 483

PostPosted: Wed Jul 01, 2009 5:22 am    Post subject: Reply with quote

Could use an svc sell screen and autodownload menus?
Back to top
View user's profile Send private message
Entar



Joined: 05 Nov 2004
Posts: 422
Location: At my computer

PostPosted: Wed Jul 01, 2009 5:50 am    Post subject: Reply with quote

One idea that would remove that nasty flooding and still be pretty useful would be to only log centerprints that are not the same as the last one. That way, if something shows up, it only gets logged once, and then the log reflects all that the centerprint ever said, and when it changed.
_________________
woh... feelin woozy... too much cider...
http://entar.quakedev.com
games fascination - My Game Development Blog/Journal
Back to top
View user's profile Send private message Visit poster's website AIM Address MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    Inside3d Forums Forum Index -> Engine Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2004 phpBB Group