Need some help here. I'm trying to produce a credits cutscene. I copied code from OFP's resource.cpp file in my attempt.
Here's my description.ext file:
class RscText
{
type = CT_STATIC;
idc = -1;
style = ST_LEFT;
h = 0.04;
colorBackground[] = {0, 0, 0, 0};
colorText[] = {TextColor, 0.75};
font = FontS;
sizeEx = 0.02;
};
class RscTitles
{
class creditsback
{
idd=-1;
movingEnable = false;
duration=10000;
name = "Creditsback";
controls[]=
{
Back, background
};
class Back : RscText
{
x = 0.72; y = 0.0; w = 0.5; h = 1.0;
text = "";
colorBackground[] = {0.0, 0.0, 0.0, 1};
};
class Background : RscText
{
text =;
colorBackground[] = {0, 0, 0, 0};
x = 0; y = 0; w = 1; h = 1;
colorText[] = {0, 0, 0, 0};
};
};
class CRtitle : creditsback
{
name = "CRtitle";
controls[]=
{
Back, background, work1, name1
};
class work1 : RscText
{
style = ST_MULTI + ST_CENTER + ST_NO_RECT;
lineSpacing = 1.0;
text = $STR_CREDITS01;
x = 0.36; y = 0.3; w = 1.0; h = 0.73;
colorText[] = {0.75, 0.75, 1.0, 1};
font = FontMAINCZ;
sizeEx = 0.7 * 0.05;
};
class name1 : RscText
{
style = ST_MULTI + ST_CENTER + ST_NO_RECT;
lineSpacing = 1.0;
text = $STR_CREDITSN01;
x = 0.36; y = 0.35; w = 1.0; h = 0.53;
colorText[] = {1.0, 1.0, 1.0, 1};
font = FontMAINCZ;
sizeEx = 1.1 * 0.05;
};
};
};
Here's my stringtable.csv file:
COMMENT, Credits, Crédits, Titoli, Colaboradores, Mitarbeiter, Autoøi
STR_CREDITS01,Test Title,Test Title,Test Title,Test Title,Test Title
STR_CREDITSN01,by The Avon Lady,by The Avon Lady,by The Avon Lady,by The Avon Lady,by The Avon Lady
Here's the script to display the background:
cutrsc ["creditsback","plain down", 0]
~4
c1=true
~16.2
The black right-side background displays OK, just as in OFP's credits cutscenes. The about script sets variable c1 to true.
There's a trigger in mission.sqm that under condition "c1", the following effects are executed:
class Effects
{
titleType="RES";
title="CRtitle";
};
This should have displayed the text defined as CRtitle in my description.ext file. Instead I get the following screen:
Where did I go wrong (other than taking on this endeavor in the first place)? What's causing that grey area to appear instead of my text planted neatly in the right hand black vertical column?
TIA!