News UnrealEd Files Mods FragBU Liandri Archives
BeyondUnreal Forums

Go Back   BeyondUnreal Forums > Unreal Development > Coding

Reply
 
Thread Tools Display Modes
Old 11th Oct 2003, 06:14 PM   #1
JamesKilton
UA Coder
 
JamesKilton's Avatar
 
Join Date: Oct. 6th, 2002
Location: Everywhere and Nowhere
Posts: 210
Reading a static array from a config file

Ok, so I have an ini file, AnnihilationBuildMenus.ini where it lists the needed arrays.

Then I have this:

Code:
class UaBuildable extends Pawn
     config(AnnihilationBuildMenus);
{
}

class UaStructure extends UaBuildable
{
     var config class<UaUnit> CanBuild[35]; 
}

class UaUnit extends UaBuildable
{
     var config class<UaStructure> CanBuild[35]; 
}
Now, in my Interaction, I display the values of these arrays 7 elements at a time. My problem is that sometimes the first 8 or so values load correctly, sometimes only the first loads correctly, and whatever in-between. This will probably work fine if I changed to a dynamic array, but I might have to check these arrays between the server and client, so really want to stay with static. Has anyone come across this problem?

Snippet from AnnihilationBuildMenus.ini:
Code:
[Annihilation.UaArmKBotLab]
CanBuild[0]=class'Annihilation.UaArmConstructionKBot'
CanBuild[1]=class'Annihilation.UaArmPeewee'
//CanBuild[2]=class'Annihilation.UaArmRocko'
//CanBuild[3]=class'Annihilation.UaArmHammer'
CanBuild[4]=class'Annihilation.UaArmJethro'
//CanBuild[5]=class'Annihilation.UaArmWarrior'
//CanBuild[6]=class'Annihilation.UaArmFlea'
UaArmKBotLab extends UaStructure

I'm stumped.

Note: I have logged the arrays themselves, and for the Arm KBot Lab above, the log shows that only CanBuild[0] was loaded, everything else is None.

Last edited by JamesKilton; 11th Oct 2003 at 07:02 PM.
JamesKilton is offline   Reply With Quote
Old 12th Oct 2003, 03:28 AM   #2
elmuerte
Master of Science
 
elmuerte's Avatar
 
Join Date: Jan. 25th, 2000
Location: the Netherlands
Posts: 1,936
I think it's better to check the array via a replicated function and direct the array, since all entries have to be replicated and that's not very efficient.

As for this problem, I have no idea
elmuerte is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 02:56 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.

Copyright ©1998 - 2012, BeyondUnreal, Inc.
Privacy Policy | Terms of Use
Bandwidth provided by AtomicGamer