OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: Rockape on 01 Oct 2003, 15:16:28
-
Hi,
Can anyone help me out here and save my remaining hair (I've been ripping it out ;D)
I'm trying to add my Clan's logo at the start of my missions...now I can get Text up and the Standard images in the Resource or Object options using Triggers. But I can't work out how to get my own customised images to show.
Can anyone help?
Thanks
Rock
-
First you neeed to make the picture a size with power of 2
Then u need to define the picture in the description.ext file using teh RscPicture class
I might be wrong on the ggrammar of the picture bit of RscPicture
Any Idea LCD, SIR ARMSTY, MACGUBA (http://www.smilies.okipages.com/s/otn/funny/moon.gif)
go get a comref and browse that and i suggest you DePBo a BAS MIssion and look at the description.ext file. BAS use this feature in most missions..
Ill take alook into it also ;D
Rhys
-
Thanks...any help or pointers int he direction of a tutorial would be helpful!
I have had a look at some BAS missions but to be honest I'm not up to speed on programming...I'm learning though!?! ;D
-
Whoa?! I got counted as a guru?! This is the happiest day of my life.
I OOOOOOOOOOOOOOOOOOOOWN!!!
But I don't know how to do that...
Just kiddn ;D
You need to make a small dialog. Wait 2 secs until I find my file where I've done this before, need to refresh my memory.
:beat: *Gets Shot* :beat:
-
I guess you should read Vektorbosons dialog tute to understand this, I won't explain this so just copy everything.
First you need to define some stuff in your description.ext. I always take everything, wheter I need it or not.
// Control types
#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"
All creds goes to Gameer, cause it's he who defined all this, I just stole it. ;D
Then you need to put in da picture. NAMEOFPICTURE.jpg. There are some stuff there you probably understand yourself.
class picture
{
name = "picture";
duration =35;
idd = -1;
movingEnable = true;
controls[]=
{
picture
};
class picture : RscText
{
style = ST_PICTURE;
lineSpacing = 1.0;
text = "PICTURENAME.jpg";
x = 0.25; y = 0.1; w = 0.5; h = 0.8;
colorText[] = {1, 1, 1, 0.5};
font = FontMAINCZ;
sizeEx = 1.5 * 0.1;
size = 1;
};
};
OK. This is probably all wrong, cause I ain't very good at dialoges. I mostly use templates from some1 elses mission and then add my own stuff. But it might work... I dunno. :P
Anyway, read Vektorbosons tute about dialoges, it's the best way.
:beat: *Gets Shot* :beat:
-
So Rockape,
Have you got it working yet or are ya gonna keep me and the good man called Sir Armsty in the dark
*But not together ;D
Rhys
-
Thanks for the replies guys...
Apologies for the delay but I've been out of town for a few days....My first attempt at 0400 this morning failed but I think thats more to do with lack of sleep....I'll try again after a bit of kip and let you know. :)
Cheers :o
-
No need for testing. I don't think it'll work anyway, better wait for the real gurus to show up. Like I said... I suck at dialog editing.
:beat: *Gets Shot* :beat:
-
;D well you're right it didnt work...there was a class defination missing....but even after that it doesnt work.
I'm currently dissecting a BAS Mission int he hope I'll get something right ???
If anyone has a fix...please help me out...I was balding before....Now I'm already contemplating buying shares in "Regain".
::)
-
I wrote a quick and durty 'how to' on this a while back.
A quick forum search should have yeilded results...
Try taking a look here (http://www.ofpec.com/yabbse/index.php?board=9;action=display;threadid=9483) and see if it helps any ;)
-
Thanks alot for the help....
A quick forum search should have yeilded results...
Try taking a look here (http://www.ofpec.com/yabbse/index.php?board=9;action=display;threadid=9483) and see if it helps any ;)
As for search....it wont work properly for me. I get around 4 entries and then I get a screen full of MySQL errors... If i try refreshing it always comes back with more Errors. But thats always been my experience with YABB SE forums.
Again, thanks alot for your patience and the Tutorials. I now have it working so i'll have to come up with something esle to bug you with! ;)
Cheers