Jump to content
Sign in to follow this  
zooloo75

drawIcon3D won't display my custom texture.

Recommended Posts

I've ran into a problem. The drawIcon3D command displays default A3 textures fine, but when I use a custom texture from within my mission, it just shows up as a blank square.

The texture is in paa format and is 64x64 with transparency.

Untitled_1.jpg

The texture (the original is in paa format)

http://s11.postimg.org/bpe75owcv/emblem_Admin.png

I'd also like to add that the texture works when I apply it to the user texture object.

addMissionEventHandler 
["Draw3D",
{
	{
		if(_x distance player < 10) then
		{
			if((getPlayerUID _x) in adminUIDs) then
			{
				drawIcon3D 
				[
					fullEmblemList select (_x getVariable ["emblem",0]),
					[1,0.9,0.55,1],
					[visiblePosition _x select 0,visiblePosition _x select 1, (visiblePosition _x select 2) + 2],
					1,
					1,
					0,
					name _x,
					1,
					0.045,
					"Default"
				];
			}
			else
			{
				drawIcon3D 
				[
					fullEmblemList select (_x getVariable ["emblem",0]),
					[0.78,0.56,0.72,1],
					[visiblePosition _x select 0,visiblePosition _x select 1, (visiblePosition _x select 2) + 2],
					1,
					1,
					0,
					name _x,
					1,
					0.04,
					"Default"
				];
			};
		};
	} forEach playerList - [player];
}
];

Edited by zooloo75

Share this post


Link to post
Share on other sites

It's located in the mission.

Share this post


Link to post
Share on other sites

try using a cursor defined in the config, like "Move3D" (no .paa). You may need to add the cursor to an addon.

Share this post


Link to post
Share on other sites

Textures already in the game work fine - such as markers.

Share this post


Link to post
Share on other sites

what is the name of the texture and the path you tried to reference it?

Share this post


Link to post
Share on other sites

"textures\emblem\admin.paa"

As I said, the texture works - it applies to the user texture object in the editor.

Share this post


Link to post
Share on other sites

Well it can very well be that drawIcon3D works different to setObjectTexture.

In other words maybe drawIcon3D is limited to textures from addons.

You could try to use procmon to see what paths drawIcon3D tries to access on use.

Share this post


Link to post
Share on other sites

There is some other command cant remember cannot use asset from mission it has to be in addon so it could be the case. Alternatively you can create custom RSC control to substitute draw icon, but this is just too much work

Share this post


Link to post
Share on other sites

Like always with paths and files not found even if they should, last resort is to use pseudo absolute paths.

Example: \mpmissions\<yourmissionname>.<island>\<here>\<starts>\<your>\<own>\<path>\<kewl_pic>.paa

Drawback is the same as in everything else so this only works for mp mission, for sp mission path is different...

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×