Line_fence special

Post a reply

Smilies
:D :) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :wink: :geek: :ugeek: :!: :?: :idea: :arrow: :| :mrgreen: :3: :wub: >:( :blergh:
View more smilies

BBCode is OFF
Smilies are ON

Topic review
   

Expand view Topic review: Line_fence special

Re: Line_fence special

by Enjay » Tue Jun 20, 2006 4:56 am

Jack wrote:1: Block player
Seeing as how this is mentioned here, I suppose I could do a memory jog to see if my request of a "block players only" could be possible. Reasons why are explained here

http://forum.zdoom.org/potato.php?t=9895

by Cutmanmike » Tue Jun 20, 2006 4:51 am

BLOCK_RAILING is a waste if you ask me since it only has a fixed height which you can't change (Thanks to strife).

by Graf Zahl » Sun Jun 18, 2006 3:25 am

They are for setting the blocking mode of the line and correspond to the

Block, Block Everything and Railing flags as they exist right now.

by MartinHowe » Sun Jun 18, 2006 3:14 am

So what we're looking at seems to be two specials:

Code: Select all

Line_fence1(height,block_above,block_below);
height: height of the fence
block_above: blocking flags above the height
block_below: blocking flags below the height

Line_fence2(block_upper,block_middle,block_lower);
block_upper: blocking flags for the upper texture
block_middle: blocking flags for the middle texture
block_lower: blocking flags for the lower texture

Blocking flags:
 0: 0x00000000 No blocking
 1: 0x00000001 Block player
 2: 0x00000002 Block monsters
 4: 0x00000004 Block projectiles
 8: 0x00000008 Block hitscans
I suggest also:
-1: 0xFFFFFFFF Default for line type
EDIT: Or for "default", instead of -1, use 0x8000000 and have a "BLOCK_DEFAULT" symbol for it in zdefs.acs.

Incidentally, zdefs.acs already has these (never noticed them before):

Code: Select all

#define BLOCK_NOTHING           0
#define BLOCK_CREATURES         1
#define BLOCK_EVERYTHING        2
#define BLOCK_RAILING           3
What are they used for?

by Xaser » Sat Jun 17, 2006 9:50 pm

I 'third' this (assuming that even makes sense), then. :P

Since Zdoom already has the code to block lines only up to certain heights (BLOCK_RAILING), would it really be that hard to make this ability non-hardcoded?

Samurai Jack's implementation sounds perfect with the addition of the Block Hitscans as well. However, could we also have a "block middle" parameter as well? Although I assume that with the said implementation the middle texture's blocking settings would be inherited from the existing properties of the line, it would be better if we could have the added flexibility of the flag methods mentioned (so for example, you could have a line block projectiles and hitscans, but allow players to cross).

by MartinHowe » Fri Jun 09, 2006 11:22 pm

This has been asked for in various forms, including by me. Seconded. Fences are a pain because their visual height in the game bears no relationship to their actual height; with 2-sided textures, this is impossible even then.

This would be useful also for full-height fences as well. Example: in Sapphire, you can shoot through a fence at some spiders, but they can't shoot through it at you.

I would add "8: Block hitscans" also.

Line_fence special

by Jack » Fri Jun 09, 2006 10:44 pm

It would be like that:

Line_fence(height,block_upper,block_lower);

height: height of the fence
block_upper: blocking flags above the height
block_lower: blocking flags below the height

Blocking flags:
0: No blocking
1: Block player
2: Block monsters
4: Block projectiles

Top