weeztor / darkrp

Automatically exported from code.google.com/p/darkrp
0 stars 1 forks source link

RPName issues #940

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What is the bug? (It has to be a DarkRP bug, nothing else!)

After you implemented some rpname updates to fix the "no name" bug a couple 
weeks ago, a new issue arose after it was fixed. ULX & Sui scoreboard and 
pretty much anything else that pulls a darkrp name that isn't darkrp, sometimes 
manages to pull the rpname, and sometimes will just print the Steam name. (even 
though they have an rpname set.)

What steps will reproduce the problem?
I currently have not found a way to reproduce it, but it happens to many 
players on the server.

Do you have any errors? serverside or clientside? If you do, which ones? No.

Are you using the downloaded version or an SVN revision (if SVN, which
revision number)? Latest SVN.

Please provide any additional information below.

RP_Lookup outputs. (You can see both players have an rpname set, rokrox's shows 
fine, and Enthusiastic's pulls his steam name on the scoreboard and in ULX.

ULX Screenshot (Showing players steam name, when it has always showed their set 
rpname.)
http://summit-gaming.com/plynameulx.png

Sui Scoreboard Screenshot. (Showing players steam name, when it has always 
showed their set rpname.)
http://summit-gaming.com/plyname.png

] rp_lookup rokrox
Nick: rokrox
Steam ID: STEAM_0:1:3421491
Steam name: |SG| rokrox

] rp_lookup enth
Nick: Enthusiastic
Steam name: [xG] Enthusiastic
Steam ID: STEAM_0:0:34987068

https://code.google.com/p/darkrp/source/detail?r=1239

Above is the revision that fixed the chat bug and that I believe caused this 
new issue. 

Thank you.

Original issue reported on code.google.com by rok...@summit-gaming.com on 29 Aug 2012 at 11:25

GoogleCodeExporter commented 9 years ago
ULX does fine with RP names for me...

Original comment by fpeijnen...@gmail.com on 30 Aug 2012 at 4:32

GoogleCodeExporter commented 9 years ago
Yes, the majority of the time it works, but when more users begin to join in it 
happens to a large portion of them, some names will show as their rpname 
perfectly, others will load as their steam name even though they have a rpname 
set, which can be found using your rp_lookup function.

It's not a huge deal, but can get confusing when players need to be 
reprimanded. 

Original comment by rok...@summit-gaming.com on 30 Aug 2012 at 4:38

GoogleCodeExporter commented 9 years ago
hmm, please look very hard for errors.
try lua_log_sv 1 and lua_log_cl 1 to log all the errors.
it's really hard for me to fix something like this if iI have no way of 
reproducing it.

Original comment by fpeijnen...@gmail.com on 30 Aug 2012 at 5:39

GoogleCodeExporter commented 9 years ago
I'll leave the two logging variables enabled for a while and see if I catch any 
errors, but I've restarted the server quite a few times and haven't managed to 
find one. 

It looks like in the code you updated to fix the invisible name,
return self.DarkRPVars.rpname and tostring(self.DarkRPVars.rpname) or 
self:SteamName()

That sometimes the "DarkRPVars.rpname" will be pulled, and then other times it 
seems to have an issue and returns the self:SteamName(), since that's an or, 
you want me to try removing the self:SteamName() and see if it sometimes turns 
up a NULL because it can't get DarkRPVars.rpname?

(Better yet, I'll just add some debug prints after that line and see if 
anything fishy comes up, sorry for the lack of evidence.).

Original comment by rok...@summit-gaming.com on 30 Aug 2012 at 9:12

GoogleCodeExporter commented 9 years ago
Okay, made some quick progress. I just removed the SteamName from this line in 
cl_init.

return self.DarkRPVars.rpname and tostring(self.DarkRPVars.rpname) or 
self:SteamName()

so it looks like this now,

return self.DarkRPVars.rpname and tostring(self.DarkRPVars.rpname)

Had a friend of mine join who had the rpname issue before, and he was getting 
this when looking at me. 

[@sui_scoreboard\player_row.lua:124] bad argument #1 to 'SetText' (string 
expected, got nil)
ERROR: GAMEMODE:'HUDPaint' Failed: [@lua\includes\modules\draw.lua:149] bad 
argument #1 to 'len' (string expected, got nil)

You can see that's returning nil for the player name, which is errors out a lot 
of other plugins that can't find a name, and since that line no longer provides 
the "SteamName," it just stops after trying to get the rpname. (Which we all 
had rpnames set when testing this.)

Also, lug_log_cl doesn't appear to exist in Gmod10. 
Unknown command "lug_log_cl"

