mirror of
https://github.com/ReactionQuake3/reaction.git
synced 2025-03-13 22:22:13 +00:00
Changed color "lerping" for focused items a bit
This commit is contained in:
parent
c7afd3ea60
commit
b12479d664
2 changed files with 65 additions and 24 deletions
|
@ -6,6 +6,32 @@
|
|||
--------------------Configuration: ui - Win32 Release TA--------------------
|
||||
</h3>
|
||||
<h3>Command Lines</h3>
|
||||
Creating temporary file "D:\DOCUME~1\Andrei\LOCALS~1\Temp\RSP114.tmp" with contents
|
||||
[
|
||||
/nologo /G6 /ML /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "UI_EXPORTS" /Fp"Release_TA/ta_ui.pch" /YX /Fo"Release_TA/" /Fd"Release_TA/" /FD /c
|
||||
"C:\Games\Quake3\rq3source\reaction\ta_ui\ui_shared.c"
|
||||
]
|
||||
Creating command line "cl.exe @D:\DOCUME~1\Andrei\LOCALS~1\Temp\RSP114.tmp"
|
||||
Creating temporary file "D:\DOCUME~1\Andrei\LOCALS~1\Temp\RSP115.tmp" with contents
|
||||
[
|
||||
/nologo /base:"0x40000000" /dll /incremental:no /pdb:"Release_TA/uix86.pdb" /map:"Release_TA/uix86.map" /machine:I386 /def:".\ui.def" /out:"../Release/uix86.dll" /implib:"Release_TA/uix86.lib"
|
||||
.\Release_TA\bg_misc.obj
|
||||
.\Release_TA\q_math.obj
|
||||
.\Release_TA\q_shared.obj
|
||||
.\Release_TA\ui_atoms.obj
|
||||
.\Release_TA\ui_gameinfo.obj
|
||||
.\Release_TA\ui_main.obj
|
||||
.\Release_TA\ui_players.obj
|
||||
.\Release_TA\ui_shared.obj
|
||||
.\Release_TA\ui_syscalls.obj
|
||||
.\Release_TA\ui_util.obj
|
||||
]
|
||||
Creating command line "link.exe @D:\DOCUME~1\Andrei\LOCALS~1\Temp\RSP115.tmp"
|
||||
<h3>Output Window</h3>
|
||||
Compiling...
|
||||
ui_shared.c
|
||||
Linking...
|
||||
Creating library Release_TA/uix86.lib and object Release_TA/uix86.exp
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.19 2002/06/08 11:43:31 makro
|
||||
// Changed color "lerping" for focused items a bit
|
||||
//
|
||||
// Revision 1.18 2002/06/05 19:17:07 makro
|
||||
// Squashed some bugs :)
|
||||
//
|
||||
|
@ -3338,10 +3341,12 @@ void Item_TextColor(itemDef_t *item, vec4_t *newColor) {
|
|||
Fade(&item->window.flags, &item->window.foreColor[3], parent->fadeClamp, &item->window.nextTime, parent->fadeCycle, qtrue, parent->fadeAmount);
|
||||
|
||||
if (item->window.flags & WINDOW_HASFOCUS) {
|
||||
lowLight[0] = 0.8 * parent->focusColor[0];
|
||||
lowLight[1] = 0.8 * parent->focusColor[1];
|
||||
lowLight[2] = 0.8 * parent->focusColor[2];
|
||||
lowLight[3] = 0.8 * parent->focusColor[3];
|
||||
//Makro - changed to fade from normal text color to focus color
|
||||
//lowLight[0] = 0.8 * parent->focusColor[0];
|
||||
//lowLight[1] = 0.8 * parent->focusColor[1];
|
||||
//lowLight[2] = 0.8 * parent->focusColor[2];
|
||||
//lowLight[3] = 0.8 * parent->focusColor[3];
|
||||
memcpy(lowLight, &item->window.foreColor, sizeof(vec4_t));
|
||||
LerpColor(parent->focusColor,lowLight,*newColor,0.5+0.5*sin(DC->realTime / PULSE_DIVISOR));
|
||||
} else if (item->textStyle == ITEM_TEXTSTYLE_BLINK && !((DC->realTime/BLINK_DIVISOR) & 1)) {
|
||||
lowLight[0] = 0.8 * item->window.foreColor[0];
|
||||
|
@ -3577,10 +3582,12 @@ void Item_TextField_Paint(itemDef_t *item) {
|
|||
parent = (menuDef_t*)item->parent;
|
||||
|
||||
if (item->window.flags & WINDOW_HASFOCUS) {
|
||||
lowLight[0] = 0.8 * parent->focusColor[0];
|
||||
lowLight[1] = 0.8 * parent->focusColor[1];
|
||||
lowLight[2] = 0.8 * parent->focusColor[2];
|
||||
lowLight[3] = 0.8 * parent->focusColor[3];
|
||||
//Makro - changed to fade from normal text color to focus color
|
||||
//lowLight[0] = 0.8 * parent->focusColor[0];
|
||||
//lowLight[1] = 0.8 * parent->focusColor[1];
|
||||
//lowLight[2] = 0.8 * parent->focusColor[2];
|
||||
//lowLight[3] = 0.8 * parent->focusColor[3];
|
||||
memcpy(lowLight, &item->window.foreColor, sizeof(vec4_t));
|
||||
LerpColor(parent->focusColor,lowLight,newColor,0.5+0.5*sin(DC->realTime / PULSE_DIVISOR));
|
||||
} else {
|
||||
memcpy(&newColor, &item->window.foreColor, sizeof(vec4_t));
|
||||
|
@ -3604,10 +3611,12 @@ void Item_YesNo_Paint(itemDef_t *item) {
|
|||
value = (item->cvar) ? DC->getCVarValue(item->cvar) : 0;
|
||||
|
||||
if (item->window.flags & WINDOW_HASFOCUS) {
|
||||
lowLight[0] = 0.8 * parent->focusColor[0];
|
||||
lowLight[1] = 0.8 * parent->focusColor[1];
|
||||
lowLight[2] = 0.8 * parent->focusColor[2];
|
||||
lowLight[3] = 0.8 * parent->focusColor[3];
|
||||
//Makro - changed to fade from normal text color to focus color
|
||||
//lowLight[0] = 0.8 * parent->focusColor[0];
|
||||
//lowLight[1] = 0.8 * parent->focusColor[1];
|
||||
//lowLight[2] = 0.8 * parent->focusColor[2];
|
||||
//lowLight[3] = 0.8 * parent->focusColor[3];
|
||||
memcpy(lowLight, &item->window.foreColor, sizeof(vec4_t));
|
||||
LerpColor(parent->focusColor,lowLight,newColor,0.5+0.5*sin(DC->realTime / PULSE_DIVISOR));
|
||||
} else {
|
||||
memcpy(&newColor, &item->window.foreColor, sizeof(vec4_t));
|
||||
|
@ -3627,10 +3636,12 @@ void Item_Multi_Paint(itemDef_t *item) {
|
|||
menuDef_t *parent = (menuDef_t*)item->parent;
|
||||
|
||||
if (item->window.flags & WINDOW_HASFOCUS) {
|
||||
lowLight[0] = 0.8 * parent->focusColor[0];
|
||||
lowLight[1] = 0.8 * parent->focusColor[1];
|
||||
lowLight[2] = 0.8 * parent->focusColor[2];
|
||||
lowLight[3] = 0.8 * parent->focusColor[3];
|
||||
//Makro - changed to fade from normal text color to focus color
|
||||
//lowLight[0] = 0.8 * parent->focusColor[0];
|
||||
//lowLight[1] = 0.8 * parent->focusColor[1];
|
||||
//lowLight[2] = 0.8 * parent->focusColor[2];
|
||||
//lowLight[3] = 0.8 * parent->focusColor[3];
|
||||
memcpy(lowLight, &item->window.foreColor, sizeof(vec4_t));
|
||||
LerpColor(parent->focusColor,lowLight,newColor,0.5+0.5*sin(DC->realTime / PULSE_DIVISOR));
|
||||
} else {
|
||||
memcpy(&newColor, &item->window.foreColor, sizeof(vec4_t));
|
||||
|
@ -3919,10 +3930,12 @@ void Item_Slider_Paint(itemDef_t *item) {
|
|||
value = (item->cvar) ? DC->getCVarValue(item->cvar) : 0;
|
||||
|
||||
if (item->window.flags & WINDOW_HASFOCUS) {
|
||||
lowLight[0] = 0.8 * parent->focusColor[0];
|
||||
lowLight[1] = 0.8 * parent->focusColor[1];
|
||||
lowLight[2] = 0.8 * parent->focusColor[2];
|
||||
lowLight[3] = 0.8 * parent->focusColor[3];
|
||||
//Makro - changed to fade from normal text color to focus color
|
||||
//lowLight[0] = 0.8 * parent->focusColor[0];
|
||||
//lowLight[1] = 0.8 * parent->focusColor[1];
|
||||
//lowLight[2] = 0.8 * parent->focusColor[2];
|
||||
//lowLight[3] = 0.8 * parent->focusColor[3];
|
||||
memcpy(lowLight, &item->window.foreColor, sizeof(vec4_t));
|
||||
LerpColor(parent->focusColor,lowLight,newColor,0.5+0.5*sin(DC->realTime / PULSE_DIVISOR));
|
||||
} else {
|
||||
memcpy(&newColor, &item->window.foreColor, sizeof(vec4_t));
|
||||
|
@ -4398,10 +4411,12 @@ void Item_OwnerDraw_Paint(itemDef_t *item) {
|
|||
}
|
||||
|
||||
if (item->window.flags & WINDOW_HASFOCUS) {
|
||||
lowLight[0] = 0.8 * parent->focusColor[0];
|
||||
lowLight[1] = 0.8 * parent->focusColor[1];
|
||||
lowLight[2] = 0.8 * parent->focusColor[2];
|
||||
lowLight[3] = 0.8 * parent->focusColor[3];
|
||||
//Makro - changed to fade from normal text color to focus color
|
||||
//lowLight[0] = 0.8 * parent->focusColor[0];
|
||||
//lowLight[1] = 0.8 * parent->focusColor[1];
|
||||
//lowLight[2] = 0.8 * parent->focusColor[2];
|
||||
//lowLight[3] = 0.8 * parent->focusColor[3];
|
||||
memcpy(lowLight, &item->window.foreColor, sizeof(vec4_t));
|
||||
LerpColor(parent->focusColor,lowLight,color,0.5+0.5*sin(DC->realTime / PULSE_DIVISOR));
|
||||
} else if (item->textStyle == ITEM_TEXTSTYLE_BLINK && !((DC->realTime/BLINK_DIVISOR) & 1)) {
|
||||
lowLight[0] = 0.8 * item->window.foreColor[0];
|
||||
|
|
Loading…
Reference in a new issue