Interface improvements... 8 artifacts

  • Two Factor Authentication is now available on BeyondUnreal Forums. To configure it, visit your Profile and look for the "Two Step Verification" option on the left side. We can send codes via email (may be slower) or you can set up any TOTP Authenticator app on your phone (Authy, Google Authenticator, etc) to deliver codes. It is highly recommended that you configure this to keep your account safe.
Status
Not open for further replies.

Dandeloreon1984

CXP Director
Jan 31, 2004
1,303
0
0
Interface improvements... 8 artifacts, and improved energy lay out.

I am currently working on making the hud support 8 artifacts, but i need assistance in programming the hud...

Here is what i have found so far... the following files are relevant to the artifact placement in the hud...

U2.U2PlayerController

UIScripts\uiu2hud,ui
UIScripts\lowerhud.ui

I can post updates on this, but it will take a while to implement 8 artifacts with one person alone... I will post small updates on this subject as need arises.
 
Last edited:

-eVo:ApHeX-

XMP-Assault Creator
Feb 3, 2004
50
0
0
37
Location Location
www.gandy-gfx.co.uk
It's all relevant in LowerHUD.ui

Code:
[LeftFrame]
Class=FixedSizeContainer
Component=LowerHudTextures
Component=StaminaBar
Component=LargeHexContainer_Left
Component=ArtifactContainer:0/71/-60
Component=ArtifactContainer:1/89/-30
Component=ArtifactContainer:2/107/-60
Component=ArtifactContainer:3/125/-30
Component=SpeedHolder
Component=PlayerClassImage
Align=HardLeft,HardBottom
Location=10,-14

I'm pretty sure changing it to

Code:
[LeftFrame]
Class=FixedSizeContainer
Component=LowerHudTextures
Component=StaminaBar
Component=LargeHexContainer_Left
Component=ArtifactContainer:0/71/-60
Component=ArtifactContainer:1/89/-30
Component=ArtifactContainer:2/107/-60
Component=ArtifactContainer:3/125/-30
Component=ArtifactContainer:4/143/-60
Component=ArtifactContainer:5/161/-30
Component=ArtifactContainer:6/179/-60
Component=ArtifactContainer:7/197/-30
Component=SpeedHolder
Component=PlayerClassImage
Align=HardLeft,HardBottom
Location=10,-14

Dunno I haven't checked but it's worth a try eh? :)
I'll go try it out and report back
 

-eVo:ApHeX-

XMP-Assault Creator
Feb 3, 2004
50
0
0
37
Location Location
www.gandy-gfx.co.uk
Code:
function interface bool HasArtifact4()	 { local Artifact A; if( PlayerReplicationInfo? ) A = Artifact( PlayerReplicationInfo.HasArtifact ); return( A? && A.ID == 4 ); }
function interface bool HasArtifact5()	 { local Artifact A; if( PlayerReplicationInfo? ) A = Artifact( PlayerReplicationInfo.HasArtifact ); return( A? && A.ID == 5 ); }
function interface bool HasArtifact6()	 { local Artifact A; if( PlayerReplicationInfo? ) A = Artifact( PlayerReplicationInfo.HasArtifact ); return( A? && A.ID == 6 ); }
function interface bool HasArtifact7()	 { local Artifact A; if( PlayerReplicationInfo? ) A = Artifact( PlayerReplicationInfo.HasArtifact ); return( A? && A.ID == 7 ); }

That should help, It's all off the top of my head and i could be miles away but add that to the artifact scoreboard in U2PlayerController and it should help draw them, but ur gonna need to use a new playercontroller :)
 

Dandeloreon1984

CXP Director
Jan 31, 2004
1,303
0
0
Here is the code that is part of u2playercontroller.uc

//-----------------------------------------------------------------------------
// artifact score board

function interface bool HasArtifact0() { local Artifact A; if( PlayerReplicationInfo? ) A = Artifact( PlayerReplicationInfo.HasArtifact ); return( A? && A.ID == 0 ); }
function interface bool HasArtifact1() { local Artifact A; if( PlayerReplicationInfo? ) A = Artifact( PlayerReplicationInfo.HasArtifact ); return( A? && A.ID == 1 ); }
function interface bool HasArtifact2() { local Artifact A; if( PlayerReplicationInfo? ) A = Artifact( PlayerReplicationInfo.HasArtifact ); return( A? && A.ID == 2 ); }
function interface bool HasArtifact3() { local Artifact A; if( PlayerReplicationInfo? ) A = Artifact( PlayerReplicationInfo.HasArtifact ); return( A? && A.ID == 3 ); }
 

