Duke4.net Forums: Feeling the burn - Duke4.net Forums

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Feeling the burn

User is offline   Mark 

#1

In a part of my map the player gets a quick burn as they walk past the 2 flame pots on the sides of the entrance. I already put them farther apart than I wanted to and I don't want to put them even farther apart.

Is there a quick fix that a non-coder like myself could easily add in somewhere to remove the burning property from the flame pots?
0

User is offline   Danukem 

  • Duke Plus Developer

#2

Instead of putting them farther away, try making them higher, so they are slightly above the player.
0

#3

The only way you will be able to do it to my knowledge is using CON code.

Search for this bit of code in GAME.CON
state burningbarrelcode
  fall
  ifcount 32
  {
	resetcount
	ifp palive
	  ifpdistl 1480
		ifp phigher
	{
	  addphealth -1
	  palfrom 16 16
	  ifrnd 96
		sound DUKE_LONGTERM_PAIN
	}
  }
  ifhitweapon
  {
	sound VENT_BUST
	debris SCRAP1 10
	ifrnd 128
	  spawn BURNING
	else
	  spawn BURNING2
	killit
  }
ends


There are a few ways to go about this, one way is to remove the line 'addphealth -1', which should stop the firevase and firebarrel hurting the player all together, otherwise, you can lower the number in the 'ifpdistl 1480' line thus requiring the player to be closer before they feel the pain.

The way I would go about it is by adding a new line to this bit of the code;
   {
	 resetcount
	 ifp palive
	   ifpdistl 1480
		 ifp phigher
		  ifspritepal 0
	 {



That's the only way I know that it can be done, including the game.con in a .zip with your map would have that automatically used at game start if you added the .zip with the -g command when starting eduke. Keep in mind this is a cheap fix and may not work reliably, what it (ifspritepal 0) will do is have it so that any non-zero palette (Try Pal 21) will stop the actor hurting the player at all.

This post has been edited by High Treason: 10 March 2011 - 06:24 PM

0

User is offline   Mark 

#4

I'll give it a try and see if it works and still looks ok. There is not a lot of room where they are. I might have to shrink them also.

EDIT: oops I replied without seeing HighTreason's reply.

This post has been edited by Marked: 10 March 2011 - 06:24 PM

0

#5

Hey, I replied without seeing DeeperThought's reply, he must have posted it whilst I was writing mine, and his idea might just work.
0

User is offline   Mark 

#6

It took a half dozen tries but I found the balance between size and height of the flamepots to solve the problem and it still looks ok.

Just a slight glow on the outside ceiling that doesn't really belong. I can live with that. Thanks guys.
0

User is offline   Danukem 

  • Duke Plus Developer

#7

As you can see from the CON code that was posted, changing their size makes no difference. The two things that matter are their distance from the player and whether the player is above them. That's why I suggested moving them above the player.
0

#8

Instead of taking damage. Wouldn't it be smarter if the player just got a red blood like flash. Because if the player has 1 life, and he has to go through that, then he is forced to die.
0

User is offline   Hank 

#9

View PostDeeperThought, on Mar 10 2011, 09:51 PM, said:

As you can see from the CON code that was posted, changing their size makes no difference. The two things that matter are their distance from the player and whether the player is above them. That's why I suggested moving them above the player.

Actually, I have a similar problem. How difficult is it to simply make a new no-burn actor, but still keep the illuminating effects? I'm talking about candles, they only burn you when you are very close. :P
0

User is offline   Mark 

#10

View PostDeeperThought, on Mar 10 2011, 08:51 PM, said:

As you can see from the CON code that was posted, changing their size makes no difference. The two things that matter are their distance from the player and whether the player is above them. That's why I suggested moving them above the player.



I was under the assumption that changing the size of the flamepot also changed the amount of light it casts. It used to be that way last I heard. So since I was moving the pot up higher I wanted to change the size of it to get the proper casting of light that I wanted. If the size and light relationship has been removed, then never mind.

This post has been edited by Marked: 10 March 2011 - 07:53 PM

0

User is offline   Danukem 

  • Duke Plus Developer

#11

I wasn't aware of any size to light relationship, I thought you were just concerned about damaging the player.
0

#12

View PostHank, on Mar 11 2011, 03:23 AM, said:

Actually, I have a similar problem. How difficult is it to simply make a new no-burn actor, but still keep the illuminating effects? I'm talking about candles, they only burn you when you are very close. :P


The code I posted above should not disable the light effects.
0

User is offline   Hank 

#13

View PostHigh Treason, on Mar 11 2011, 07:24 AM, said:

The code I posted above should not disable the light effects.

Yeah, but I want to know: If I want a candle, with lighting effects and damage, can I make a new actor? Or directly: I have no clue where to code the lighting, it's seems to be in the formitable Eduke32, can it be done by cons without using an existing actor?

This post has been edited by Hank: 11 March 2011 - 05:14 PM

0

User is offline   Danukem 

  • Duke Plus Developer

#14

View PostHank, on Mar 11 2011, 05:12 PM, said:

Yeah, but I want to know: If I want a candle, with lighting effects and damage, can I make a new actor? Or directly: I have no clue where to code the lighting, it's seems to be in the formitable Eduke32, can it be done by cons without using an existing actor?


It can be done, but it is not straightforward. There is no real CON support for that as yet.
0

User is offline   Hank 

#15

View PostDeeperThought, on Mar 11 2011, 08:23 PM, said:

It can be done, but it is not straightforward. There is no real CON support for that as yet.

Thanks, I'll ask more questions when the candle is done! :P
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic


All copyrights and trademarks not owned by Voidpoint, LLC are the sole property of their respective owners. Play Ion Fury! ;) © Voidpoint, LLC

Enter your sign in name and password


Sign in options