Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
XiaoYangGuang

Static Sprites - How to?

Recommended Posts

Does anyone know how to create sprites that does not turn around when you look at it, it would act like a linedef except it has its own life. The point is that I want to be able to make easier shootable walls and stuff

Share this post


Link to post

Sprites are not rendered in 3d. I do know in some OpenGL source ports sprites can be rendered the way you describe in a vertical axis, so that the sprites look like paper when you stare straight down at them, but the image will always face you from any angle.

Essentially it only does half of what you describe and is a variable in the options menu, not really an editing feature.

Share this post


Link to post

Well sidedefs are always standing still pointing whatever direction you put it and on which side its texture is, However a sprite is usually always facing the camera, But I would like to be able to lock the sprite so it would face the same way as if it was a linedef, thus it would be possible to fake that it is a wall or something

Share this post


Link to post
PhilibusMo said:

Isn't what he wants to do achievable with an impassible double sided linedef within a sector with the mid textures filled?

Can't shoot it.

Made a 1 unit wide sector and put the ceiling of that sector to 1 unit above the floor. Now you have a shootable window. You can add a middle texture to it as well.

Share this post


Link to post
DuckReconMajor said:

Can't shoot it.

Made a 1 unit wide sector and put the ceiling of that sector to 1 unit above the floor. Now you have a shootable window. You can add a middle texture to it as well.


You can do with 3d floors as well, But its a bit different, cause I want to be able to have frames for that static sprite, so that when you shoot it it has its own animation but I dont want it to turn around as to look like a sprite's behaviour

Share this post


Link to post

You could do that with ZDoom and ACS, and you wouldn't have to use the 1-unit-wide-sector trick to make it work because ZDoom can make linedefs block shots.

Share this post


Link to post
arrrgh said:

You could do that with ZDoom and ACS, and you wouldn't have to use the 1-unit-wide-sector trick to make it work because ZDoom can make linedefs block shots.




Yeah, I explained myself a little bit poorly here before. This is what I wrote to a buddy of mine:

Imagine you have a button that is a sprite, when you approach it, you hear some small sound, when you shoot it, it will cause another sound, and turn on, if you shoot it again it may sound more damaged this time, and if you maybe shoot it once more time it will be broken, when its broken it will spawn some crap from nearby its destination
Im not sure but I dont think you can define linedefs or textures to have some kind of hp.. And to act like some life

I know there are some other ways doing some of these things, like ACS etc but afaik it would be more limited?

Share this post


Link to post
XiaoYangGuang said:

Imagine you have a button that is a sprite, when you approach it, you hear some small sound, when you shoot it, it will cause another sound, and turn on, if you shoot it again it may sound more damaged this time, and if you maybe shoot it once more time it will be broken, when its broken it will spawn some crap from nearby its destination
Im not sure but I dont think you can define linedefs or textures to have some kind of hp.. And to act like some life

I know there are some other ways doing some of these things, like ACS etc but afaik it would be more limited?

This is most definitely doable with ACS. You'll need a mapspot to spawn debris objects from as well. You can also have the script that runs use a variable as a counter to track 'damage' and 'health.'

int shovelsecretwallhealth;

script 21 (void)
{
	if(shovelsecretwallhealth==2) //three hits
	{
		int amount;
		while(amount<=10)//while loop spawns 10 pieces of debris randomly at once
		{
			thing_projectilegravity(10,random(200,206),random(0,255),random(15,35),random(25,65));
			amount++;
		}
		
		sectorsound("environment/woodbreak",127);
		setlinetexture(2,side_front,texture_middle,"CUPBRD4");
		setlineblocking(2,BLOCK_NOTHING);
		clearlinespecial();
		terminate;//ends
	}
	//If the above is not met, this continues
	sectorsound("environment/Barrelhit",127);
	shovelsecretwallhealth++;
}

Share this post


Link to post

Place an invisible actor. When the actor dies, it triggers the script. Simple.

Share this post


Link to post
Gez said:

Place an invisible actor. When the actor dies, it triggers the script. Simple.

That would work as well, and has an added effect (if you have it turned on) of your weapons autoaiming for it, making it easier to find. :P

Share this post


Link to post
Gez said:

Place an invisible actor. When the actor dies, it triggers the script. Simple.

Did this for various destructible scenery in a project I'll likely never finish. Works great, and I added a simple "scanner" weapon that would make these invisible actors jump to a single frame of animation, which would show where hidden passages and such were.

Share this post


Link to post

I imagine you could use 3D models for such things if you're using a port that supports it:

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×