Author Topic: Getting client info  (Read 1313 times)

0 Members and 1 Guest are viewing this topic.

Offline djoverspin

  • Newbie
  • *
  • Posts: 1
  • Karma: 0
Getting client info
« on: July 07, 2017, 10:35:59 AM »
I got a good question. I'm trying to edit the welcome window on my server to where you can check out the rules and what not on the server, but want to also have a donation link in there. but the thing I'm stuck on is getting the client info. I don't know the code I use to retrieve the username of the player on the website.

Here's an example I'm trying to get. The link will be "welcome.php?user=playername" and on the site, it'll say "Welcome playername to my server. I hope you have fun."

Can someone help me on getting the player name so I can set up my server right?

Thanks.

Offline JamminR

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 8096
  • Karma: 390
  • Sertafide Ulysses Jenius
    • Team Ulysses [ULib/ULX, other fine releases]
Re: Getting client info
« Reply #1 on: July 07, 2017, 03:07:22 PM »
ULX doesn't do this by default. You'd have to make your own MOTD system and disable ULX's.
Curruntly, we only have %curmap% and %steamid%
With your server's PHP, there may be ways to convert steamid to a username web-server side if you also have a Steam API key.
See discussion https://forums.ulyssesmod.net/index.php/topic,7102.msg35723.html#msg35723
"Though a program be but three lines long, someday it will have to be maintained." -- The Tao of Programming