DieHard Wolfers Forum Index DieHard Wolfers
A Wolfenstein 3d Fan Community


  Hosted by: MCS & Areyep.com - Designed by: BrotherTank

Original Yahoo Forum - Die Hard Archives

AReyeP HomepageAreyep Homepage DieHard Wolfenstein BunkerDieHard Wolfenstein Bunker Log inLog in RegisterRegister Banlist FAQFAQ Search ForumsSearch

  Username:    Password:      Remember me       

Timed remove bodies
Page 1 of 1
DieHard Wolfers Forum Index -> DieHard Archives View Previous TopicRefresh this PageAdd Topic to your Browser FavoritesSearch ForumsPrint this TopicE-mail TopicGoto Page BottomView Next Topic
This forum is locked: you cannot post, reply to, or edit topics.This topic is locked: you cannot edit posts or make replies.
Author Message
Guest




Last Visit:





PostPosted: Sat Jun 05, 2004 1:30 pm
   Subject: Timed remove bodies
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Next PostGoto Bottom of Posts

I put respawning guards in my TC, but to avoid having a ton of dead bodies lying around and causing the dissapearing object problem, I put RemoveObj(ob); in the death code for the guard. This removes the guard instantly as soon as he's killed, without any death animation. I was wondering if thier was a way to 'time' the removal of the dead body so it will remove, say 30 seconds or so after the guard was killed.
WSJ
DieHard Officer
DieHard Officer


Joined: 17 Apr 2004
Last Visit: 08 May 2017

Topics: 24
Posts: 521

blank.gif

PostPosted: Sat Jun 05, 2004 4:10 pm
   Subject: Re: Timed remove bodies
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Next PostGoto Bottom of Posts

Here's one way I would've done it...

In WL_ACT2.C, look for these lines:

::: CODE :::

statetype s_grddie1      = {false,SPR_GRD_DIE_1,15,NULL,A_DeathScream,&s_grddie2};
statetype s_grddie2      = {false,SPR_GRD_DIE_2,15,NULL,NULL,&s_grddie3};
statetype s_grddie3      = {false,SPR_GRD_DIE_3,15,NULL,NULL,&s_grddie4};
statetype s_grddie4      = {false,SPR_GRD_DEAD,0,NULL,NULL,&s_grddie4};


Change the line I marked in red to:

::: CODE :::

statetype s_grddie4      = {false,SPR_GRD_DEAD,2100,NULL,NULL,NULL};


Notice how I changed the "0" to "2100." That will make the guard's last death frame display for about 30 seconds. You see, the time in Wolf3D is measured in "tics." A tic is about 1/70 of a second, so 2100 tics equals approximately 30 seconds.

Also, I changed the "&s_grddie4" to "NULL" so that the guard will disappear.
ZuljinRaynor
DieHard Officer
DieHard Officer


Joined: 17 Jan 2004
Last Visit: 30 Apr 2011

Topics: 19
Posts: 559
Location: New Jersey, USA
usa.gif

PostPosted: Tue Jun 08, 2004 5:43 pm
   Subject: Re: Timed remove bodies
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Next PostGoto Bottom of Posts

Maybe, the bodies fall dead, and when they respawn 30 seconds later, the body disappears with it. Like in DN3D. By the way, I was thinking about adding a fifth difficuly to my game but I have no clue really on how to add it and make it use the Bring 'em on actors and health but have them respawn. This would be interesting, don't you guys think?
Commodore
DieHard Guard
DieHard Guard


Joined: 28 May 2004
Last Visit: 29 Mar 2008

Topics: 15
Posts: 263
Location: :noitacoL
blank.gif

PostPosted: Wed Jun 09, 2004 4:05 am
   Subject: Re: Timed remove bodies
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Next PostGoto Bottom of Posts

Like doom! I'd enjoy that.

Also slow animation of the body rotting away would be cool.

_________________
z2 - ZZT Archive
Codetech84
Code Master
Code Master


Joined: 12 Mar 2003
Last Visit: 21 Sep 2017

Topics: 22
Posts: 1281
Location: Rauma - Finland
finland.gif

PostPosted: Wed Jun 09, 2004 9:06 am
   Subject: Re: Timed remove bodies
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Next PostGoto Bottom of Posts

ZuljinRaynor wrote:
Maybe, the bodies fall dead, and when they respawn 30 seconds later, the body disappears with it. Like in DN3D. By the way, I was thinking about adding a fifth difficuly to my game but I have no clue really on how to add it and make it use the Bring 'em on actors and health but have them respawn. This would be interesting, don't you guys think?


If you store some of their original attributes (health and stuff, initial state, etc...), you could restore them later when player isn't around.

_________________
Click here to visit KFH Games website!
*UPDATED* Spear of Destiny Reloaded
KFH Games on Facebook
ZuljinRaynor
DieHard Officer
DieHard Officer


Joined: 17 Jan 2004
Last Visit: 30 Apr 2011

Topics: 19
Posts: 559
Location: New Jersey, USA
usa.gif

PostPosted: Wed Jun 09, 2004 12:19 pm
   Subject: Re: Timed remove bodies
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Next PostGoto Bottom of Posts

Do you guys know how to do it? I would love to implement this. I'm guessing it is possible so maybe we should get to work. The only problem is, I don't do coding from scratch unless I have a base for it. I'm guessing some "switches" would be done for making the respawn on our one difficulty.
Codetech84
Code Master
Code Master


Joined: 12 Mar 2003
Last Visit: 21 Sep 2017

Topics: 22
Posts: 1281
Location: Rauma - Finland
finland.gif

PostPosted: Thu Jun 10, 2004 2:11 am
   Subject: Re: Timed remove bodies
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Bottom of Posts

Yeah I know how to do it, however I don't think can be of any use 'cause I don't have the source code anymore (Had to format my HD). I have it on a backup cd, but not on HD.

Which reminds me, I could post my (not so extensive) ai bot tutorial...

_________________
Click here to visit KFH Games website!
*UPDATED* Spear of Destiny Reloaded
KFH Games on Facebook
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.This topic is locked: you cannot edit posts or make replies. Time synchronized with the forum server time
DieHard Wolfers Forum Index -> DieHard Archives View Previous TopicRefresh this PageAdd Topic to your Browser FavoritesSearch ForumsPrint this TopicE-mail TopicGoto Page TopView Next Topic
Page 1 of 1
Jump to:  

Related topics
 Topics   Replies   Views   Last Post 
No new posts 0049 "Don't Use" question...[Remove to Wolf3D Foru
Author: Thomas
0 1566 Wed Feb 15, 2006 12:27 pm
Thomas View latest post
No new posts Moving static object
Author: Raistlin
4 1649 Fri Oct 08, 2004 6:31 pm
Dugtrio17 View latest post
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
   You cannot delete your posts in this forum
You cannot vote in polls in this forum


Copyright ©2003-2008 DieHard Wolfers
A Modified subBunker Theme by BrotherTank
Powered by phpBB © 2001, 2005 phpBB Group