PDA

View Full Version : UScript features for the next patch?



Gugi
11-23-2007, 09:39 AM
It would be useful if some of these "features" get implemented into UScript in the next patch:

Ordering BroadcastHandler as Linked-List again
Some function/variables to get the current time on the server (like WorldInfo.Hour).
SetPropertyText() and GetPropertyText() (I guess these are already in the new patch?)
Perhaps a way to do MD5-checks (dunno about the native-anti-cheat, though) and the Dir-Command?
Why is the Controller-List in the WorldInfo private? It had its uses in UT2k4.
Modifying defaultproperties on runtime: class'Test'.default.MyVar=5. It was especially handy with configurations (anyway, for what is the StaticSaveConfig()-function if you can't change the default properties?). (Only saw this on UDN).


These are the once I miss till know.

Just as a suggestion... :rolleyes:

Eliot
11-23-2007, 03:43 PM
it is const because we have now

native final iterator function AllControllers(class<Controller> BaseClass, out Controller C);

:)

Mysterial
11-23-2007, 07:56 PM
Modifying defaultproperties on runtime: class'Test'.default.MyVar=5. It was especially handy with configurations (anyway, for what is the StaticSaveConfig()-function if you can't change the default properties?). (Only saw this on UDN).


Config properties can be modified with that syntax (they're the only ones that can)

Bonehed316
11-24-2007, 01:21 AM
Default properties are const due to, I believe, the way default properties are now stored (compressed). There's really no need for them to be writable now with archetypes.

Wormbo
11-24-2007, 03:27 AM
[...]

SetPropertyText() and GetPropertyText() (I guess these are already in the new patch?)

[...]
Ugh, hacky stuff.

A much more needed addition would be a replacement for the missing classes UDPLink and TCPLink.

Gugi
11-24-2007, 05:55 AM
Didn't knew that, thx Mysterial.

ye, I know that these functions shouldn't be used too often (etc.) but they were sometimes useful to prevent dependencies.

Shambler
11-24-2007, 10:34 AM
Default properties are const due to, I believe, the way default properties are now stored (compressed). There's really no need for them to be writable now with archetypes.
Hmm, interesting. You can actually use the ObjectArchetype property in Object.uc to set the defaults (just cast it).
Doesn't that make the compiler restrictions for Class.default.Value = NewValue kind of pointless?
All that Class.default does is cast to the context of the default object; not to any compressed values as far as I can tell.

As for SetPropertyText/GetPropertyText, BattleMode pointed out these two functions which were added in the patch: (Object.uc)

function string GetSpecialValue(name PropertyName);
function SetSpecialValue(name PropertyName, string NewValue);
I haven't tested them, but I wonder if they work the same way?

Zeo
11-24-2007, 05:38 PM
I did find an over site in the code. The Alt Fire on the LinkGun doesn't call OwnerEvent('FiredWeapon') like all the other weapons do.

woooo
11-24-2007, 07:34 PM
geeks loool I dont get this stuff, ut2004 was a lot easier -_-

Mysterial
11-24-2007, 11:44 PM
As for SetPropertyText/GetPropertyText, BattleMode pointed out these two functions which were added in the patch: (Object.uc)

function string GetSpecialValue(name PropertyName);
function SetSpecialValue(name PropertyName, string NewValue);
I haven't tested them, but I wonder if they work the same way?


They require the mod to manually implement the function and handle property names, but the idea was to allow the same type of compatibility hackery as Get/SetPropertyText(). Just requires a bit more communication. :)

Shambler
11-25-2007, 02:15 PM
Ah I see :) I missed that they weren't native.

Gugi
11-25-2007, 02:34 PM
Haven't looked at the patch yet, but I've read in the news about these functions (and guessed that they would do the same thing).

Ok, so every mod-maker, please implement these functions^^