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       

2ND Function
Page 1 of 1
DieHard Wolfers Forum Index -> Feature Fanatics View Previous TopicRefresh this PageAdd Topic to your Browser FavoritesSearch ForumsPrint this TopicE-mail TopicGoto Page BottomView Next Topic
Post new topicReply to topic
Author Message
Sporb2000
DieHard SS
DieHard SS


Joined: 27 Dec 2004
Last Visit: 26 May 2009

Topics: 19
Posts: 383
Location: New Zealand - Invercargill
newzealand.gif

PostPosted: Sun Apr 03, 2005 6:23 pm
   Subject: 2ND Function
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Next PostGoto Bottom of Posts

twould be neat to have a second function button , you know , like you have your Assault Rifle and you press , say ,Y for example and it fires in a burst or it shoots a bomb - it would almost be like adding two weapons into one singular gun - though i'd say the coding would be a tad tricky it sounds possible

_________________
I Like (Brackets)
Guest




Last Visit:





PostPosted: Sun Apr 03, 2005 11:11 pm
   Subject: Re: 2ND Function
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Next PostGoto Bottom of Posts

I don`t think it would be so difficult. You need Poet`s tutorial of missile launcher and then you have to slightly modify the Cmd_fire and/or T_Attack routine to get the weapon to fire missiles instead of shooting normally.
Sporb2000
DieHard SS
DieHard SS


Joined: 27 Dec 2004
Last Visit: 26 May 2009

Topics: 19
Posts: 383
Location: New Zealand - Invercargill
newzealand.gif

PostPosted: Sun Apr 03, 2005 11:38 pm
   Subject: Re: 2ND Function
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Next PostGoto Bottom of Posts

flamer46 wrote:
I don`t think it would be so difficult. You need Poet`s tutorial of missile launcher and then you have to slightly modify the Cmd_fire and/or T_Attack routine to get the weapon to fire missiles instead of shooting normally.

to make it real good though you'd need to add a new sprite array thingy - you know ... the thig wot controlls the display of the attack frames when you fire , that way you can make the character raise the gun's barrel to shoot yer G-bomb and the muzzle flash could be a different colour ie a gray poof. That way you could have the double barrel shotgun that shoots a single barrel at a time or both at once with the second function. or a rifle , you could have the 2nd function as a melee attack that doesnt alert anyone (haave to make it like a silenced gun)

_________________
I Like (Brackets)
Guest




Last Visit:





PostPosted: Mon Apr 04, 2005 12:10 am
   Subject: Re: 2ND Function
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Next PostGoto Bottom of Posts

Quote:
to make it real good though you'd need to add a new sprite array thingy - you know ... the thig wot controlls the display of the attack frames when you fire , that way you can make the character raise the gun's barrel to shoot yer G-bomb and the muzzle flash could be a different colour ie a gray poof. That way you could have the double barrel shotgun that shoots a single barrel at a time or both at once with the second function. or a rifle , you could have the 2nd function as a melee attack that doesnt alert anyone (haave to make it like a silenced gun)

That`s pretty easy to do. In T_Attack you just put something like attackframe+=4 and it will work as another weapon. Then you only have to add the weapon states in WL_agent.c and add the sprite definitions in WL_DEF.h . Then you use an editor to insert the shotgun melee attack sprites after the ones of the shotgun firing.
Xarkon
DieHard Guard
DieHard Guard


Joined: 05 Jun 2003
Last Visit: 19 Apr 2006

Topics: 18
Posts: 203
Location: West Australia
australia.gif

PostPosted: Mon Apr 04, 2005 8:08 pm
   Subject: Re: 2ND Function
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Next PostGoto Bottom of Posts

I think a few years ago that people tried to do something close to this.

Bombs or an RPG would have to be a routine with the distance it comes out like teh projectile weapons like the "Fake Hitler's Flame", then it would explode on enemy or ground. This would be very effective and good, also another routine coded into this would have to be the explosion radius. I'm pretty sure this has been done too, We have all seen it in End Of Destiny, the exploding barrels thingy. Yeah.

Good Luck people. Smile

_________________
Trying is the first step to failure
Guest




Last Visit:





PostPosted: Tue Apr 05, 2005 1:49 am
   Subject: Re: 2ND Function
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Next PostGoto Bottom of Posts

There have been tutorials on exploding barrels since a long time. There is one at Poet`s site and one at Zujilin Raynor`s site. They both have explosive range.
andy3012
DieHard Guard
DieHard Guard


Joined: 02 Jul 2004
Last Visit: 15 Feb 2008

Topics: 29
Posts: 292
Location: England
uk.gif

PostPosted: Tue Apr 05, 2005 5:02 am
   Subject: Re: 2ND Function
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Next PostGoto Bottom of Posts

you could just do the diffrent weapon same button tutorial, like you could make it so it doesn't change the graphic.
Guest




Last Visit:





PostPosted: Tue Apr 05, 2005 6:06 am
   Subject: Re: 2ND Function
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Next PostGoto Bottom of Posts

Here is what i think you could do.

I`ll make the pistol use the 2nd function. By pressing ctrl you shoot a normal bullet, by pressing Z you shoot a missile.

