[Added] [USDF/ZSDF] More than 1 image per dialogue / offset graphic

Moderator: GZDoom Developers

Re: [USDF/ZSDF] More than 1 image per dialogue / offset grap

Postby Rachael » Tue Feb 21, 2017 3:36 pm

I think what would help Tormentor667 more than anything else right now is just a single use-case example showing this in action that he can edit to suit his own needs.

Were I knowledgeable about this and not engaging in other projects at the moment, I would do this, myself.
User avatar
Rachael
Admin
 
Joined: 13 Jan 2004
Discord: Rachael#3767
Twitch ID: madamerachelle
Github ID: madame-rachelle
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: [USDF/ZSDF] More than 1 image per dialogue / offset grap

Postby Major Cooke » Tue Feb 21, 2017 3:45 pm

Yeah, I would too. Trying to learn this stuff from scratch sucks.
User avatar
Major Cooke
QZDoom Maintenance Team
 
Joined: 28 Jan 2007

Re: [USDF/ZSDF] More than 1 image per dialogue / offset grap

Postby Tormentor667 » Tue Feb 21, 2017 4:31 pm

Thanks for the reply. I do understand that Graf follows this new philosophy and that's something people can actually live with. Concerning ZScript - I have no idea where to start honestly... I am really no programmer at all so taking a look at the sourcecode will make things just worse
User avatar
Tormentor667
needs more detail
 
Joined: 16 Jul 2003
Location: Germany

Re: [USDF/ZSDF] More than 1 image per dialogue / offset grap

Postby Graf Zahl » Wed Feb 22, 2017 3:18 am

You'll have to write a new DrawBackdrop function in that new class. But to give you some help you should do a mock-up as demonstration of what you plan to do.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
 
Joined: 19 Jul 2003
Location: Germany

Re: [USDF/ZSDF] More than 1 image per dialogue / offset grap

Postby Tormentor667 » Wed Feb 22, 2017 11:15 am

Sure thing, here you go: http://imgur.com/a/rBWag
User avatar
Tormentor667
needs more detail
 
Joined: 16 Jul 2003
Location: Germany

Re: [USDF/ZSDF] More than 1 image per dialogue / offset grap

Postby Graf Zahl » Wed Feb 22, 2017 1:18 pm

That may require a bit more of fiddling with the script code. If I had some time on my hands I might be able to help you but I'm afraid you'll have to ask someone else.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
 
Joined: 19 Jul 2003
Location: Germany

Re: [USDF/ZSDF] More than 1 image per dialogue / offset grap

Postby Tormentor667 » Wed Feb 22, 2017 2:08 pm

Fortunately, Nash is already trying something. Let's see where he ends up with, he is very skilled with stuff like that and knows the code so we have good chances I'd say. Thanks still for your help.
User avatar
Tormentor667
needs more detail
 
Joined: 16 Jul 2003
Location: Germany

Re: [USDF/ZSDF] More than 1 image per dialogue / offset grap

Postby AFADoomer » Thu Feb 23, 2017 6:45 pm

So, I made a thing... Then saw that Nash is working this already. Oh, well.

Image

Used existing graphics (the pain flash is the background, hence the red tint).

The fade image (pain flash here) is always drawn, and the face image co-opts the existing background image in ZSDF (so no change to existing dialogue lumps is needed). Left the default font because I wasn't sure what you actually wanted done there. The indents on the name and first line are in LANGUAGE, so could be removed easily there - by default, the text all aligns left.

Some choice strings may need to be re-worked because they are too wide now (like the costs and durations on the clerk's other conversation).

Spoiler: ZScript contents
User avatar
AFADoomer
 
Joined: 15 Jul 2003

Re: [USDF/ZSDF] More than 1 image per dialogue / offset grap

Postby Nash » Thu Feb 23, 2017 11:24 pm

@AFADoomer: I suggest you go ahead and submit your work to Tormentor! I am a little short on time currently. :(

@Tormentor667: Look, what AFA did is perfect for your needs. :D
User avatar
Nash
Twitter/Facebook/Youtube: nashmuhandes
 
 
 
Joined: 27 Oct 2003
Location: Kuala Lumpur, Malaysia
Twitch ID: nashmuhandes
Github ID: nashmuhandes

Re: [USDF/ZSDF] More than 1 image per dialogue / offset grap

Postby AFADoomer » Thu Feb 23, 2017 11:56 pm

Thanks, Nash!

@Tormentor - Give me the go-ahead, and I'll commit this to github for testing.

Current state:
Image

Right now, everything looks good at 4:3 and 16:9, but there are alignment issues at other aspect ratios - nothing game-breaking, just not pretty... I reinvented the wheel on some of the code, because I was learning it as I went, so there's definitely room for improvement, still.
User avatar
AFADoomer
 
Joined: 15 Jul 2003

Re: [USDF/ZSDF] More than 1 image per dialogue / offset grap

Postby Nash » Fri Feb 24, 2017 12:04 am

The pixels on the font look dirty... are you using the clean scaling tags?
User avatar
Nash
Twitter/Facebook/Youtube: nashmuhandes
 
 
 
Joined: 27 Oct 2003
Location: Kuala Lumpur, Malaysia
Twitch ID: nashmuhandes
Github ID: nashmuhandes

Re: [USDF/ZSDF] More than 1 image per dialogue / offset grap

Postby AFADoomer » Fri Feb 24, 2017 7:33 am

Nash wrote:The pixels on the font look dirty... are you using the clean scaling tags?

No... That was part of the "reinventing the wheel" that I was talking about. It should be a relatively quick fix, I just didn't have time to rework it last night.
User avatar
AFADoomer
 
Joined: 15 Jul 2003

Re: [USDF/ZSDF] More than 1 image per dialogue / offset grap

Postby Tormentor667 » Fri Feb 24, 2017 9:09 am

Hey Afa, thanks alot for helping us out with this, it looks already very good :) Feel free to commit the work. Regarding the line height/gap, just keep it as it was before. The mockup for the text was only meant to know where the text is, not how it looks.

Maybe you have also ideas on how to improve it or make it look better, so feel free to add your own suggestions. :)
User avatar
Tormentor667
needs more detail
 
Joined: 16 Jul 2003
Location: Germany

Re: [USDF/ZSDF] More than 1 image per dialogue / offset grap

Postby AFADoomer » Sat Feb 25, 2017 12:02 am

OK, just added this to Blade of Agony...

Also implemented independent scaling for the conversation text and the replies... The replies shown here are slightly smaller than the speaker's text, mostly so that everything fits without re-doing the DIALOGUE lumps.
Image

Spoiler: Code
User avatar
AFADoomer
 
Joined: 15 Jul 2003

Re: [USDF/ZSDF] More than 1 image per dialogue / offset grap

Postby Tormentor667 » Sat Feb 25, 2017 5:02 am

Oh yes :) Thanks so kindly AFADoomer, this looks perfect now and the terribly looking Dialogue with overlapping text and mugs is gone :) Thanksthanksthanks!!!

*EDIT*
Noticed two issues when trying it with the latest SVN, first: I can't use the mouse anymore to choose from the options. Second, if you start a new game and choose the difficulty, the "are you sure" message appears to be off-center. Would you mind trying?

*EDIT2*
For some reason the toilet dialogue isn't talking anymore as well even though it hasn't been touched.
User avatar
Tormentor667
needs more detail
 
Joined: 16 Jul 2003
Location: Germany

PreviousNext

Return to Closed Feature Suggestions

Who is online

Users browsing this forum: No registered users and 3 guests