Meanwhile, this thread languishes...
Every time a mouse UI comes up, no one solves multiplayer/alternate input issues. So let's solve them.
My try at an on-screen mouse cursor script
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Re: My try at an on-screen mouse cursor script
Okay then, so here are a bunch of issues with this script:
I don't know if that's the best way, but to me, it seems like it could be one of the only ways.
The second issue would probably take some feature suggestions. Like edward said, how are we to know what the player is using to input yaw/pitch movement? There's no way to tell at this time.
The third issue could easily be resolved with some extra code in the script, but then that just compounds onto the 4th issue.
The 4th issue could be resolved if the script ran clientside and reported any events to the server when necessary (such as clicking on something, but this is just a mouse script, so that is beyond the scope of this script). IIRC, clientside scripts are only in Zandronum/Skulltag.
Yikes, this is more complex than I had previously thought! Do let me know what you guys think.
- There is no good way to account for the "invertmouse" CVar without multiplayer/demo issues.
- There is no way to account for other forms of input besides mouse and keyboard (mouselook/keyboard look)
- The script itself doesn't have anything specially coded to deal with multiple players using it at this moment.
- The script runs every tic. That might put some strain on the host, but then again, how are we to have a smooth cursor without the script running every tic?
I don't know if that's the best way, but to me, it seems like it could be one of the only ways.
The second issue would probably take some feature suggestions. Like edward said, how are we to know what the player is using to input yaw/pitch movement? There's no way to tell at this time.
The third issue could easily be resolved with some extra code in the script, but then that just compounds onto the 4th issue.
The 4th issue could be resolved if the script ran clientside and reported any events to the server when necessary (such as clicking on something, but this is just a mouse script, so that is beyond the scope of this script). IIRC, clientside scripts are only in Zandronum/Skulltag.
Yikes, this is more complex than I had previously thought! Do let me know what you guys think.
Re: My try at an on-screen mouse cursor script
This sounds like you think ZDoom can be affected by map complexity over the network. It isn't. Everything already is "clientside", and the only component that scales is the number of players, as the playsim itself is determined by player input. Hence it being deterministic in the first place. Zandro added clientside functions to attempt to get around the problem of its own network components not being able to scale like that at all.wtg62 wrote:The 4th issue could be resolved if the script ran clientside and reported any events to the server when necessary (such as clicking on something, but this is just a mouse script, so that is beyond the scope of this script). IIRC, clientside scripts are only in Zandronum/Skulltag.
That is how Doom always worked, in case you forgot.

Re: My try at an on-screen mouse cursor script
Pffft how could I forget that? Silly me!
Probably because I haven't touched ZDoom multiplayer in ages.
And... was thinking of Zandronum, stranegly.
So how's about those other actual problems then?
Probably because I haven't touched ZDoom multiplayer in ages.

And... was thinking of Zandronum, stranegly.
So how's about those other actual problems then?

Re: My try at an on-screen mouse cursor script
The actual problem is that ACS simply isn't designed for such a system, and while ideas have been discussed, nobody has had time to design or prototype any such implementation that would. Strife Dialogues are about as close as one gets, at the moment (sanity wise).
Re: My try at an on-screen mouse cursor script
I agree with you there. How are we to have a good UI system, when it runs with a ticrate of 35 tics per second?
Even if 35 is a large number compared to most games, you aren't going to be able to simulate a mouse very well.
That's something that definitely bothered me making this script, because of the unwanted lagging effect it created.
Plus... well, multiplayer issues are there for sure.
Strife dialogues don't suffer a lot of the issues ACS UI scripts do, correct?
The problem with Strife dialogues for me, is how little flexibility it gives you.
I could sorta picture a system that works like the Strife dialogues, but lets you change the x & y positions of text, or even use images and what not.
I'd think transitions (i.e. menu options sliding in and other slightly more complex stuff) may be out of the question though, or would come later.
Even if 35 is a large number compared to most games, you aren't going to be able to simulate a mouse very well.
That's something that definitely bothered me making this script, because of the unwanted lagging effect it created.
Plus... well, multiplayer issues are there for sure.
Strife dialogues don't suffer a lot of the issues ACS UI scripts do, correct?
The problem with Strife dialogues for me, is how little flexibility it gives you.
I could sorta picture a system that works like the Strife dialogues, but lets you change the x & y positions of text, or even use images and what not.
I'd think transitions (i.e. menu options sliding in and other slightly more complex stuff) may be out of the question though, or would come later.
- Xeotroid
- Posts: 448
- Joined: Sat Jun 23, 2012 7:44 am
- Graphics Processor: nVidia with Vulkan support
- Location: Czech Rep.
Re: My try at an on-screen mouse cursor script
For more flexible dialogues you might check out ZKVN, but I didn't look into it. Otherwise... you'll have to wait for DoomScript
Re: My try at an on-screen mouse cursor script
I was definitely picturing just this kind of flexibility. Really good link you just gave me there.Xeotroid wrote:For more flexible dialogues you might check out ZKVN, but I didn't look into it. Otherwise... you'll have to wait for DoomScript