02-17-2013 06:51 AM
Is there a way to detect which viewer an Avatar is using?
I have detected a difference in the way they react with one of my scripts and wish to accomodate them gracefully.
I therefore need to be able to detect the viewer in use within a script and respond appropriately.
02-17-2013 06:54 AM - edited 02-17-2013 08:54 AM
No, there's no way to detect a user's viewer. That functionality has been banned, in fact, from TPVs.
What's the specific difference in behaviour that you need to accommodate? There may well be a work-round.
ETA -- actually, I think there may still be a way, with http_request (what Red Zone used). But I don't know if that still works and I'm not sure I'd recommend it.
ETA2 -- I'm open to correction here, but I don't think you can reliably detect the viewer with http_request, at least not the way I'm doing it, because if you're opening webpages in your normal web browser -- IE or Firefox or Chrome or whatever, as opposed to the viewer's web browser -- that's what the script sees.
02-17-2013 09:32 AM
there is no way to detect what viewer people are using. This was introduced after there were a lot of complaints about people getting harassed for using V2 and V3 compatible viewers like Firestorm by especially people addicted to Phoenix and Singularity (and other V1 viewers).
While this went both ways no doubt, that was the main concern.
03-24-2013 04:19 AM - edited 03-24-2013 04:22 AM
Sorry for the delay in the reply b ut the problem is escalating.
I accept that there is no way to detect which viewer the user is using but is there a way to detect that they are using a standard SL viewer?
Perhaps additional info might help.
I am detecting that some users of the game I am working on are using the movement keys in a way which cheats the game and other players. I have been unable to reproduce this using the standard SL viewer but know that the"cheats" are using other viewers. The problem seems to arise when key presses are made in quick succession in a particular sequence.
03-24-2013 06:19 AM
Sorry, but you can't detect which viewer someone is using. That extends to being unable to detect if they're using the official viewer.
Would it work to place some sort of limiter on the control event, maybe using llMinEventDelay, or maybe trapping that particular sequence inside the control event?
Either that, or ask the devs on whatever viewer it is for their help. But the hard fact remains that whatever solution you find can't involve detecting viewers.
03-24-2013 07:06 AM
llMinEventDelay is used in HUDs for sporting events for exactly that reason -- to limit how quickly a football player can run on the field, for example. You have to build in other constraints so that the game won't work at all unless the player is wearing the HUD.
03-24-2013 11:25 AM
Thanks for the responses.
I am already checking that the player has not only the HUD but the latest version. It gets detached if they try to wear the wrong one.
The checks that you suggest is on the lines that I am being forced to adopt.
Am I right in thinking that the speed of successive messages from a viewer to the script control event queue are determined by both the speed of the processor being used and the lag that might be incurred in the transmission path in use?
There isn't a limiting value within the viewer?
Thanks again for responding.
03-24-2013 11:39 AM
There are no limiting values in the viewer, AFAIK. Server-side, the limit is the speed of the physics engine. If you are using llMoveToTarget, for example, the LSL wiki notes that the fastest response time you will get is 0.044444444 seconds (two physics frames, 2/45). So, even if a user's computer is capable of delivering faster impulses, and if the Internet can handle them gracefully, they will be throttled at that point. Then, as you note, sim lag will reduce the response time by some random amount. The point of using llMinEventDelay is to add another throttle to the mix so that no one will have an unfair advantage.
03-24-2013 11:53 AM
Thanks once more for the info.
I do not want to arbitrarily throttle the players by using the llMinEventDelay as the game is fast and furious but I must do something to ensure a level playing field (pun not intended).
I still don't understand how they are doing it (cheating) even after being told how to reproduce it.
I didn't want to have to install all the different viewers to see what effect I can have but I suppose needs must.