Home   Help Search Login Register  

Author Topic: Custom Res Prob... (ITS NOTT OVER!!!)  (Read 3008 times)

0 Members and 1 Guest are viewing this topic.

Captain Winters

  • Guest
Re:Custom Res Prob...
« Reply #15 on: 23 Jul 2003, 01:05:20 »
Hmm... I tried it, got no error, but no picture popped up either  :-[

Tanks! 8)

Offline Sui

  • Former Staff
  • ****
    • OFPEC
Re:Custom Res Prob...
« Reply #16 on: 23 Jul 2003, 03:33:10 »
Just eliminating all the obvious things here... so please bear with me mate :)

What size is your picture, and is it in your users/missions/missionname directory?

Oh, also, in your .ext entry, try putting quotes around the file name. Eg.

text = "credits1.jpg";

Rather than:

text = credits1.jpg;

Gameer_77

  • Guest
Re:Custom Res Prob...
« Reply #17 on: 23 Jul 2003, 11:09:02 »
And if that don't work, try this instead of RscPicture:

Code: [Select]


class RscText
{
   type = CT_STATIC;
   idc = -1;
   style = ST_LEFT;
   colorBackground[] = {0, 0, 0, 0};
   colorText[] = {TextColor, 0.75};
   font = FontMAIN;
   sizeEx = 0.02;
};


Remember and change the bottom half too (class credits1:RscText)

Captain Winters

  • Guest
Re:Custom Res Prob...
« Reply #18 on: 23 Jul 2003, 17:09:12 »
Okay,

@Sui- The sizes are 512x256 and one's 512x512. And they are in that dir.
@Gameer- I tried that as well, and no luck...  :-\


Tanks! 8)

Gameer_77

  • Guest
Re:Custom Res Prob...
« Reply #19 on: 23 Jul 2003, 19:41:10 »
OK, this works for me when I do it... :-\


Code: [Select]
#define CT_STATIC                  0
#define CT_BUTTON                  1
#define CT_EDIT                     2
#define CT_SLIDER                  3
#define CT_COMBO                  4
#define CT_LISTBOX               5
#define CT_TOOLBOX               6
#define CT_CHECKBOXES            7
#define CT_PROGRESS               8
#define CT_HTML                     9
#define CT_STATIC_SKEW         10
#define CT_ACTIVETEXT            11
#define CT_TREE                     12
#define CT_3DSTATIC               20
#define CT_3DACTIVETEXT         21
#define CT_3DLISTBOX            22
#define CT_3DHTML                  23
#define CT_3DSLIDER               24
#define CT_3DEDIT                  25
#define CT_OBJECT                  80
#define CT_OBJECT_ZOOM         81
#define CT_OBJECT_CONTAINER   82
#define CT_OBJECT_CONT_ANIM   83
#define CT_USER                     99

// Static styles
#define ST_HPOS                  0x0F
#define ST_LEFT                  0
#define ST_RIGHT               1
#define ST_CENTER               2
#define ST_UP                     3
#define ST_DOWN                  4
#define ST_VCENTER            5

#define ST_TYPE                  0xF0
#define ST_SINGLE               0
#define ST_MULTI               16
#define ST_TITLE_BAR         32
#define ST_PICTURE            48
#define ST_FRAME               64
#define ST_BACKGROUND         80
#define ST_GROUP_BOX         96
#define ST_GROUP_BOX2         112
#define ST_HUD_BACKGROUND   128
#define ST_TILE_PICTURE      144
#define ST_WITH_RECT         160
#define ST_LINE                  176

#define ST_SHADOW               256
#define ST_NO_RECT            512

#define ST_TITLE               ST_TITLE_BAR + ST_CENTER

// Predefined controls
#define IDC_OK                  1
#define IDC_CANCEL            2

// Colors
#define TextColor         0.08, 0.08, 0.12
#define InvTextColor   0.35, 0.38, 0.36

// Fonts
#define FontS "tahomaB24"
#define FontM "tahomaB36"

#define FontHTML "courierNewB64"
#define FontHTMLBold "courierNewB64"
#define FontMAP "courierNewB64"
#define FontMAIN "SteelfishB64"
#define FontMAINCZ "SteelfishB64CE"
#define FontTITLE "SteelfishB128"
#define FontTITLEHalf "SteelfishB64"
#define FontBOOK "garamond64"
#define FontNOTES "AudreysHandI48"

class RscText
{
   type = CT_STATIC;
   idc = -1;
   style = ST_LEFT;
   colorBackground[] = {0, 0, 0, 0};
   colorText[] = {TextColor, 0.75};
        font = FontMAIN;
   sizeEx = 0.02;
};

