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 :
In minimap.swf , I call "registerHUDMinimap" unrealscript function ,to initial "minimap GFxObject" in "GFxHud.uc" :Code:var minimapContainer:MovieClip = this.createEmptyMovieClip("minimapContainer", this.getNextHighestDepth()); minimapContainer._x = 970; minimapContainer._y = 8; minimapContainer.loadMovie("minimap.swf");
"registerHUDMinimap" is a function in GfXHud.uc that Init my Minimap :Code:ExternalInterface.call("registerHUDMinimap", this);
Initialization process for 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); }
[GFxMinimap.uc]
And the problem ...Code:var UTMapInfo MapInfo; ... function Init(GFxHud h) { ... if (MapInfo.MapTexture != none) { MapTexSize = Texture2D(MapInfo.MapTexture).SizeX; SetString("mapImagePath", "img://" $ PathName(MapInfo.MapTexture)); <---------------- **** } ... }
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![]()



Reply With Quote

Bookmarks