[Added] UDMF vertex slopes

Moderator: Developers

UDMF vertex slopes

Postby DavidPH » Wed Dec 08, 2010 10:38 pm

Adds UDMF properties to vertexes for applying vertex slopes to them directly, instead of via things.

Code: Select allExpand view
vertex
{
   zceiling = <float>; // Heights are absolute. Default is no slope.
   zfloor   = <float>; // Note that undefined is not the same as 0.
}


EDIT: Rewrote so that the slope data is in an external struct. An array is created when loading a UDMF map and deleted after reading the slope values. (For non-UDMF maps, the array is NULLed and the length set to 0.)
Attachments
UDMF_VERTEX_slopes.patch.7z
new patch for r3025
(1.69 KiB) Downloaded 26 times
Last edited by DavidPH on Thu Dec 09, 2010 10:44 am, edited 1 time in total.
User avatar
DavidPH
Crazy Compiler Man
 
Joined: 28 Aug 2009

Re: UDMF vertex slopes

Postby esselfortium » Wed Dec 08, 2010 10:42 pm

:wub:
User avatar
esselfortium
 
Joined: 19 Sep 2006

Re: UDMF vertex slopes

Postby Grymmoire » Wed Dec 08, 2010 10:57 pm

I like this, I like this a lot.

That's 2 mappers who use vertex slopes and like this. I SEE A TREND! :P
User avatar
Grymmoire
Terrible, terrible.
 
Joined: 24 Jun 2009
Location: Nowhere, KS

Re: UDMF vertex slopes

Postby Xaser » Wed Dec 08, 2010 11:47 pm

10/10.

I might actually find myself using vertex slopes now. For some reason I've never felt like littering a map with extra things so I've generally stuck to the "Vaderslope" method instead.
User avatar
Xaser
anarchivist
 
 
 
Joined: 20 Jul 2003

Re: UDMF vertex slopes

Postby NeuralStunner » Thu Dec 09, 2010 12:37 am

This has my vote as well.
User avatar
NeuralStunner
Worldcrafter
 
 
 
Joined: 21 Jul 2009
Location: A Dynamic Link Library
Discord: NeuralStunner#1293

Re: UDMF vertex slopes

Postby Graf Zahl » Thu Dec 09, 2010 2:58 am

The idea is good but the implementation is not. This increases the size of the vertex structure from 8 to 20 bytes but those 12 bytes are never ever used anymore after setup. Before this is added it needs to be changed to store the temporary data in a temporary data structure.
User avatar
Graf Zahl
Lead GZDoom Developer
 
Joined: 19 Jul 2003
Location: Germany

Re: UDMF vertex slopes

Postby DavidPH » Thu Dec 09, 2010 9:43 am

OK. I wasn't sure if it'd be a problem or not. I'll go fix that, then.
User avatar
DavidPH
Crazy Compiler Man
 
Joined: 28 Aug 2009

Re: UDMF vertex slopes

Postby DavidPH » Thu Dec 09, 2010 10:47 am

New patch is done. I wasn't certain what else to do with the vertexdata array, so I delete it after loading slopes. This didn't cause any problems when I tested, but if there's a better place to do so (if it should be done at all), then feel free to move it (or tell me where to move it to).
User avatar
DavidPH
Crazy Compiler Man
 
Joined: 28 Aug 2009

Re: UDMF vertex slopes

Postby Graf Zahl » Mon Dec 13, 2010 7:57 pm

added
User avatar
Graf Zahl
Lead GZDoom Developer
 
Joined: 19 Jul 2003
Location: Germany


Return to Closed Feature Suggestions

Who is online

Users browsing this forum: No registered users and 1 guest