class RscTitles
{
  class credits1
  {
      name = "credits1";
      duration = 16.5;
      idd = -1;
      movingEnable = false;
      fadein=0;
      controls[]=
      {
        credits1
      };
      class credits1:RscText
   {
                 idc = 0;
              x = 0.2;
               y = 0.2;
                  w = 0.15;
              h = 0.2;
             colorText[] = {1,1,1,1};
        text = \tag.jpg;
        style = ST_PICTURE + ST_NO_RECT;
   };
  };

Offline Sui

  • Former Staff
  • ****
    • OFPEC
Re:Custom Res Prob...
« Reply #20 on: 24 Jul 2003, 02:53:13 »
* Sui slaps himself on the forehead

Of course... it had to do with defining your styles.

I generally don't do that, I just put the number in. But if you are going to use labels, eg.

   type = CT_STATIC;
   idc = -1;
   style = ST_LEFT;

You have to actually tell OFP what CT_STATIC and ST_LEFT are...
Personally, I prefer to use:

   type = 0;
   idc = -1;
   style = 0;

And not have that huge section at the start of your .ext file, but I guess it amounts to the same sort of thing ;)

Captain Winters

  • Guest
Re:Custom Res Prob...
« Reply #21 on: 24 Jul 2003, 03:28:54 »
Thanks Sui and Gameer!  ;D :-*

Tanks! 8)

Captain Winters

  • Guest
Re:Custom Res Prob...
« Reply #22 on: 31 Jul 2003, 00:48:25 »
DUHN SUHN DUHN! We htought it was over... *I* thought it was over! It Is'NT!

Code: [Select]
#define CT_STATIC                  0
#define CT_BUTTON                  1
#define CT_EDIT                     2
#define CT_SLIDER                  3
#define CT_COMBO                  4
#define CT_LISTBOX               5
#define CT_TOOLBOX               6
#define CT_CHECKBOXES            7
#define CT_PROGRESS               8
#define CT_HTML                     9
#define CT_STATIC_SKEW         10
#define CT_ACTIVETEXT            11
#define CT_TREE                     12
#define CT_3DSTATIC               20
#define CT_3DACTIVETEXT         21
#define CT_3DLISTBOX            22
#define CT_3DHTML                  23
#define CT_3DSLIDER               24
#define CT_3DEDIT                  25
#define CT_OBJECT                  80
#define CT_OBJECT_ZOOM         81
#define CT_OBJECT_CONTAINER   82
#define CT_OBJECT_CONT_ANIM   83
#define CT_USER                     99

// Static styles
#define ST_HPOS                  0x0F
#define ST_LEFT                  0
#define ST_RIGHT               1
#define ST_CENTER               2
#define ST_UP                     3
#define ST_DOWN                  4
#define ST_VCENTER            5

#define ST_TYPE                  0xF0
#define ST_SINGLE               0
#define ST_MULTI               16
#define ST_TITLE_BAR         32
#define ST_PICTURE            48
#define ST_FRAME               64
#define ST_BACKGROUND         80
#define ST_GROUP_BOX         96
#define ST_GROUP_BOX2         112
#define ST_HUD_BACKGROUND   128
#define ST_TILE_PICTURE      144
#define ST_WITH_RECT         160
#define ST_LINE                  176

#define ST_SHADOW               256
#define ST_NO_RECT            512

#define ST_TITLE               ST_TITLE_BAR + ST_CENTER

// Predefined controls
#define IDC_OK                  1
#define IDC_CANCEL            2

// Colors
#define TextColor         0.08, 0.08, 0.12
#define InvTextColor   0.35, 0.38, 0.36

// Fonts
#define FontS "tahomaB24"
#define FontM "tahomaB36"

#define FontHTML "courierNewB64"
#define FontHTMLBold "courierNewB64"
#define FontMAP "courierNewB64"
#define FontMAIN "SteelfishB64"
#define FontMAINCZ "SteelfishB64CE"
#define FontTITLE "SteelfishB128"
#define FontTITLEHalf "SteelfishB64"
#define FontBOOK "garamond64"
#define FontNOTES "AudreysHandI48"

class RscText
{
   type = CT_STATIC;
   idc = -1;
   style = ST_LEFT;
   colorBackground[] = {0, 0, 0, 0};
   colorText[] = {TextColor, 0.75};
        font = FontMAIN;
   sizeEx = 0.02;
};

