Special Operations: Action Tactical mod [Beta 2 Release!]
Forum rules
The Projects forums are only for projects. If you are asking questions about a project, either find that project's thread, or start a thread in the General section instead.
Got a cool project idea but nothing else? Put it in the project ideas thread instead!
Projects for any Doom-based engine (especially 3DGE) are perfectly acceptable here too.
Please read the full rules for more details.
The Projects forums are only for projects. If you are asking questions about a project, either find that project's thread, or start a thread in the General section instead.
Got a cool project idea but nothing else? Put it in the project ideas thread instead!
Projects for any Doom-based engine (especially 3DGE) are perfectly acceptable here too.
Please read the full rules for more details.
-
- Posts: 1489
- Joined: Thu Sep 07, 2006 12:24 pm
- Location: Boringland, California
Re: Special Operations: Action Tactical mod [Beta 1 Release!
Strange, I thought I changed it to 5. Are you using the Beta 1 version or the Alpha version? I know that the Alpha version, that pickup code was messed up but it should have been fixed in Beta 1. Also, that just reminded me that I completely forgot to change the pickup sound for that Rocket Launcher.
-
- Posts: 1880
- Joined: Mon May 24, 2010 4:38 pm
- Location: C:\Earth>
Re: Special Operations: Action Tactical mod [Beta 1 Release!
Oh, you changed it in the Beta version? I haven't downloaded the Beta version yet, I'm using the Alpha version.
-
- Posts: 564
- Joined: Mon Jun 25, 2012 12:06 pm
- Location: Stranded on Lh'owon
Re: Special Operations: Action Tactical mod [Beta 1 Release!
Played it, not so bad keep it up!
-
- Posts: 1786
- Joined: Wed Sep 08, 2010 4:58 pm
Re: Special Operations: Action Tactical mod [Beta 1 Release!
I like it so far. The combat shotgun feels like it has a little too much spread though. Maybe tighten it slightly?
-
- Posts: 1880
- Joined: Mon May 24, 2010 4:38 pm
- Location: C:\Earth>
Re: Special Operations: Action Tactical mod [Beta 1 Release!
It does feel like a little too much spread, actually.
-
- Posts: 1489
- Joined: Thu Sep 07, 2006 12:24 pm
- Location: Boringland, California
Re: Special Operations: Action Tactical mod [Beta 1 Release!
I could probably tighten it up a tiny bit. I purposely left the spread for the combat shotgun to be wide since that gun is supposed to fill in the SSG's role of being the perfect CQB gun. The Model 1887 fills the Doom Shotgun's role of being the "sorta" sniper-rifle at medium range firefights.
Alright, so I'm trying to figure out how to have grenades you can use at any time while using any weapon like in Call of Duty 4, however, I want it so that it'll play the animation of the player throwing the grenade. How would I go about and doing that?
Alright, so I'm trying to figure out how to have grenades you can use at any time while using any weapon like in Call of Duty 4, however, I want it so that it'll play the animation of the player throwing the grenade. How would I go about and doing that?
-
- Posts: 1786
- Joined: Wed Sep 08, 2010 4:58 pm
Re: Special Operations: Action Tactical mod [Beta 1 Release!
It might need a bit more punch then, since it feels like it's just a weaker version of the 1887 right now.
-
- Posts: 1880
- Joined: Mon May 24, 2010 4:38 pm
- Location: C:\Earth>
Re: Special Operations: Action Tactical mod [Beta 1 Release!
GZDoom is tricky when it comes to this. Download Brutal Doom, and take a peek at the PLAYER lump. You'll probably get the idea. This is one of the lines in the player's spawn state:lizardcommando wrote:Alright, so I'm trying to figure out how to have grenades you can use at any time while using any weapon like in Call of Duty 4, however, I want it so that it'll play the animation of the player throwing the grenade. How would I go about and doing that?
Code: Select all
TNT1 A 0 A_JumpIfInventory("FistsSelected", 1, "FistsStand")
Last edited by Zombieguy on Wed Aug 22, 2012 10:43 pm, edited 1 time in total.
-
- Posts: 1489
- Joined: Thu Sep 07, 2006 12:24 pm
- Location: Boringland, California
Re: Special Operations: Action Tactical mod [Beta 1 Release!
Yeah, I suppose I could boost up the strength for the Combat Shotgun. It was pretty hard to try and balance these two guns.
-
- Posts: 9696
- Joined: Sun Jan 04, 2004 5:37 pm
- Preferred Pronouns: They/Them
- Operating System Version (Optional): Debian Bullseye
- Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
Re: Special Operations: Action Tactical mod [Beta 1 Release!
In the Mutiny (and Hexen come to think of it) I'm pretty sure it's a CustomInventory "Use" state that shoots the projectile. This is the simplest method but the grenade spawns instantly without any animation.lizardcommando wrote:Alright, so I'm trying to figure out how to have grenades you can use at any time while using any weapon like in Call of Duty 4, however, I want it so that it'll play the animation of the player throwing the grenade. How would I go about and doing that?
To have a weapon animation you can either code in a grenade-throwing state for every weapon, or figure out a way to instantly switch to a grenade weapon and back to your old weapon using a mix of inventory flags and ACS (again for every weapon, but at least the actual state is in one weapon only so you don't have to edit every single weapon every time you want to adjust the grenade throw).
-
- Posts: 1489
- Joined: Thu Sep 07, 2006 12:24 pm
- Location: Boringland, California
Re: Special Operations: Action Tactical mod [Beta 1 Release!
Alright, I kinda got the grenades to work. I've only got it to function with the Colt 1911 so far, but Vaecrius's first method was what I'm going with. Unfortunately, I seem to be running into a small problem. I end up having unlimited grenades. Not sure what I'm missing here:
Code: Select all
ACTOR Colt1911 : Weapon replaces Pistol
{
+NOALERT
+NOAUTOFIRE
Weapon.SelectionOrder 1000
Weapon.AmmoUse 1
Weapon.AmmoUse2 0
Weapon.SlotNumber 2
Weapon.AmmoGive 10
Weapon.AmmoType "Clip"
//AttackSound "weapons/coltfire"
Obituary "%o was capped by %k's Colt 1911."
+WEAPON.WIMPY_WEAPON
Inventory.Pickupmessage "Picked up a Colt 1911."
States
{
Ready:
TNT1 A 0 A_JumpIfInventory("TossGrenade", 1, "GrenadeThrow")
1911 A 1 A_WeaponReady
Loop
Deselect:
1911 A 1 A_Lower
Loop
Select:
1911 A 1 A_Raise
Loop
Fire:
1911 A 1
1911 B 0 A_AlertMonsters
1911 B 1 Bright A_PlayWeaponSound("weapons/coltfire")
1911 B 1 Bright A_FireBullets(3,2,-1,7,"BULLETPUFF",1,0)
1911 C 1
1911 D 2
1911 E 1
1911 D 1
Goto Ready
GrenadeThrow:
TNT1 A 0 A_JumpIfInventory("grenadepickup", 1, 2)
GRWU AB 3
GREN ABC 3
GREN D 4 A_PlayWeaponSound("weapons/pinpull")
GREN E 3
TNT1 A 6
GREN F 2 A_PlayWeaponSound("weapons/grenadethrow")
GREN G 2 A_FireCustomMissile("GrenadeObj",-1,1,3,2)
TNT1 A 0 A_TakeInventory("grenadepickup",1,TIF_NOTAKEINFINITE)
GREN HI 2
TNT1 A 4
Goto Ready
AltFire:
KICK A 2 A_PlayWeaponSound("weapons/kickgo")
KICK B 2
KICK C 0 A_Recoil(-5)
KICK C 2 A_CUSTOMPUNCH(10,0,0,"KickPuff")
KICK B 3
Goto Ready
Spawn:
PIST A -1
Stop
}
}
-
- Posts: 1489
- Joined: Thu Sep 07, 2006 12:24 pm
- Location: Boringland, California
Re: Special Operations: Action Tactical mod [Beta 1 Release!
Hey guys, I've got another question. So why is it bad to do the "Sister weapon" route for berserk weapons? I wanted it to powerup not only the fists and its altfire kick attack, but the knife as well.
-
- Posts: 61
- Joined: Thu Nov 17, 2011 10:03 pm
- Location: Canada
Re: Special Operations: Action Tactical mod [Beta 1 Release!
I assume that the "JumpifInventory" at the beginning of GrenadeThrow is meant to check if you have any explosives left before you toss them, but it seems that it merely skips a couple frames - I think what you meant to do was have the JumpIfInventory skip a frame that cancels the attack.
IE
GrenadeThrow:
TNT1 A 0 A_JumpIfInventory("grenadepickup", 1, 2)
GRWU AB 3 A_Jump(256, "ready") //cancel attack if there are no more grenades left
GREN ABC 3 // continue attack
etc
I could be just too tired/stupid at this moment though.
IE
GrenadeThrow:
TNT1 A 0 A_JumpIfInventory("grenadepickup", 1, 2)
GRWU AB 3 A_Jump(256, "ready") //cancel attack if there are no more grenades left
GREN ABC 3 // continue attack
etc
I could be just too tired/stupid at this moment though.
-
- Posts: 1489
- Joined: Thu Sep 07, 2006 12:24 pm
- Location: Boringland, California
Re: Special Operations: Action Tactical mod [Beta 1 Release!
That just ended up crashing ZDoom :/
Ok, oddly enough, I don't know how I ended up not catching this at all, but the coding seems to be dependent on the primary weapon's ammunition. For example, the ammo is being taken from the Colt 1911 rather than the grenades themselves. The ammo is being taken from BOTH the primary weapon and the grenade themselves. I don't know how the hell I didn't notice that before... Ugh, this is annoying to try and fix. >_<
Ok, oddly enough, I don't know how I ended up not catching this at all, but the coding seems to be dependent on the primary weapon's ammunition. For example, the ammo is being taken from the Colt 1911 rather than the grenades themselves. The ammo is being taken from BOTH the primary weapon and the grenade themselves. I don't know how the hell I didn't notice that before... Ugh, this is annoying to try and fix. >_<
-
- Posts: 9696
- Joined: Sun Jan 04, 2004 5:37 pm
- Preferred Pronouns: They/Them
- Operating System Version (Optional): Debian Bullseye
- Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
Re: Special Operations: Action Tactical mod [Beta 1 Release!
1. Never copypaste another person's code into a main project until you understand every line of code you are pasting.
1.1. If you ever see an A_Jump/Check with a number instead of a named state, never take anything for granted that it would work as planned, without double-checking where everything jumps to.
2. Do a string search for A_Jump and A_Check and check all jump states.
3A. If you set an A_Jump/Check call on a non-zero length frame and it does in fact jump, the jump occurs before the length of the frame such that you do not see the calling frame at all.
3B. Always, always check jumps to and from "ready", "spawn", "see" or other frequently defaulted-to states to make sure that you never end up in a zero-length loop.
Greenmarine's suggestion crashes because of 3A and 3B.
Here's my version, which moves the A_Jump/Ready call to after the AB frames have finished playing:
1.1. If you ever see an A_Jump/Check with a number instead of a named state, never take anything for granted that it would work as planned, without double-checking where everything jumps to.
2. Do a string search for A_Jump and A_Check and check all jump states.
3A. If you set an A_Jump/Check call on a non-zero length frame and it does in fact jump, the jump occurs before the length of the frame such that you do not see the calling frame at all.
3B. Always, always check jumps to and from "ready", "spawn", "see" or other frequently defaulted-to states to make sure that you never end up in a zero-length loop.
Greenmarine's suggestion crashes because of 3A and 3B.
Here's my version, which moves the A_Jump/Ready call to after the AB frames have finished playing:
Code: Select all
GrenadeThrow:
TNT1 A 0 A_JumpIfInventory("grenadepickup", 1, "GrenadeReallyThrow")
GRWU AB 3 //play these frames and cancel attack, if there are no more grenades left
TNT1 A 0 A_TakeInventory("GrenadeThrowFlagOrWhateverYouNamedIt",999999) //EDIT: gotta remove this or you're stuck in a loop, zero or otherwise
TNT1 A 0 A_Jump(256,"Ready")
GrenadeReallyThrow:
GREN ABC 3 // continue attack
...
Last edited by Matt on Fri Aug 24, 2012 12:58 am, edited 3 times in total.