UCC is built into T3Ed and it compiles variables, events, and functions but the problems is in order to use an event or function in your class it needs some base variables, functions, and events (I'm going to refer to those as VFE).
In typical unreal games those VFEs are usually defined in the Actor class. In TDS and DX2 those functions were moved out of the Actor class into hard-coded madness. So if you write a function in your class involving a pawn, don't expect it to work since one of the most used events are Touch/UnTouch and several other vars and functions. You won't find them in unreal script in T3Ed.
It's easy enough to add Touch and UnTouch to the Actor class. See this code I added earlier tonight (it's a convoluted hack to get trigger actors from UT2003 working):
Code:
/**************************************
Added variables and functions from UT2003's Actor. These were necessary for triggers - ascottk
I may make an intermediary class between Actor and the rest (T3Extended?)
**************************************/
var const bool bOnlyAffectPawns; // Optimisation - only test ovelap against pawns. Used for influences etc.
native final function OnlyAffectPawns(bool B);
native final function SetDrawType(EDrawType NewDrawType); //This references T3Ed's version of EDrawType so it might be OK - ascottk
native(262) final function SetCollision( optional bool NewColActors, optional bool NewBlockActors, optional bool NewBlockPlayers );
event Timer();
event Touch( Actor Other );
event UnTouch( Actor Other );
event Actor SpecialHandling(Pawn Other);
//=============================================================================
// Timing.
// Causes Timer() events every NewTimerRate seconds.
native(280) final function SetTimer( float NewTimerRate, bool bLoop );
/* TouchingActors() returns all actors touching the current actor (fast)
*/
native(307) final iterator function TouchingActors( class<actor> BaseClass, out actor Actor );
//
// Triggers.
//
event Trigger( Actor Other, Pawn EventInstigator );
event UnTrigger( Actor Other, Pawn EventInstigator );
event BeginEvent();
event EndEvent();
//=============================================================================
// Iterator functions.
// Iterator functions for dealing with sets of actors.
/* AllActors() - avoid using AllActors() too often as it iterates through the whole actor list and is therefore slow
*/
native(304) final iterator function AllActors ( class<actor> BaseClass, out actor Actor, optional name MatchTag );
/* DynamicActors() only iterates through the non-static actors on the list (still relatively slow, bu
much better than AllActors). This should be used in most cases and replaces AllActors in most of
Epic's game code.
*/
native(313) final iterator function DynamicActors ( class<actor> BaseClass, out actor Actor, optional name MatchTag );
//
// Destroy this actor. Returns true if destroyed, false if indestructable.
// Destruction is latent. It occurs at the end of the tick.
//
native(279) final function bool Destroy();
//
// Called immediately before gameplay begins.
//
event PreBeginPlay()
{
// Handle autodestruction if desired.
if( !bGameRelevant )
Destroy();
}
// Called immediately after gameplay begins.
//
event PostBeginPlay();
/*
Untrigger an event
*/
function UntriggerEvent( Name EventName, Actor Other, Pawn EventInstigator )
{
local Actor A;
if ( EventName == '' )
return;
ForEach DynamicActors( class 'Actor', A, EventName )
A.Untrigger(Other, EventInstigator);
}
/* Reset()
reset actor to initial state - used when restarting level without reloading.
*/
function Reset();
/*
Trigger an event
*/
event TriggerEvent( Name EventName, Actor Other, Pawn EventInstigator )
{
local Actor A;
if ( EventName == '' )
return;
ForEach DynamicActors( class 'Actor', A, EventName )
A.Trigger(Other, EventInstigator);
}
/**************************************
Added variables and functions from UT2003's Pawn. These were necessary for triggers - ascottk
**************************************/
// return true if controlled by a real live human
simulated function bool IsHumanControlled()
{
return ( PlayerController(Controller) != None );
}
But the problem is that some of the declarations I made conflicted with the hard-coded ones and I killed T3Ed.
So one thought I had is to add a new class that'll act like an intermediary class between Actor and the rest (see my code comment) so I don't conflict with the hard-coded ones. How would I find that out? Read the Viktoria errors when it doesn't like something. T3Ed complained about not finding it's own code for its variables when I implemented my own & it said which variable it couldn't find. I think it's the ones defined by "native" or "final".
EDIT: If you declare a native function not built in to T3Ed you get something like this:
Another problem is accessing variables within a struct since the original devs implemented a new property system. I'm sure there is a way but I don't know yet.
As I get a better understanding of unreal script I'll see if we can implement a better scripting system like the triggers in ut2003, Ravenshield's AIScript. Or like the Dark Mod's Stim/Response system. The less use I get from the linking system and triggerscripts, the better.
EDIT: Just don't get your hope up . . .