Results 1 to 1 of 1
  1. #1
    MSgt. Shooter Person
    Join Date
    Jul 2011
    Posts
    32

    Question Problem with GFxMinimap (2DMapTexture) [+HUD flaw :D]

    I'm trying to make my custom Hud(+minimap)
    main trouble is "Minimap" !

    According to Scaleform tutorials about HUD (Mastering a GFx HUD (Part 1-4) ) ,I made my three classes :
    >GFXHudWrapper [extend HUD] : Handle HUD + Inventory + ...
    >GFxHud [extend GFxMoviePlayer]: Handling and updating HUD's itesm+ Initialing and updating Minimap
    >GFxMinimap [extend GFxObject] : Minimap Logic

    First "GFxHudWrapper.uc" create a "GFxHud" .
    Then "GFxHud.uc" load "Hud.swf" .
    "Hud.swf" load "minimap.swf" internally, at the beginning with action-script :
    Code:
    var minimapContainer:MovieClip = this.createEmptyMovieClip("minimapContainer", this.getNextHighestDepth());
    minimapContainer._x = 970;
    minimapContainer._y = 8;
    minimapContainer.loadMovie("minimap.swf");
    In minimap.swf , I call "registerHUDMinimap" unrealscript function ,to initial "minimap GFxObject" in "GFxHud.uc" :
    Code:
    ExternalInterface.call("registerHUDMinimap", this);
    "registerHUDMinimap" is a function in GfXHud.uc that Init my Minimap :
    Code:
    function registerHUDMinimap(GFxMinimap mp )
    {
    	//`log("Initiing MINIMAP !!!!--!!!!! ");
    	Minimap = mp ;
    	Radius = 10; //?
    	CurZoomf = 64;
    	NormalZoomf = 64;
    
    	Minimap.Init(self); // <---- *
    
    	Minimap.SetFloat("_xscale", 85);
    	Minimap.SetFloat("_yscale", 85);
    }
    Initialization process for Minimap ...
    [GFxMinimap.uc]
    Code:
    var UTMapInfo		MapInfo;
    ...
    function Init(GFxHud h)
    {
    ...
    if (MapInfo.MapTexture != none)
    	{
    		MapTexSize = Texture2D(MapInfo.MapTexture).SizeX;
    		SetString("mapImagePath", "img://" $ PathName(MapInfo.MapTexture));  <---------------- ****
    	}
    ...
    }
    And the problem ...
    I wonder how minimap 2DTexure is set in above code ?!??!
    I use "VCTF-Necropolis.uk" map , that really has a minimap with a map-texture ! But when I play it with my GameCode (not UTGame) , nothing show in minimap except enemy+.. item as a red point !

    PS: I can show my enemy+flag+... in minimap without problem ! I just have problem with 2D-map-texture showing .
    PS: I knew editor method to change minimap texture ( Editor::WorldProperties->WorldInfo->MyMapInfo-> ... )

    Thanks is advance for your helps
    Last edited by emadpres; 10-14-2011 at 05:45 AM.


 

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Copyright ©2009-2011 Epic Games, Inc. All Rights Reserved.
Digital Point modules: Sphinx-based search vBulletin skin by CompletevB.com.