Announcement

Collapse
No announcement yet.

Regarding a new method of gui programming

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Regarding a new method of gui programming

    When I say new, I mean new in reference to commonly known methods and those explained at the unreal developer network. Anyhow it is plain to see in uscript source (class UT2k4mainmenu.uc) guibutton objects as well as background objects, listbox objects etc.

    However when inspecting well known mods uscript code (namely Muralis, AirBU, NeoTokyo etc.) I find their own Mainmenu classes although subclasses of ut2k4guipage like usual, do not have these GUI control OBJECTS At all!

    Instead in their default properties they use notation like this:

    Taken from muralis

    Code:
    defaultproperties
    {
        i_Background=BackgroundImage'MurGuiMainMenu.PageBackground'
        i_MuralisLogo=GUIImage'MurGuiMainMenu.ImgMuralisLogo'
        i_AscLogo=GUIImage'MurGuiMainMenu.ImgAscLogo'
        b_Practice=GUIButton'MurGuiMainMenu.PracticeButton'
        b_MultiPlayer=GUIButton'MurGuiMainMenu.MultiplayerButton'
        b_Host=GUIButton'MurGuiMainMenu.HostButton'
        b_Settings=GUIButton'MurGuiMainMenu.SettingsButton'
        b_Quit=GUIButton'MurGuiMainMenu.QuitButton'
        lblVersion=GUILabel'MurGuiMainMenu.VersionLabel'
        MenuSong="Muralis"
        bDisconnectOnOpen=True
        bAllowedAsLast=True
        __OnOpen__Delegate="MurGuiMainMenu.InternalOnOpen"
        __OnReOpen__Delegate="MurGuiMainMenu.MainReopened"
        __OnCanClose__Delegate="MurGuiMainMenu.CanClose"
        WinTop=0.00
        WinHeight=1.00
        bDebugging=True
        __OnKeyEvent__Delegate="MurGuiMainMenu.MyKeyEvent"
    }
    It seems this method is some short hand that emulates the object code, but reduces its written parameters. But what is "pagebackground" referring to? How does this programming shorthand function. Is there any documentation referring to it?

    Moreover their guifonts have no array references such as this:

    Code:
    class MurFontXenotron extends GUIFont;
    
    defaultproperties
    {
        KeyName="Xenotron"
        FontArrayNames=
    }
    Yet they work brilliantly. I believe this pseudo-system if I can even call it that of gui coding works well and I would like to employ it, but I know nothing of it, and traditional means seem troublesome.

    If anyone can shed any light on this topic, please do so. Thanks.

    #2
    The problem is that the subobjects in the default properties have not been exported with the rest of the script.

    I'm fairly sure that if you use UCC to extract the scripts then the subobjects should be exported properly. If it doesn't, then you can make UCC export all objects in a package,which includes the subobjects you want plus a whole load of other fluff which you'll have to sort through.

    Otherwise you could try asking the author(s) for the original source.

    Comment

    Working...
    X