-eVo:ApHeX-

XMP-Assault Creator
Feb 3, 2004
50
0
0
37
Location Location
www.gandy-gfx.co.uk
Nothing of interest in there, just try what i said and extend U2PlayerController and it should work, i think it just doesnt return the info to the hud.

which means your gonna have to make your own gametype...and make multiple gametypes supported, which takes days (believe me i been there and done it)

You can easily run ucc server XMP-8Artifacts?game=Eight.ArtifactsGame
but you won't be able to configure anything using the ingame HUD.

When a public beta is released of my mod i'll release the code on how to get this running (pointless me trying to keep it secret people will get at it no matter what) gotta iron out some bugs
 
Last edited:

Dandeloreon1984

CXP Director
Jan 31, 2004
1,303
0
0
you may have been first, but now we need a mutator to replace the u2controller, and still keep the gameplay the same...

I believe that there is a mod needed to be applied to the u2xmp's artifact/icon node.

Now here is what i think the new hud corner should like...
 

Attachments

  • NEWHUD.bmp
    175.3 KB · Views: 5

-eVo:ApHeX-

XMP-Assault Creator
Feb 3, 2004
50
0
0
37
Location Location
www.gandy-gfx.co.uk
the gameplay would be kept the same anyways :x

I'll help you along the way and hopefully get this working, as I say i've given you (afaik) all the neccesary info to get this working, but perhaps i am wrong.

One problem your gonna run into is getting this working as a proper gametype, for a start your gonna need to code a seperate UI for each gametype, i've got the code for A gametype-dependent hud, so with a bit of luck it shouldn't interfere too much.
 

Dandeloreon1984

CXP Director
Jan 31, 2004
1,303
0
0
-eVo:ApHeX- said:
I don't even see a photoshop image there :|
it it's extension is .psp then you should change it to something the Ie can actually read like .gif since it won't affect the quality and you'll have a small file
The image is in a jpeg format.
Loqa said:
Perhaps this bit of code could be of use?
thank you for the little bit of code.

I will post the image again.

I will also post a new unage unvolving an improved energy lay out when there is ten energy sources...
 

Attachments

  • NEWHUDsm.jpg
    NEWHUDsm.jpg
    7.4 KB · Views: 21
  • NEw_LWR_RIGHT.jpg
    NEw_LWR_RIGHT.jpg
    10.4 KB · Views: 15
Last edited:

Dandeloreon1984

CXP Director
Jan 31, 2004
1,303
0
0
//-----------------------------------------------------------------------------

function ArtifactCarryTimer()
{
/* local int i;

DMTN("ArtifactCarryTimer -- time:" @ Level.TimeSeconds );
for( i=0; i < ArtInfo.Length; i++ )
{
DMTN("Artifact#:" @ i @ "picked up time:" @ ArtInfo.PickedUpTime );
if( ArtInfo.PickedUpTime > 0.0 &&
Level.TimeSeconds - ArtInfo.PickedUpTime > MaxArtifactCarryTime )
{
NotifyArtifactSentHome( ArtInfo.ID, None );
}
}
*/
}

//-----------------------------------------------------------------------------

function InitArtifactScoreboard()
{
local int i;
for( i=0; i < ArtInfo.Length; i++ )
UpdateArtifactScore(i);
}

//-----------------------------------------------------------------------------

