Jump to content
Sign in to follow this  
KeyCat

Any dialog wizards hanging around?

Recommended Posts

I have very limited experience with dialogs at all in OFP and I'm using Vectorboson's nice tutorial to learn more about the subject but having hard time figuring this out and the tutorial doesn't cover it...

Here is what I want to do:

I want to use the built in 3D laptop to show some multi-line text/s. I have the laptop showing OK when in map view and are able to place singe line texts on the screen at center or left/right but I can't figure out how to do multi-line text (I know it's possible to do in 2D dialogs)!?

Anyone having any hints, tips or maybe even a simple demo laying around wink_o.gif

/Christer (a.k.a KeyCat)

Share this post


Link to post
Share on other sites

Example for a multiline resource of a dialog:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">class Title : RscText

{

style = ST_CENTER+ST_MULTI+ST_NO_RECT;

lineSpacing = 1;

x = 0;

y = 0.15;

w = 1;

h = 0.15;

text = "Line 1\nLine 2";

sizeEx = 0.04;

font = FontB;

};

Share this post


Link to post
Share on other sites

@ hardrock: Thanks for a swift reply but are you 100% sure this works on the 3D laptop dialog? I have tried something very similar before posting but that didn't work...

Even with my limited knowledge it looks like your example is for a 2D dialog, correct?

/Christer (a.k.a KeyCat)

Share this post


Link to post
Share on other sites

You could be right on that, I used that way on a 2d resource, but wouldn't it work on a 3d resource too?

Share this post


Link to post
Share on other sites

Nope, or at least I couldn't get it to work in a 3D dialog and thats why I'm asking tounge2.gif

Anyone else???

/Christer (a.k.a KeyCat)

Share this post


Link to post
Share on other sites

If I remember correctly static multi-line text was not working in 3d dialogs.

Only possibility is to use indeed a 2d multi-line text and it will be written on the right place on the laptop, but not perspective correct.

If you are looking frontal at the laptop you won't see a difference.

Share this post


Link to post
Share on other sites

Thanks for your reply vektorboson! Still a bit confused tho...

If I understand you correctly I should create a multi-line 2D dialog then somehow show it on the 3D laptop screen?

/Christer (a.k.a KeyCat)

Share this post


Link to post
Share on other sites

This is from an old description.ext

I am not sure it worked or not...

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

class Rsc3DText

{

type = CT_3DSTATIC;

idc = -1;

selection = "display";

style = ST_CENTER;

colorText[] = {0, 1, 0, 1};

color[] = {0, 1, 0, 1};

font = FontHTMLBold;

angle = 0;

size = 0.8;

sizeEx = 0.02;

default = false;

};

class MItem7 : Rsc3DText

       {

         idc = 907;

         style=ST_MULTI;

         lines=9;

         lineWidth=.5;

         lineSpacing=0.005;

         size=0.04;

         x = 0.03; y = 0.4; w = 0.94; h = 0.405;

         text = "xxxx";

};

Share this post


Link to post
Share on other sites

Thanks CrashDome! I will try it and see if I can figure it out from there...

/Christer (a.k.a KeyCat)

Share this post


Link to post
Share on other sites

Still haven't solved this one sad_o.gif

Only possibility is to use indeed a 2d multi-line text and it will be written on the right place on the laptop, but not perspective correct.

If you are looking frontal at the laptop you won't see a difference.

vektorboson, would you mind elaborate a bit on how to do this?

/Christer (a.k.a KeyCat)

Share this post


Link to post
Share on other sites

He meant that you create as well a 3d resource as a 2d resource, and place the 2d (multi-line) resource on the screen so that it looks like it was on the 3d resource. That only works, if you make the 3d resource fixed (thus no-one can move it around).

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×