Access System's Username
Moderator: GZDoom Developers
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.
Please bear in mind that the people helping you do not automatically know how much you know. You may be asked to upload your project file to look at. Don't be afraid to ask questions about what things mean, but also please be patient with the people trying to help you. (And helpers, please be patient with the person you're trying to help!)
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.
Please bear in mind that the people helping you do not automatically know how much you know. You may be asked to upload your project file to look at. Don't be afraid to ask questions about what things mean, but also please be patient with the people trying to help you. (And helpers, please be patient with the person you're trying to help!)
-
- Posts: 9
- Joined: Thu May 25, 2023 6:45 am
- Preferred Pronouns: He/Him
- Operating System Version (Optional): Windows 11
- Graphics Processor: nVidia (Modern GZDoom)
Access System's Username
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
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
-
- Posts: 852
- Joined: Mon May 10, 2021 8:08 pm
- Preferred Pronouns: He/Him
- Operating System Version (Optional): EndeavorOS (basically Arch)
- Graphics Processor: Intel with Vulkan/Metal Support
Re: Access System's Username
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.
-
- Posts: 9
- Joined: Thu May 25, 2023 6:45 am
- Preferred Pronouns: He/Him
- Operating System Version (Optional): Windows 11
- Graphics Processor: nVidia (Modern GZDoom)
-
- Posts: 852
- Joined: Mon May 10, 2021 8:08 pm
- Preferred Pronouns: He/Him
- Operating System Version (Optional): EndeavorOS (basically Arch)
- Graphics Processor: Intel with Vulkan/Metal Support
Re: Access System's Username
No, but you can use the player name.
-
- Posts: 9
- Joined: Thu May 25, 2023 6:45 am
- Preferred Pronouns: He/Him
- Operating System Version (Optional): Windows 11
- Graphics Processor: nVidia (Modern GZDoom)
Re: Access System's Username
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.
-
- Posts: 2950
- Joined: Thu Jul 17, 2003 12:07 am
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
Re: Access System's Username
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.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.
-
- Posts: 21706
- Joined: Tue Jul 15, 2003 7:33 pm
- Preferred Pronouns: He/Him
- Operating System Version (Optional): A lot of them
- Graphics Processor: Not Listed
Re: Access System's Username
Your mod would end up addressing me as "wildw" or "owner" which wouldn't really work either.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.
-
- Posts: 1558
- Joined: Tue Oct 20, 2015 12:50 pm
- Graphics Processor: nVidia with Vulkan support
- Location: Kozolupy, Bohemia
Re: Access System's Username
Yeah, another attempt on jumpscare wad, just to be completely fade away like a year later.
-
- Posts: 9
- Joined: Thu May 25, 2023 6:45 am
- Preferred Pronouns: He/Him
- Operating System Version (Optional): Windows 11
- Graphics Processor: nVidia (Modern GZDoom)
Re: Access System's Username
Hm, yeah that's a good point,.,..Chris wrote: ↑Sun May 28, 2023 2:16 pmGiven 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.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.
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
-
- Posts: 852
- Joined: Mon May 10, 2021 8:08 pm
- Preferred Pronouns: He/Him
- Operating System Version (Optional): EndeavorOS (basically Arch)
- Graphics Processor: Intel with Vulkan/Metal Support
Re: Access System's Username
What I meant was getting the name CVar. That is the name the player uses in game.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.
-
- Posts: 9
- Joined: Thu May 25, 2023 6:45 am
- Preferred Pronouns: He/Him
- Operating System Version (Optional): Windows 11
- Graphics Processor: nVidia (Modern GZDoom)
Re: Access System's Username
Oh, I thought you meant GetUserName() from the Player structyum13241 wrote: ↑Tue May 30, 2023 8:08 amWhat I meant was getting the name CVar. That is the name the player uses in game.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.
-
- Posts: 75
- Joined: Mon Aug 26, 2019 9:18 pm
- Graphics Processor: nVidia with Vulkan support
Re: Access System's Username
Yeah, that's what yum is talking about, the GetUsername() method gets the name CVAR of the player whose struct belongs to.cawmageddon wrote: ↑Tue May 30, 2023 7:03 pmOh, I thought you meant GetUserName() from the Player structyum13241 wrote: ↑Tue May 30, 2023 8:08 amWhat I meant was getting the name CVar. That is the name the player uses in game.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.
And ? Most maps aren't unforgettable masterpieces that will be fondly remembered for years to come.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.
-
- Posts: 9
- Joined: Thu May 25, 2023 6:45 am
- Preferred Pronouns: He/Him
- Operating System Version (Optional): Windows 11
- Graphics Processor: nVidia (Modern GZDoom)
Re: Access System's Username
Oh, thank you !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.