class RscTitles
{
  class map
  {
      name = "map";
      duration = 7;
      idd = -1;
      movingEnable = false;
      fadein=0;
      controls[]=
      {
        map
      };
      class map:RscText
   {
                 idc = 0;
             x = 0.2;
               y = 0.2;
                  w = 0.15;
             h = 0.2;
             colorText[] = {1,1,1,1};
        text = \tag.jpg;
        style = ST_PICTURE + ST_NO_RECT;
   {
  class end
  {
      name = "end";
      duration = 20;
      idd = -1;
      movingEnable = false;
      fadein=0;
      controls[]=
      {
        end
      };
      class end:RscText
   {
                 idc = 0;
             x = 0.2;
               y = 0.2;
                  w = 0.15;
             h = 0.2;
             colorText[] = {1,1,1,1};
        text = \tag.jpg;
        style = ST_PICTURE + ST_NO_RECT;
   };

Everything worked great.. until I tried the second picture...!!! I call it using the cutRSC n stuff, and I seriously have an issuse with not knowing. I attached the image I'm trying to get to work...  :-[
TIA

Tanks!  8)

Captain Winters

  • Guest
Re:Custom Res Prob... (ITS NOTT OVER!!!)
« Reply #23 on: 31 Jul 2003, 00:50:51 »
NEWS FLASH!

i just tried to save the level, and it gave me this error (check attachment!). I believe this may be the problem!!! (lol, no shit). Any ideas?

Tanks! 8)
« Last Edit: 31 Jul 2003, 00:51:07 by Captain Winters »

Offline Messiah

  • Honourary OFPEC Patron & Drinking Buddy of Wolfsbane
  • Honoured Contributor
  • ***
  • OFPEC Veteran
    • Project UK Forces
Re:Custom Res Prob... (ITS NOTT OVER!!!)
« Reply #24 on: 31 Jul 2003, 01:33:33 »
i think you've placed a = when you should have placed a {

roflmao  ;)

(im good at stating the obvious)
Proud Member of the Volunteer Commando Battalion

Captain Winters

  • Guest
Re:Custom Res Prob... (ITS NOTT OVER!!!)
« Reply #25 on: 31 Jul 2003, 01:58:47 »
ROTF!  ;D lol!
That aint it man! Checked!

Tanks! 8)

Gameer_77

  • Guest
Re:Custom Res Prob... (ITS NOTT OVER!!!)
« Reply #26 on: 31 Jul 2003, 13:25:05 »
Looks to me like you got a bit mixed up...

Quote
       ........
      controls[]=
      {
        map
      };
      class map:RscText
  {
                idc = 0;
            x = 0.2;
              y = 0.2;
                  w = 0.15;
            h = 0.2;
            colorText[] = {1,1,1,1};
        text = \tag.jpg;
        style = ST_PICTURE + ST_NO_RECT;
  {
  class end
  {
      name = "end";
      duration = 20;
      idd = -1;
      movingEnable = false;
      fadein=0;
      controls[]=
      {
        end
      };
        ..........

You've put a "{" at the end of the "map" picture whereas you should have double "};".

Code: [Select]
class RscTitles
{
  class map
  {
      name = "map";
      duration = 7;
      idd = -1;
      movingEnable = false;
      fadein=0;
      controls[]=
      {
        map
      };
      class map:RscText
  {
                idc = 0;
            x = 0.2;
              y = 0.2;
                  w = 0.15;
            h = 0.2;
            colorText[] = {1,1,1,1};
        text = \tag.jpg;
        style = ST_PICTURE + ST_NO_RECT;
};
};
  class end
  {
      name = "end";
      duration = 20;
      idd = -1;
      movingEnable = false;
      fadein=0;
      controls[]=
      {
        end
      };
      class end:RscText
  {
                idc = 0;
            x = 0.2;
              y = 0.2;
                  w = 0.15;
            h = 0.2;
            colorText[] = {1,1,1,1};
        text = \tag.jpg;
        style = ST_PICTURE + ST_NO_RECT;
};
};

I *think* that's what the problem is...

Gameer

EDIT  You *may* have to do a triple "};" on the very last picture...
« Last Edit: 31 Jul 2003, 13:26:54 by Gameer »

Captain Winters

  • Guest
Re:Custom Res Prob... (ITS NOTT OVER!!!)
« Reply #27 on: 31 Jul 2003, 17:20:22 »
okay! i'll try it out n let u kno!

Tanks! 8)

Captain Winters

  • Guest
Re:Custom Res Prob... (ITS NOTT OVER!!!)
« Reply #28 on: 31 Jul 2003, 18:45:16 »
GREEATTT! Thanks!  ;D ::)

Tanks! 8)