Page 1 of 1
Access System's Username
Posted: Thu May 25, 2023 6:52 am
by cawmageddon
Hi All,
I'm making a horror wad and I think it'd be cool to break the fourth wall at one point and have a demon address the player by their real name, or at least the name of their user account in their system.
Since gzdoom is running C/C++ this should be easy to implement for windows and linux, right?
Any help is appreciated

Re: Access System's Username
Posted: Thu May 25, 2023 11:00 am
by yum13241
But that's not exposed in ZScript. Just because it's possible in C++ doesn't mean we'll get to see it in ZScript.
Re: Access System's Username
Posted: Fri May 26, 2023 12:58 am
by cawmageddon
yum13241 wrote: ↑Thu May 25, 2023 11:00 am
But that's not exposed in ZScript. Just because it's possible in C++ doesn't mean we'll get to see it in ZScript.
Oh nooooooo :{
Do you have any idea how one might go about implementing it?
Re: Access System's Username
Posted: Sat May 27, 2023 7:44 am
by yum13241
No, but you can use the player name.
Re: Access System's Username
Posted: Sun May 28, 2023 7:50 am
by cawmageddon
Hm, I want to create a sense of horror so having the demon address the player as "PLAYER1" won't really have the same impact.
Re: Access System's Username
Posted: Sun May 28, 2023 2:16 pm
by Chris
cawmageddon wrote: ↑Sun May 28, 2023 7:50 am
Hm, I want to create a sense of horror so having the demon address the player as "PLAYER1" won't really have the same impact.
Given the wide range of styles a person can set their system username with, that may not be any better. Depending on what it's set to, it may even come across as confusing, with the player not realizing it was meant to address them rather than a using a generic word or name. The system username may be better thought of as a unique (for the system) identifier or title, rather than a name you'd address someone with in conversation.
Re: Access System's Username
Posted: Mon May 29, 2023 12:39 am
by wildweasel
cawmageddon wrote: ↑Sun May 28, 2023 7:50 am
Hm, I want to create a sense of horror so having the demon address the player as "PLAYER1" won't really have the same impact.
Your mod would end up addressing me as "wildw" or "owner" which wouldn't really work either.
Re: Access System's Username
Posted: Mon May 29, 2023 2:39 am
by ramon.dexter
Yeah, another attempt on jumpscare wad, just to be completely fade away like a year later.
Re: Access System's Username
Posted: Mon May 29, 2023 11:23 pm
by cawmageddon
Chris wrote: ↑Sun May 28, 2023 2:16 pm
cawmageddon wrote: ↑Sun May 28, 2023 7:50 am
Hm, I want to create a sense of horror so having the demon address the player as "PLAYER1" won't really have the same impact.
Given the wide range of styles a person can set their system username with, that may not be any better. Depending on what it's set to, it may even come across as confusing, with the player not realizing it was meant to address them rather than a using a generic word or name. The system username may be better thought of as a unique (for the system) identifier or title, rather than a name you'd address someone with in conversation.
Hm, yeah that's a good point,.,..
Alright, well I might still play around with it and see if I can get it working as a zdoom learning exercise, but not actually use it in a map.
Thanks to everyone who replied <3
Re: Access System's Username
Posted: Tue May 30, 2023 8:08 am
by yum13241
cawmageddon wrote: ↑Sun May 28, 2023 7:50 am
Hm, I want to create a sense of horror so having the demon address the player as "PLAYER1" won't really have the same impact.
What I meant was getting the
name CVar. That is the name the player uses in game.
Re: Access System's Username
Posted: Tue May 30, 2023 7:03 pm
by cawmageddon
yum13241 wrote: ↑Tue May 30, 2023 8:08 am
cawmageddon wrote: ↑Sun May 28, 2023 7:50 am
Hm, I want to create a sense of horror so having the demon address the player as "PLAYER1" won't really have the same impact.
What I meant was getting the
name CVar. That is the name the player uses in game.
Oh, I thought you meant GetUserName() from the Player struct
Re: Access System's Username
Posted: Wed Jun 14, 2023 9:35 am
by inkoalawetrust
cawmageddon wrote: ↑Tue May 30, 2023 7:03 pm
yum13241 wrote: ↑Tue May 30, 2023 8:08 am
cawmageddon wrote: ↑Sun May 28, 2023 7:50 am
Hm, I want to create a sense of horror so having the demon address the player as "PLAYER1" won't really have the same impact.
What I meant was getting the
name CVar. That is the name the player uses in game.
Oh, I thought you meant GetUserName() from the Player struct
Yeah, that's what yum is talking about, the GetUsername() method gets the name CVAR of the player whose struct belongs to.
ramon.dexter wrote: ↑Mon May 29, 2023 2:39 am
Yeah, another attempt on jumpscare wad, just to be completely fade away like a year later.
And ? Most maps aren't unforgettable masterpieces that will be fondly remembered for years to come.
Re: Access System's Username
Posted: Wed Jun 14, 2023 5:50 pm
by cawmageddon
inkoalawetrust wrote: ↑Wed Jun 14, 2023 9:35 am
Yeah, that's what yum is talking about, the GetUsername() method gets the name CVAR of the player whose struct belongs to.
Oh, thank you !