There were no server-side errors, as the server-side is pulling the rpname 
fine, it's the client side that is getting garbled. Because I can always do 
rp_lookup and find the RPName, even if the scoreboard, ulx, and everything else 
client side is showing the SteamName.

Why the rpname is sometimes returning nil on the client-side is beyond me.

Original comment by rok...@summit-gaming.com on 30 Aug 2012 at 9:43

GoogleCodeExporter commented 9 years ago
This happens in my server also, If I notice an error I'll mention it, although 
I believe no error is fired off, must the the "or". May have something to do 
with 'DarkRPVars' returning a nil.

Original comment by core...@gmail.com on 31 Aug 2012 at 2:33

GoogleCodeExporter commented 9 years ago
The client doesn't have any rp names when they join. they all get sent 
afterwards. see if the bug does not occur when you open these menus like tree 
twenty seconds after you're in the server

Original comment by fpeijnen...@gmail.com on 31 Aug 2012 at 6:53

GoogleCodeExporter commented 9 years ago
oh and not everyone has an rp name, so it will return the steam name for them 
too

Original comment by fpeijnen...@gmail.com on 31 Aug 2012 at 6:55

GoogleCodeExporter commented 9 years ago
When people get this glitch, it seems to override everything else that isn't 
darkrp. It's permanent until they change their rpname name. (which fixes it no 
problem)

Original comment by rok...@summit-gaming.com on 31 Aug 2012 at 6:56

GoogleCodeExporter commented 9 years ago
And the people in the screenshots have rpnames set, I even had an rpname set, 
it works fine for me, but others will get this issue, and sometimes they will 
see me as my steam name, not my rpname. 

Original comment by rok...@summit-gaming.com on 31 Aug 2012 at 6:57

GoogleCodeExporter commented 9 years ago
I have no idea how to even start with this issue.

Original comment by fpeijnen...@gmail.com on 31 Aug 2012 at 1:08

GoogleCodeExporter commented 9 years ago
I found a server that has the problem. ply.DarkRPVars.rpname is nil. Now to 
find out why.

Original comment by fpeijnen...@gmail.com on 31 Aug 2012 at 9:38

GoogleCodeExporter commented 9 years ago
Some people's RP names show and some people's RP names don't. This is rather 
difficult :/

Original comment by fpeijnen...@gmail.com on 31 Aug 2012 at 9:54

GoogleCodeExporter commented 9 years ago
Maybe a character in the name is causing the called information to be 
recognized as arguments/table? I've had an issue of that sort before; with 
characters causing my return to be nil and using some prints it showed it being 
a table so I had to use gsub with certain characters, in this case it was ( and 
) not sure if this is what's going on but, worth a say.

Original comment by core...@gmail.com on 6 Sep 2012 at 9:01

GoogleCodeExporter commented 9 years ago
*used gsub before the information sent, in which was the case of my issue.

Original comment by core...@gmail.com on 6 Sep 2012 at 9:17

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Any ETC on when this will be fixed?

Original comment by christop...@gmail.com on 7 Sep 2012 at 1:27

GoogleCodeExporter commented 9 years ago
He doesn't know what's causing it, neither do you, neither does anyone else who 
has posted. That's why he's left the ticket open. It's not like he hasn't 
looked into it, he knows there's a problem.

Original comment by rok...@summit-gaming.com on 7 Sep 2012 at 1:35

GoogleCodeExporter commented 9 years ago
Finally found the god damn cause

Original comment by fpeijnen...@gmail.com on 9 Sep 2012 at 3:37

GoogleCodeExporter commented 9 years ago
Thank you for the update, it looks like some debug print was left in the file. 
(Just a heads up)

Timer Error: [gamemodes\darkrp\gamemode\server\player.lua:210] attempt to call g
lobal 'fprint' (a nil value)

Original comment by rok...@summit-gaming.com on 10 Sep 2012 at 4:55

GoogleCodeExporter commented 9 years ago
Remove that line for now, will fix asap

Original comment by fpeijnen...@gmail.com on 10 Sep 2012 at 4:58

GoogleCodeExporter commented 9 years ago
ERROR: GAMEMODE:'HUDPaint' Failed: [darkrp\gamemode\client\hud.lua:50] attempt 
to compare number with string

After the latest update.

Original comment by rok...@summit-gaming.com on 12 Sep 2012 at 2:22

GoogleCodeExporter commented 9 years ago
Tried the fix and still having this issue :s

Original comment by mckenzie...@gmail.com on 10 Nov 2012 at 9:59

GoogleCodeExporter commented 9 years ago
Probably because you're not updated to the latest version. Darkrp moved to 
github.

https://github.com/FPtje/DarkRP

Original comment by rokro...@gmail.com on 10 Nov 2012 at 10:11