 |
|  |
 |
|
Nordicus
|
 |
Vancouver, B.C., Canada
Oct 1999 time: 21:13
|
|
Has anyone been in here yet?
Call To Power\ctp_data\english\uidata\layouts
When I tried to make trade icons (using UPBA5608 to UPBA5640), I found that many on-screen and in-game graphics were overwritten. Puzzled, because I checked all files, pic, icons, etc., which would use these numbers, so I snooped around & came across this file. Had to blow CTP away and reinstall...
Anyway, there's all sorts of goodies in this file--for anyone who's interested or just bored, have a look. (Also, good place to check before you start making any graphic material and plan to use upba, upa, and such.)
[This message has been edited by Nordicus (edited January 08, 2000).]
|
|
|  |
 |
|
Nordicus
|
 |
Vancouver, B.C., Canada
Oct 1999 time: 21:13
|
|
Oh, here's from diplomacy.ldl, part of what caused my trouble:
quote:
template DIP_RANGER:T_FONT5_DIPLOMACY {
bool alwaysranger true
rangery {
int widthpix 15
int heigthpix 15
string type "scroller"
string orientation "vertical"
string pattern "upba5605.tga"
incy {
int widthpix 15
int heightpix 15
string pattern "upba5605.tga"
}
decy {
int widthpix 15
int heightpix 15
string pattern "upba5605.tga"
}
# thumb {
# string image0 "upba5613.tga"
# string imagebltflag "chromakey"
# }
}
}
|
Apparently, all font colors, etc., are in these as well. Sizes of every window, menu, message, too. Maybe there's a way to include 32 civs thru this...?
Well, a thought.
[This message has been edited by Nordicus (edited January 08, 2000).]
[This message has been edited by Nordicus (edited January 15, 2000).]
[This message has been edited by Nordicus (edited January 15, 2000).]
|
|
|  |
 |
|
Dreamer
|
|
Singapore
Dec 1999 time: 05:13
|
|
I have seen an example from the tutorial SLIC where they use Attract() to call one of the button within the ControlPanel.ldl.
Seem like these ldl files are some kind of built-in routines that we can call out quite similar to Object Oriented Programming.
|
|
|  |
 |
|  |
 |
|
Nordicus
|
 |
