I wanna draw a translucend texture, but i seems that Canvas class don't have more the Style, anyone know how to draw a texture traslucent, like style=3 in Unreal Engine 1 or 2
In UE 1 and 2
Canvas.Style=STY_Translucent; or Canvas.Style=3;
In UE3?
I wanna draw a translucend texture, but i seems that Canvas class don't have more the Style, anyone know how to draw a texture traslucent, like style=3 in Unreal Engine 1 or 2
In UE 1 and 2
Canvas.Style=STY_Translucent; or Canvas.Style=3;
In UE3?
You need to use DrawMaterialTile instead, and set the Materials BlendMode to be translucent.
Keep in mind, when rendering on the canvas, only the Emissive and Opacity values are valid.
I had used Canvas.Style for drawing text, how should I update that for UT3?
I wouldn't use DrawMaterialTile for text, or would I?
No, text rendering hasn't changed at all (to include font support, for better or worse).
Also, for rendering textures, you do not, in fact, need a material :
1) Create a texture with an alpha channel (I use TARGA .tga format)
2) Import your texture into a texture package
3) In your code, call Canvas.DrawTile()
The thing to play with is Canvas.DrawColor.A. Setting the alpha channel will affect how transparent your texture shows up as.
Last edited by Pfhoenix; 12-14-2007 at 09:56 AM.
Fleet Wars
Jetpack for UT3
Raggy Weapons
SpeedBump
Mod Exemplar Project
Official Proelium Site
Official UnrealScript IRC Channel - #unrealscript on irc.enterthegame.com
You don't need it. The "style" is determined by the texture itself. You can't have a color-keyed texture any more. You need to create textures with alpha channels for masking.
You only have two options :
1) Do as I wrote
2) Do as Bonehed wrote
My method negates the need to have materials that you won't otherwise use. Bonehed's method allows you to do fancy processing on a texture before rendering it.
Fleet Wars
Jetpack for UT3
Raggy Weapons
SpeedBump
Mod Exemplar Project
Official Proelium Site
Official UnrealScript IRC Channel - #unrealscript on irc.enterthegame.com
i need Canvas.DrawColor.A = 0 and Canvas.DrawTile()?
use this..
you want transparent green? use this..Code:H.Canvas.DrawColor.R = 255; H.Canvas.DrawColor.G = 255; H.Canvas.DrawColor.B = 255; H.Canvas.DrawColor.A = 0;
Code:H.Canvas.DrawColor.R = 0; H.Canvas.DrawColor.G = 255; H.Canvas.DrawColor.B = 0; H.Canvas.DrawColor.A = 130;
Last edited by pingfreak; 12-20-2007 at 07:22 PM. Reason: stuff added
~ If it was easy everyone would be doing it. ~
Akimbo Expansion Pack Elite Machines XX HitSounds Show Damage
DM-Backyard99 DM-Lan_Party
Bookmarks