Main

Forums

Wiki

Downloads

Tutorials

Walkthrough

Unreal-netiquette

Links

Submit-News

Oldunreal's hosted:
UnrealReference

Usermaps

Real-CTF

Donate for Oldunreal:

Oldunreal Donation
Oldunreallogo
  Welcome, Guest. Please Login or Register
 
  HomeHelpSearchLoginRegister  
 
 
Canvas.DrawPortal (Read 337 times)
Bleeder91[NL]
God Member
*****
Offline


Personal Text:

Posts: 780
Location, Location, Location.
Gender: male
Canvas.DrawPortal
04/16/12 at 18:36:35
 
2 Downsides to using this:
- Sprites will be shown outside of the draw region of the portal, just try shooting a dispersion shot to somewhere outside the drawn view, the explosion will show up somewhere outside the box.
- The weapon you're carrying will be redrawn, or at least I think it does. This is pretty annoying since I use it on the scoreboard and it'll make the redrawn weapon overlap some HUD parts.
Any ideas on how to fix this?
Back to top
« Last Edit: 04/16/12 at 18:37:14 by Bleeder91[NL] »  
WWW WWW Bleeder91[NL]  
IP Logged
 
[]KAOS[]Casey
Oldunreal MasterPoster
******
Offline


nedm

Posts: 2894
Gender: male
Re: Canvas.DrawPortal
Reply #1 - 04/16/12 at 19:40:45
 
Oh shi- ancient bugs that I can barely remember how we fixed!

1)fixed for 227(can't remember since what version), impossible to fix otherwise except with workaround which i'll post below
2) that's a bug in a render device, I don't remember which it is anymore, but I don't think it happens in 227 or you can fix it with a setting

Workaround for  1:
Your draw portal has to be positioned at X/Y of 0,0, since the current drawportal native code doesn't offset the drawing of the sprites by the X/Y position of the portal.

Possible workaround for 2:

Render the portal before rendering weapon

Back to top
« Last Edit: 04/16/12 at 19:41:21 by []KAOS[]Casey »  
 
IP Logged
 
Bleeder91[NL]
God Member
*****
Offline


Personal Text:

Posts: 780
Location, Location, Location.
Gender: male
Re: Canvas.DrawPortal
Reply #2 - 04/16/12 at 21:31:01
 
thx for the quick response Cheesy
1: So I guess this won't be a problem when I play in 227? I know it does in 226 but if it's fixed in 227 then it doesn't require any changes in the script itself, right?
2:Yeah, I guess that's the only option. I'll try drawing it first, then call Weapon.RenderOverlays, and then draw the scoreboard background around the portal. There's just this issue with the second weapon render being slightly off location from the first weapon. Gotta test this one out tomorrow if it still does that.
Back to top
 
WWW WWW Bleeder91[NL]  
IP Logged
 
[]KAOS[]Casey
Oldunreal MasterPoster
******
Offline


nedm

Posts: 2894
Gender: male
Re: Canvas.DrawPortal
Reply #3 - 04/17/12 at 02:55:02
 
The sprite drawing bug just be fixed when you use 227, nothing additional is needed.

edit: the slightly off location thing might be because the aspect ratio of Canvas.ClipX/ClipY not matching the drawportals ratio of sizex/sizey
Back to top
« Last Edit: 04/17/12 at 02:56:01 by []KAOS[]Casey »  
 
IP Logged
 
Bleeder91[NL]
God Member
*****
Offline


Personal Text:

Posts: 780
Location, Location, Location.
Gender: male
Re: Canvas.DrawPortal
Reply #4 - 04/17/12 at 11:14:47
 
Well that didn't work out that well. Tried calling Weapon.RenderOverlays from the scoreboard, gave some crappy results. It looks fine when you don't do anything, but once you start shooting, for some reason the weapon goes back a bit :S
And the portal's FOV was different from my own, that's why it was shown off location. But it still gives problems when I try to zoom in. I think I'll leave it hidden for a while until something pops up.
Back to top
 
WWW WWW Bleeder91[NL]  
IP Logged
 
(Moderators: Smirftsch, TCP_Wolf, Smartball, pÍtßűll, DieHard SCWS)