So first you need Poet`s tutorial or getting a rocket.

Open WL_Agent.c

Find the weapon state:
::: CODE :::

{{6,0,1},{6,2,2},{6,0,3},{6,-1,4} },  // knife
{{6,0,1},{6,1,2},{6,0,3},{6,-1,4} },  // pistol

Change the line with pistol like this.
::: CODE :::

{{6,0,1},{6,1,2},{6,0,3},{6,-1,4}, {6,0,5},{6,1,6},{6,0,7},{6,-1,8}}, // pistol

Ok now go to GunAttack (objtype *ob)
and find the lines
::: CODE :::

if(gamestate.weapon==wp_mlauncher)
{

Change to
::: CODE :::
 
if((gamestate.weapon == wp_mlauncher) || (gamestate.weapon == wp_pistol && gamestate.attackframe==5))
{


Now go to CMD_fire routine
::: CODE :::

void  Cmd_Fire (void)
{

Change that to
::: CODE :::

void Cmd_Fire(boolean ctrl)
{

Now in the routine scroll down a bit
find gamestate.weaponframe = 0;
before add:
::: CODE :::

if(ctrl == false && gamestate.attackframe != 5)
gamestate.attackframe = 5

Now go to the T_Player routine
Find
::: CODE :::

if( buttonstate[bt_attack] && !buttonheld[bt_attack])
Cmd_Fire();

Change to
::: CODE :::

if(buttonstate[bt_attack && !buttonheld[bt_attack] && (!gamestate.weapon == wp_pistol && gamestate.attackframe <= 4)
Cmd_Fire(true);
else
if( Keyboard[sc_Z] && gamestate.weapon =wp_pistol && !gamestate.attackframe >=5)
Cmd_Fire(false);


Ok, i haven`t tested this so tell me if it works. I think theres some errors in the if statements above. Tell me whatever bug you get. With this code the weapon sprites should stay the same. If they already are changing when you shoot a missile then it`s ok. Otherwise in the CMD_FIRE routine find
::: CODE :::

gamestate.weaponframe =0

change to
::: CODE :::

if(ctrl=true)
gamestate.weaponframe = 0;
else
gamestate.weaponframe = 5;

Tell me if this works.
Commodore
DieHard Guard
DieHard Guard


Joined: 28 May 2004
Last Visit: 29 Mar 2008

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

PostPosted: Tue Apr 05, 2005 8:39 am
   Subject: Re: 2ND Function
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Next PostGoto Bottom of Posts

the problem I see with adding a button is that you should then have to go and make it customiseable, buecause some of us use different control setups and pressing Z would mean I'd have to reach across the keyboard.

_________________
z2 - ZZT Archive
Guest




Last Visit:





PostPosted: Tue Apr 05, 2005 8:55 am
   Subject: Re: 2ND Function
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Next PostGoto Bottom of Posts

Yes, i forgot that keyboards can vary, on my keyboard z is just above alt.
Though i think it wouldn`t be difficult to do. I mean probably someone like BT or Adam Biser could do it. I know there are the definitions in WL_DEF.h and two routines in wl_main.c(or wl_menu.c, can`t remebmer Very Happy ).They are ReadConfig and WriteConfig.
Tricob
Moderator
<B>Moderator</B>


Joined: 14 Mar 2005
Last Visit: 3:34 ago.

Topics: 165
Posts: 8280
Location: Neo-traditions, Inc.
usa.gif

PostPosted: Tue Apr 05, 2005 6:22 pm
   Subject: Re: 2ND Function
   [ IP : Logged ]
Reply with quote
Goto Top of PostsGoto Previous PostGoto Bottom of Posts

flamer46 wrote:
Yes, i forgot that keyboards can vary, on my keyboard z is just above alt.
Though i think it wouldn`t be difficult to do. I mean probably someone like BT or Adam Biser could do it. I know there are the definitions in WL_DEF.h and two routines in wl_main.c(or wl_menu.c, can`t remebmer Very Happy ).They are ReadConfig and WriteConfig.

I'd really like to know - where in the Customize Controls window do you plan to draw in this extra button? I don't see any extra room to display something additional in there. But if I'm overlooking some place that's obvious to you, please - by all means - point it out to me. Smile
Display posts from previous:   
Post new topicReply to topic Time synchronized with the forum server time
DieHard Wolfers Forum Index -> Feature Fanatics 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 Weapons balancement mod for Wolfenstein 3d.
Author: undead merc
13 3796 Sun Jan 04, 2009 3:20 am
Zombie_Plan View latest post
No new posts dynamic sounds
Author: doomjedi
16 3739 Tue Jan 08, 2008 2:40 pm
Ripper View latest post
No new posts Gun Change bob
Author: Xarkon
18 3494 Thu Mar 31, 2005 8:07 am
Guest View latest post
No new posts Stranger Weapons in TC's
Author: Majik Monkee
22 6134 Mon Feb 02, 2004 4:29 am
Guest View latest post
No new posts Reloading weapons
Author: wolf3dbreaker
26 6195 Wed Jul 02, 2003 12:05 pm
jamez 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