NewsUnrealEdFilesModsFragBULiandri Archives
BeyondUnreal Forums

Go Back   BeyondUnreal Forums > Unreal Development > Coding

Reply
 
Thread Tools Display Modes
Old 17th Dec 2005, 04:39 PM   #1
Call me Erdrik
Arch Mage
 
Call me Erdrik's Avatar
 
Join Date: Nov. 24th, 1999
Location: Spring Hill, FL, USA
Posts: 334
UCC compiling error...

Im having a strange problem trying to compile my mod with UCC...
the file in question 'SH_AScouts.uc' has many calls to the function
Quote:
simulated function SetSystemsPwrDrain()
'SH_AScouts.uc' is a subclass of 'SH_ARaceShips.uc' which in turn is a subclass of 'SH_Ships.uc', which clearly contains the called function.

This is the error in the UCC log:
Quote:
Error: C:\Program Files\UT2004\Ships\Classes\SH_AScouts.uc(589) : Error, 'SetSystemsPwrDrain': Bad command or expression
The only thing I can think of ( and I'm really guessing here ) is that the name of the .uc files maybe determines the order in which they are compiled and that 'SH_AScouts.uc' is being compiled before 'SH_Ships.uc'. But that dosen't seem to make any sense to me...

does anyone have any clue as to what is wrong? If you need any more info post what you need and Ill post it up...
__________________
Call me Erdrik
-hvErdrik
-Erdrik

*PIMP*
DarkMagic
Boycott Fox!!! Down with the Evil Overlords!
Call me Erdrik is offline   Reply With Quote
Old 17th Dec 2005, 05:16 PM   #2
Angel_Mapper
Noblesse Oblige
 
Angel_Mapper's Avatar
 
Join Date: Jun. 17th, 2001
Location: Cape Suzette
Posts: 3,524
I'd need to see the code (SH_AScouts line 589).
Angel_Mapper is offline   Reply With Quote
Old 17th Dec 2005, 06:56 PM   #3
Call me Erdrik
Arch Mage
 
Call me Erdrik's Avatar
 
Join Date: Nov. 24th, 1999
Location: Spring Hill, FL, USA
Posts: 334
Code:
Auto State Running
{
...
	Function Timer()
	{
	...
		//===================================================
		// MainHull.Operations.HyperCharging PowerManagment
		//===================================================
			HypChrg++;
			If (HypChrg >= 1000)
			{   
				//log("bHypChrged = True");
				HypChrg = 1000;
				bHypChrged = True;
			}
			/*
			Power:
			Each Tick, Systems will check if there is enough energy to run them
			in order of priority. If not they woll be turned off. Running systems
			WILL NOT ACTUALY DRAIN POWER!!!!
			Systems are Weapons, Shields, Engines, MiscDevices, and Base Cost
			Each Hull is also Checked
			*/
*589*			SetSystemsPwrDrain();
		...
	}
...
}
I noticed something as I copied this code. the function is called in a state... and the function in the parent class is not in a state. Could this be the problem? I haven't had much experience with states :P
__________________
Call me Erdrik
-hvErdrik
-Erdrik

*PIMP*
DarkMagic
Boycott Fox!!! Down with the Evil Overlords!
Call me Erdrik is offline   Reply With Quote
Old 17th Dec 2005, 07:11 PM   #4
Angel_Mapper
Noblesse Oblige
 
Angel_Mapper's Avatar
 
Join Date: Jun. 17th, 2001
Location: Cape Suzette
Posts: 3,524
If it doesn't give you an error for the other instances of the function call then it could be a simple syntax error.
Angel_Mapper is offline   Reply With Quote
Old 17th Dec 2005, 07:59 PM   #5
Call me Erdrik
Arch Mage
 
Call me Erdrik's Avatar
 
Join Date: Nov. 24th, 1999
Location: Spring Hill, FL, USA
Posts: 334
syntax? mmm not sure, what would cause the syntax error...
If you like I can post the files and you can take a closer look?

(tho I'm not sure if my messy coding will make it any easier :P lol )

EDIT: I fixed it by adding a SetSystemsPwrDrain() function in the state
and simply adding Super.SetSystemsPwrDrain(); :P
__________________
Call me Erdrik
-hvErdrik
-Erdrik

*PIMP*
DarkMagic
Boycott Fox!!! Down with the Evil Overlords!

Last edited by Call me Erdrik; 17th Dec 2005 at 08:53 PM.
Call me Erdrik is offline   Reply With Quote
Old 19th Dec 2005, 07:30 AM   #6
Hazard.ep
Registered User
 
Hazard.ep's Avatar
 
Join Date: Oct. 7th, 2003
Posts: 166
You 100% copied the code from your *.uc. There is this *589* in front of your function call, that doesn't seem right, ever tried to take this out?
__________________
------------------------------------------------------------------------


Erik 'HaZarD' Poppe - Caster-Mod - Lead Coder, Project Coordinator
------------------------------------------------------------------------
Hazard.ep is offline   Reply With Quote
Old 19th Dec 2005, 12:42 PM   #7
[SAS]Solid Snake
Registered User
 
[SAS]Solid Snake's Avatar
 
Join Date: Jun. 7th, 2002
Location: New Zealand
Posts: 2,633
I think that was used to indicate the line of the problem. Calling a super only means that it will call the parent function, although that should work. Its hard to tell when I can only see a small segment of the code.
__________________
I make the impossible possible ... ... ... to some extent.

Digital Confectioners
[SAS]Solid Snake is offline   Reply With Quote
Old 20th Dec 2005, 08:42 AM   #8
Call me Erdrik
Arch Mage
 
Call me Erdrik's Avatar
 
Join Date: Nov. 24th, 1999
Location: Spring Hill, FL, USA
Posts: 334
Ok, Now its not recognizing variables declared in SH_Ships.uc...

Im gunna just post the three files...
this is the error:
Quote:
Error: C:\Program Files\UT2004\Ships\Classes\SH_AScouts.uc(670) : Error, Bad or missing expression after '<'
It dosen't seem to recognize the expression 'ShipWeapons' Even tho it is in the variables in the parent class SH_Ships.uc...
Is there something I need declared at the begining of the state or something?? I always thought that was for excludes and replication...

EDITi: Doh forgot to post the files

EDITii: Ok heres something wierd... I commented out the whole damn file(and any other file that cuased problems...) of course UCC compiled fine. but when I looked in Unreal ED, old classes that I had in the mod( and have since DELETED!! ) are in the class list!
SH_AShipA.uc
SH_AShipAa.uc
These files ( and some others ) are NOT in c:\program files\UT2004\ships\classes and yet show up in Unreal ED. I have deleted both Ships.u and Ships.ucl and successfuly compiled twice, and yet they still show up in unreal ED!
Attached Files
File Type: zip files.zip (12.4 KB, 9 views)
__________________
Call me Erdrik
-hvErdrik
-Erdrik

*PIMP*
DarkMagic
Boycott Fox!!! Down with the Evil Overlords!

Last edited by Call me Erdrik; 20th Dec 2005 at 09:53 AM.
Call me Erdrik 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 01:18 AM.


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