Advanced input method - HudInput

Post a reply

Smilies
:D :) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :wink: :geek: :ugeek: :!: :?: :idea: :arrow: :| :mrgreen: :3: :wub: >:( :blergh:
View more smilies

BBCode is OFF
Smilies are ON

Topic review
   

Expand view Topic review: Advanced input method - HudInput

Re: Advanced input method - HudInput

by Nash » Wed Aug 06, 2014 5:45 am

GooberMan wrote:But needless to say, there's far nicer ways to get keyboard input there than hacking in to the chat functionality. I'd rather a full-fledged API that has properly thought things through than something that essentially replicates the BASIC prompts you used to type in to C64s in stores back in the day.
I think there's some left-over code in the ACS stuff that was supposed to be a proper input API... I remember Randi briefly talked about it many years ago but I can't find the posts anymore. :D Would be cool to see that stuff pickup up again.

Re: Advanced input method - HudInput

by Graf Zahl » Wed Aug 06, 2014 2:41 am

Indeed. I didn't close this because the patch was not readable but because this is the wrong way to go about it.
To ensure that the input gets to where it is needed it needs to be routed through the network command stream, like Edward850 pointed out

Re: Advanced input method - HudInput

by edward850 » Wed Aug 06, 2014 2:34 am

You don't even know what you are doing, do you? This fixes absolutely nothing about the issues pointed out. The Input still doesn't touch the player command buffer, and it will still break horribly in demos (I'm not sure how amused I'm supposed to be at the chat dialog popping up during demo playback).

And it's still pretty much the wrong way to go about any of this.

Re: Advanced input method - HudInput

by Monsterovich » Wed Aug 06, 2014 2:19 am

Graf Zahl wrote:
edward850 wrote:I literally cannot understand what's going on with this code. You define player numbers in your "specifications" but otherwise never use them. You only ever pull the string/chatmode from the local session, and the string can only ever be created by the local session. It never even touches player commands, which makes it beyond unusable in almost every test case I can think of.

Demos and netgames be damned. Which is completely absurd for something that uses player numbers as part of its spec.
This neither works with demos nor with multiplayer. Sorry, can't be added as-is.
You closed suggestion faster than I posted new comment. I made new version of patch that could help in netgames. I just added hud information to player's object.
Hope, this helps.

Re: Advanced input method - HudInput

by edward850 » Wed Aug 06, 2014 2:02 am

Basically, yeah. That's the other problem I had with this. It's rather kludged in with a function that made little sense from a user standpoint (why the chatmesseage function? Especially if you're not actually chatting to something), and it incorrectly assumed that players would always have some form of keyboard input (which is kind of a bad thing to assume these days).

It does make me wonder if it would be worth adding the virtual keyboard to the chatmessage function, though. :P

Re: Advanced input method - HudInput

by GooberMan » Wed Aug 06, 2014 1:57 am

Well, I won't go in to a stylistic discussion there.

But needless to say, there's far nicer ways to get keyboard input there than hacking in to the chat functionality. I'd rather a full-fledged API that has properly thought things through than something that essentially replicates the BASIC prompts you used to type in to C64s in stores back in the day.

Re: Advanced input method - HudInput

by Nash » Tue Aug 05, 2014 7:01 pm

Would be useful actually (I have at least 3 major uses for this if this were implemented) but I guess the implementation is incomplete. Once demo, save-game and multiplayer compatibility is properly worked out, I'm sure it'd be decent for inclusion.

Example usage: text entry with keyboard instead of ACS-based mouse-driven on-screen keyboard . For in-game journals, question/answer stuff, etc.

Re: Advanced input method - HudInput

by Graf Zahl » Tue Aug 05, 2014 3:44 pm

edward850 wrote:I literally cannot understand what's going on with this code. You define player numbers in your "specifications" but otherwise never use them. You only ever pull the string/chatmode from the local session, and the string can only ever be created by the local session. It never even touches player commands, which makes it beyond unusable in almost every test case I can think of.

Demos and netgames be damned. Which is completely absurd for something that uses player numbers as part of its spec.

Ok, that decides it. After reading this I had a closer look at the code and you are correct. This neither works with demos nor with multiplayer. Sorry, can't be added as-is.

Re: Advanced input method - HudInput

by GooberMan » Tue Aug 05, 2014 3:27 pm

I want to know what general purpose need this fills (since the OP claimed such things) and why a raw input reader in ACS wouldn't be a better idea.

Re: Advanced input method - HudInput

by Edward-san » Tue Aug 05, 2014 3:04 pm

Please use 'diff -u' instead of 'diff -c'. This is because the patch format is not compatible with git.

Re: Advanced input method - HudInput

by edward850 » Tue Aug 05, 2014 11:14 am

I literally cannot understand what's going on with this code. You define player numbers in your "specifications" but otherwise never use them. You only ever pull the string/chatmode from the local session, and the string can only ever be created by the local session. It never even touches player commands, which makes it beyond unusable in almost every test case I can think of.

Demos and netgames be damned. Which is completely absurd for something that uses player numbers as part of its spec.

Re: Advanced input method - HudInput

by Monsterovich » Tue Aug 05, 2014 11:08 am

Graf Zahl wrote:Hm. I get this when trying to apply with TortoiseGit:
Patch format detection failed.

Fail
How did you create this patch?
diff -c ./zdoombak/src/ ./zdoom/src/ > inputpatch_2.7.1_2.diff

Stupid question. Have you renamed it to .diff? :P Or this is not important?

Re: Advanced input method - HudInput

by Graf Zahl » Tue Aug 05, 2014 11:03 am

Hm. I get this when trying to apply with TortoiseGit:
Patch format detection failed.

Fail
How did you create this patch?

Re: Advanced input method - HudInput

by edward850 » Tue Aug 05, 2014 11:02 am

Something about this seems incomplete. I don't see how the text is being handled by the player command buffer.
Edit: Yeah, nothing about this is implemented properly at all.

Re: Advanced input method - HudInput

by Monsterovich » Tue Aug 05, 2014 10:43 am

Graf Zahl wrote:Please repost the patch as attachment. Directly coming from a

Code: Select all

 section it cannot be applied without errors.[/quote]

"The extension diff is not allowed."

lol Ok, done.

Top