Vancouver, B.C., Canada
Oct 1999 time: 21:13
|
|
Locutus, Dreamer...hey.
Yes, I knew this had potential 
Here is from "gameplayoptions.ldl":
quote:
GamePlayOptionsWindow {
string pattern "upba6417.tga"
string xanchor "center"
string yanchor "center"
int widthpix 390
int heightpix 225
int xpix 528
int ypix 451
Name:T_FONT4_POPTITLE {
string parent "c3_PopupTitle"
string xanchor "center"
string yanchor "top"
int widthpct 50
int heightpix 20
string text "str_ldl_GAMEPLAY_OPTIONS"
}
Background {
string image0 "upba2710.tga"
int xpix 93
int ypix 0
}
AcceptButton {
int xpix 404
int ypix 217
int widthpix 48
int heightpix 19
int bevelwidth 0
string imagebltflag "chromakey"
string image0 "upbb2303.tga"
}
TutorialButton:GAMEPLAY_CHECKBOX {
int ypix 40
stringtable {
string string0 "str_ldl_Tutorial_Advice_Off"
string string1 "str_ldl_Tutorial_Advice_On"
}
}
LeftRightClickMoveButton:GAMEPLAY_CHECKBOX {
int ypix 40
int xpix 30
stringtable {
string string0 "str_ldl_Right_Click_Move"
string string1 "str_ldl_Left_Click_Move"
}
}
AutoCycleTurnButton:GAMEPLAY_CHECKBOX {
int ypix 70
int xpix 30
stringtable {
string string0 "str_ldl_Auto_Cycle_Turn_Off"
string string1 "str_ldl_Auto_Cycle_Turn_On"
}
}
AutoCycleUnitsButton:GAMEPLAY_CHECKBOX {
int ypix 100
int xpix 30
stringtable {
string string0 "str_ldl_Auto_Cycle_Units_Off"
string string1 "str_ldl_Auto_Cycle_Units_On"
}
}
BattleViewButton:GAMEPLAY_CHECKBOX {
int ypix 130
int xpix 30
stringtable {
string string0 "str_ldl_Battle_View_Off"
string string1 "str_ldl_Battle_View_On"
}
}
MonumentButton:GAMEPLAY_CHECKBOX {
int ypix 130
int xpix 200
stringtable {
string string0 "str_ldl_Monument_Screen_Off"
string string1 "str_ldl_Monument_Screen_On"
}
}
BattleViewAlwaysButton:GAMEPLAY_CHECKBOX {
int ypix 160
int xpix 30
stringtable {
string string0 "str_ldl_Show_All_Battles_Off"
string string1 "str_ldl_Show_All_Battles_On"
}
}
MouseSpeedSlider {
int xpix 202
int ypix 89
int widthpix 160
int heightpix 38
int maxxval 15
int maxyval 0
int pagexval 1
int pageyval 1
int xval 5
string pattern "upba6417.tga"
string type "slider"
string orientation "horizontal"
bool rigidthumb TRUE
bool quantizedrag TRUE
int minthumbsize 9
int ticks 0
thumb {
int widthpix 9
int heightpix 40
string image0 "upba2513.tga"
string imagebltflag "chromakey"
}
}
MouseSpeedName:T_FONT1_91 {
int xpix 194
int ypix 74
int widthpix 102
int heightpix 20
int srcxpix 95
int srcypix 100
int srcwidthpix 160
int srcheightpix 20
string pattern "upba6417.tga"
string text "str_ldl_Mouse_Speed"
}
AutoSaveButton:GAMEPLAY_CHECKBOX {
int ypix 160
int xpix 200
stringtable {
string string0 "str_ldl_Autosave_Off"
string string1 "str_ldl_Autosave_On"
}
}
LeftHandedMouseButton:GAMEPLAY_CHECKBOX {
int ypix 40
int xpix 200
stringtable {
string string0 "str_ldl_Left_Handed_Mouse_Off"
string string1 "str_ldl_Left_Handed_Mouse_On"
}
}
}
$ |
I think it may be possible to add diplomacy buttons/options, triggered perhaps with Slic, as well as, like the above, gameplay options (like that option Markos wanted--another option aside from, in the option window, Bloodlust on/off and Pollution/on off--when he wanted to conquer the world but not his ally...an "Allied Victory on/off" button). O the possibilities!
How about an END ALLIANCE option?! 
Here's something quite neat from "civ3.ldl":
(wonder why it's called "civ3" here...?)
quote:
#######################################
# File: C:\civ3_project\civ3_data\english\uidata\layouts\c
iv3.ldl
# Last Access: Mon Jun 01 13:01:30 1998
#######################################
##-----------------------------------##
## Imports ##
##-----------------------------------##
import "font1.ldl"
import "font2.ldl"
import "font3.ldl"
import "font4.ldl"
import "font5.ldl"
import "font6.ldl"
import "ctp_template.ldl"
import "buttonbank.ldl"
import "controlpanel.ldl"
import "tradescreen.ldl"
import "ancient.ldl"
import "cityview.ldl"
import "cvscreen.ldl"
import "citystatus.ldl"
import "queuewin.ldl"
import "unitstatus.ldl"
import "greatlibrary.ldl"
import "messagebox.ldl"
import "helptile.ldl"
import "diplomacy.ldl"
import "fliwindow.ldl"
import "science.ldl"
import "statswindow.ldl"
import "spnewgame.ldl"
import "scenario.ldl"
import "custommap.ldl"
import "options.ldl"
import "graphics.ldl"
import "sound.ldl"
import "gameplayoptions.ldl"
import "loadsave.ldl"
|
I wonder...
------------------
"There can be no maximum of creation without a concomitant maximum of destruction, no supreme good without supreme evil"--Heller, paraphrasing Nietzsche.
"The more passion for the argument, the less evidence for it"--Russel.
"I *may* have solved some of the problem with specialists tonight. Then again, I may have screwed things up- I don't know. If that happens, I won't know whether to laugh, cry, or both. God, I'm starting to sound like Nordicus (the horror!). "--Wes Whitaker, during AAIPs testing.
[This message has been edited by Nordicus (edited January 15, 2000).]
[This message has been edited by Nordicus (edited January 19, 2000).]
|
|
|  |
 |
|  |
 |
|
Dreamer
|
|
Singapore
Dec 1999 time: 05:13
|
|
Bad news, the Attract() function is not used to call the UI components in those idl files.
If you have played the tutorial scenario, CTP uses the Attract() to create a blinking green box around the UI components to capture the player attention on certain buttons or screen controls while the tutorial explained their features.
Guess we'll have to find other ways to call these UI components.
|
|
|  |
 |
|  |
 |
|
skorpion59
|
|
Tulsa, Oklahoma, USA
May 1999 time: 23:13
|
|
Slamp,
Here is the SLIC code which is relevant:
Trigger 'name' on "UI Component Name" when (expression) {
commands
}
This is a special format trigger for triggering by UI components. It behaves in the same way as the normal format, except that it is only evaluated when the UI component is used. The name follows the same rules as for message boxes.
The body of the trigger is executed only when the expression is true (not equal to 0).
VOID Attract(ldlname)
Draw a highlight box around the named UI component.
VOID DisableClose()(Messages only)
Disallow closing this message from the UI.
So it appears it might be possible to actually do something with this.
------------------
Don, Apolyton Junkie
|
|
|  |
 |
|
gemini
|
|
Bump************
Has anyone had any luck with calling ui components???
I am trying to think of a way to have a scenario screen with a custom picture (kinda like in a civ2 scenario)pop up on the first turn. Is there any way to do this.
------------------
Gemini
|
|
|  |
 |
|
gemini
|
|
Thanks, I'll take a look see.
------------------
Gemini
|
|
|  |
 |
|
gemini
|
|
I looked in powerslic's and as far as I can see only message icons have been added, I couldn't find anything pertaining to adding a background image to a message box. Are you sure this can be done???
------------------
Gemini
|
|
|  |
 |
|  |
 |
|  |
 |
|
gemini
|
|
Hey, using the throne room is working out almost perfectly, the one thing that is causing me some frustration is that at first I wanted the background bigger but after trying and trying I think I am going to give up. I partialy succeded though. I got the background to go as big as I wanted but, there was a border that I could not resize.
I'm pretty sure it was this line in the throne.ldl file that is mucking it up.
code:
## Chromakeyed border with raised exit button.
BorderImage {
string image0 "tbb000.tga"
string imagebltflag "chromakey"
int xpix 0
int ypix 0
int widthpix 640
int heightpix 480
}
This border picture I could not resize "tbb000.tga".
I tried to replace it but all I got was a crash, I tried to omit it but crash again, tried a whole bunch of different things but crash again.
Oh well, I guess it'll have to stay 640x480 for the background pic.
But I do have a question for you or anyone. Can I add a scroll bar to the side, that's about the only work around I could think of to doing what I want.
I honestly haven't a clue how to do that. If I am right I think it may be this that has to be added.
code:
rangery {
int widthpix 15
int heigthpix 15
string type "scroller"
string orientation "vertical"
string pattern "upba6417.tga"
incy {
int widthpix 15
int heightpix 15
string pattern "upba6417.tga"
}
decy {
int widthpix 15
int heightpix 15
string pattern "upba6417.tga"
}
}
Well, I will try it tommorrow, but I was hoping maybe someone else has tried this and can save me some hassle by giving some advice.
------------------
Gemini
|
|
|  |
 |
|  |
 |
|
Martin the Dane
|
 |
Aarhus, Denmark
Feb 2000 time: 06:13
|
|
Hi gemini,
Well I'm back, haven't been in here for a while.
quote:

Originally posted by gemini on 08-16-2000 02:30 AM
... there was a border that I could not resize.
 |
I just looked at the problem and it seams that unlike background images the images pasted on the background are not tiled, so changing the size of the image in the .ldl does nothing.
You are right about the source of the problem but what you have to do is either out-comment the whole block like this:
code:
## Chromakeyed border with raised exit button.
## BorderImage {
## string image0 "tbb000.tga"
## string imagebltflag "chromakey"
## int xpix 0
## int ypix 0
## int widthpix 640
## int heightpix 480
## }
or make your own border image. This however requires the use of transparency, and I have no clue as to which color to use.
quote:

This border picture I could not resize "tbb000.tga".
I tried to replace it but all I got was a crash, I tried to omit it but crash again, tried a whole bunch of different things but crash again.
 |
How did you try that?
You should never use the same file name as the internal reference in the original, as they are sometime used in other places where you don't want to change anything.
Just to try, I replaced "tbb000.tga" with "mbv_Upba7506.tga" (one of the images in screenmod 2.0) and it worked fine.
There is one issue with replacing .tga files: you have to chose the same pallet and internal format as used by civ-ctp. The easy way to do that is to make a copy of one of the .tga files already there and resize and rename it and then edit it to suite your purpose.
I have played around with the "Throneroom.ldl" but could not make a scrollbox, no matter what I did it never showed up. 
If you find a way let me know.
Martin the Dane
|
|
|  |
All times are GMT. The time now is 05:13. Apolyton Time is 00:13. |
top of page
|
|
|
Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is ON
vB code is ON
Smilies are ON
[IMG] code is ON
|
|
|
|
|
|