function UpdateArtifactScore( int ArtIndex )
{
local EArtifactState AState;
local class<Artifact> AType;
local int ATeam;
local GameReplicationInfo GRI;

GRI = GameReplicationInfo;
if( GRI == None )
return;

AState = ArtInfo[ArtIndex].State;
AType = ArtInfo[ArtIndex].Type;
ATeam = ArtInfo[ArtIndex].Team;

switch( ArtIndex )
{
case 0:

// clear flags
GRI.bArtBG_Slot0_Red_Dropped = false; GRI.bArtBG_Slot0_Red_Stored = false; GRI.bArtBG_Slot0_Red_Carried = false;
GRI.bArtBG_Slot0_Blue_Dropped = false; GRI.bArtBG_Slot0_Blue_Stored = false; GRI.bArtBG_Slot0_Blue_Carried = false;
GRI.bArt_Defense_Slot0 = false;
GRI.bArt_Health_Slot0 = false;
GRI.bArt_Shield_Slot0 = false;
GRI.bArt_Skill_Slot0 = false;
GRI.bArt_Stamina_Slot0 = false;
GRI.bArt_WeaponDamage_Slot0 = false;

// artifact background
switch( ATeam )
{
case 0:
if( AState == AS_Stored ) GRI.bArtBG_Slot0_Red_Stored = true;
else if( AState == AS_Carried ) GRI.bArtBG_Slot0_Red_Carried = true;
else if( AState == AS_Dropped ) GRI.bArtBG_Slot0_Red_Dropped = true;
break;

case 1:
if( AState == AS_Stored ) GRI.bArtBG_Slot0_Blue_Stored = true;
else if( AState == AS_Carried ) GRI.bArtBG_Slot0_Blue_Carried = true;
else if( AState == AS_Dropped ) GRI.bArtBG_Slot0_Blue_Dropped = true;
break;

default:
Warn("Artifact has unknown team:" @ ATeam );
}

// artifact icon
if( AType == class'ArtifactInvDefense' ) GRI.bArt_Defense_Slot0 = true;
else if( AType == class'ArtifactInvHealth' ) GRI.bArt_Health_Slot0 = true;
else if( AType == class'ArtifactInvShield' ) GRI.bArt_Shield_Slot0 = true;
else if( AType == class'ArtifactInvSkill' ) GRI.bArt_Skill_Slot0 = true;
else if( AType == class'ArtifactInvStamina' ) GRI.bArt_Stamina_Slot0 = true;
else if( AType == class'ArtifactInvWeaponDamage' ) GRI.bArt_WeaponDamage_Slot0 = true;

break;

case 1:

// clear flags
GRI.bArtBG_Slot1_Red_Dropped = false; GRI.bArtBG_Slot1_Red_Stored = false; GRI.bArtBG_Slot1_Red_Carried = false;
GRI.bArtBG_Slot1_Blue_Dropped = false; GRI.bArtBG_Slot1_Blue_Stored = false; GRI.bArtBG_Slot1_Blue_Carried = false;
GRI.bArt_Defense_Slot1 = false;
GRI.bArt_Health_Slot1 = false;
GRI.bArt_Shield_Slot1 = false;
GRI.bArt_Skill_Slot1 = false;
GRI.bArt_Stamina_Slot1 = false;
GRI.bArt_WeaponDamage_Slot1 = false;

// artifact background
switch( ATeam )
{
case 0:
if( AState == AS_Stored ) GRI.bArtBG_Slot1_Red_Stored = true;
else if( AState == AS_Carried ) GRI.bArtBG_Slot1_Red_Carried = true;
else if( AState == AS_Dropped ) GRI.bArtBG_Slot1_Red_Dropped = true;
break;

case 1:
if( AState == AS_Stored ) GRI.bArtBG_Slot1_Blue_Stored = true;
else if( AState == AS_Carried ) GRI.bArtBG_Slot1_Blue_Carried = true;
else if( AState == AS_Dropped ) GRI.bArtBG_Slot1_Blue_Dropped = true;
break;

default:
Warn("Artifact has unknown team:" @ ATeam );
}

// artifact icon
if( AType == class'ArtifactInvDefense' ) GRI.bArt_Defense_Slot1 = true;
else if( AType == class'ArtifactInvHealth' ) GRI.bArt_Health_Slot1 = true;
else if( AType == class'ArtifactInvShield' ) GRI.bArt_Shield_Slot1 = true;
else if( AType == class'ArtifactInvSkill' ) GRI.bArt_Skill_Slot1 = true;
else if( AType == class'ArtifactInvStamina' ) GRI.bArt_Stamina_Slot1 = true;
else if( AType == class'ArtifactInvWeaponDamage' ) GRI.bArt_WeaponDamage_Slot1 = true;

break;

case 2:

// clear flags
GRI.bArtBG_Slot2_Red_Dropped = false; GRI.bArtBG_Slot2_Red_Stored = false; GRI.bArtBG_Slot2_Red_Carried = false;
GRI.bArtBG_Slot2_Blue_Dropped = false; GRI.bArtBG_Slot2_Blue_Stored = false; GRI.bArtBG_Slot2_Blue_Carried = false;
GRI.bArt_Defense_Slot2 = false;
GRI.bArt_Health_Slot2 = false;
GRI.bArt_Shield_Slot2 = false;
GRI.bArt_Skill_Slot2 = false;
GRI.bArt_Stamina_Slot2 = false;
GRI.bArt_WeaponDamage_Slot2 = false;

// artifact background
switch( ATeam )
{
case 0:
if( AState == AS_Stored ) GRI.bArtBG_Slot2_Red_Stored = true;
else if( AState == AS_Carried ) GRI.bArtBG_Slot2_Red_Carried = true;
else if( AState == AS_Dropped ) GRI.bArtBG_Slot2_Red_Dropped = true;
break;

case 1:
if( AState == AS_Stored ) GRI.bArtBG_Slot2_Blue_Stored = true;
else if( AState == AS_Carried ) GRI.bArtBG_Slot2_Blue_Carried = true;
else if( AState == AS_Dropped ) GRI.bArtBG_Slot2_Blue_Dropped = true;
break;

default:
Warn("Artifact has unknown team:" @ ATeam );
}

// artifact icon
if( AType == class'ArtifactInvDefense' ) GRI.bArt_Defense_Slot2 = true;
else if( AType == class'ArtifactInvHealth' ) GRI.bArt_Health_Slot2 = true;
else if( AType == class'ArtifactInvShield' ) GRI.bArt_Shield_Slot2 = true;
else if( AType == class'ArtifactInvSkill' ) GRI.bArt_Skill_Slot2 = true;
else if( AType == class'ArtifactInvStamina' ) GRI.bArt_Stamina_Slot2 = true;
else if( AType == class'ArtifactInvWeaponDamage' ) GRI.bArt_WeaponDamage_Slot2 = true;

break;

case 3:

// clear flags
GRI.bArtBG_Slot3_Red_Dropped = false; GRI.bArtBG_Slot3_Red_Stored = false; GRI.bArtBG_Slot3_Red_Carried = false;
GRI.bArtBG_Slot3_Blue_Dropped = false; GRI.bArtBG_Slot3_Blue_Stored = false; GRI.bArtBG_Slot3_Blue_Carried = false;
GRI.bArt_Defense_Slot3 = false;
GRI.bArt_Health_Slot3 = false;
GRI.bArt_Shield_Slot3 = false;
GRI.bArt_Skill_Slot3 = false;
GRI.bArt_Stamina_Slot3 = false;
GRI.bArt_WeaponDamage_Slot3 = false;

// artifact background
switch( ATeam )
{
case 0:
if( AState == AS_Stored ) GRI.bArtBG_Slot3_Red_Stored = true;
else if( AState == AS_Carried ) GRI.bArtBG_Slot3_Red_Carried = true;
else if( AState == AS_Dropped ) GRI.bArtBG_Slot3_Red_Dropped = true;
break;

case 1:
if( AState == AS_Stored ) GRI.bArtBG_Slot3_Blue_Stored = true;
else if( AState == AS_Carried ) GRI.bArtBG_Slot3_Blue_Carried = true;
else if( AState == AS_Dropped ) GRI.bArtBG_Slot3_Blue_Dropped = true;
break;

default:
Warn("Artifact has unknown team:" @ ATeam );
}

// artifact icon
if( AType == class'ArtifactInvDefense' ) GRI.bArt_Defense_Slot3 = true;
else if( AType == class'ArtifactInvHealth' ) GRI.bArt_Health_Slot3 = true;
else if( AType == class'ArtifactInvShield' ) GRI.bArt_Shield_Slot3 = true;
else if( AType == class'ArtifactInvSkill' ) GRI.bArt_Skill_Slot3 = true;
else if( AType == class'ArtifactInvStamina' ) GRI.bArt_Stamina_Slot3 = true;
else if( AType == class'ArtifactInvWeaponDamage' ) GRI.bArt_WeaponDamage_Slot3 = true;

break;

default:
Warn("Artifact index out of scoreboard range:" @ ArtIndex );
}
}


The above lines are the culprit, an update is needed...

this is part of the xmpgame.uc
 
Status
Not open for further replies.