Announcement

Collapse
No announcement yet.

Cant Access an text if its not on the first frame?

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

    #16
    Probably something wrong with your UnrealScript somewhere. That's usually the culprit of a Scaleform related crash. Hard to say what it could be. You'll have to debug it to track it down.

    Comment


      #17
      The code I gave you is tested working.

      I suspect the culprit is in your other class.

      Comment


        #18
        well i completly took the code that referenced any oter classes and used exactly the same whole Class you posted above Checked twice the paths to make Sure there werent any path issues

        Code:
        class SFHud extends GFxMoviePlayer;
        
        var GFxObject buff1txt;
        
        function Init(optional LocalPlayer player)
        {	
            super.Init(player);
            Start();
            Advance(0);
        }
        
        
        event bool WidgetInitialized(name WidgetName, name WidgetPath, GFxObject Widget)
        {    
            switch(WidgetName)
            {                 
                case ('tests'):
                      buff1txt = Widget;
                      SetWidgetPathBinding(buff1txt, WidgetPath);		
                      break;		   
                default:
                      break;
            }
            return true;
        }
        
        function TickHUD()
        {
            
                if (buff1txt != none)
                {
                     buff1txt.SetText("TEEEESSSSTTTT");
                }
            
        }
        
        defaultproperties
        {
            WidgetBindings(0)={(WidgetName="tests",WidgetClass=class'GFxClikWidget')}
        
            MovieInfo = SwfMovie'SURVIVORFlash.HUD'
        	
            bIgnoreMouseInput = true
            bDisplayWithHudOff = false
            bEnableGammaCorrection = false
            bPauseGameWhileActive = false
            bCaptureInput = false;
        }
        Aaction Script

        Code:
        if( _global.CLIK_loadCallback )
        {
             _global.CLIK_loadCallback(buff1_mc.tests._name, targetPath(buff1_mc.tests), buff1_mc.tests); // changed buff1nametxt to tests to see if it was some sort of isse
        }

        Everything just gave me the same result wich is the Crash

        Comment


          #19
          Interesting. Works on my end. What release of UDK are you using?

          You can try replacing the WidgetBindings line in default properties with this:

          Code:
          WidgetBindings.Add((WidgetName="tests",WidgetClass=class'GFxClikWidget'))

          Comment


            #20
            Well nevermind i decided to make everything from scratch and use SetVisible() instead now i set all the buffs & debuffs set visible to false and then just toggle them on/off whatever the player has the buff Still thanks for the help matt!

            Comment

            Working...
            X