Aiming Custom Projectiles ACS

Discuss all aspects related to modding Zandronum here.
Post Reply
User avatar
nambona890
Banned
Posts: 31
Joined: Sat Aug 02, 2014 9:38 am
Location: Australia
Clan Tag: [BAF]
Banned: Permanently

Aiming Custom Projectiles ACS

#1

Post by nambona890 » Sat Aug 23, 2014 12:11 pm

So what I'm trying to do is fire a custom projectile at a player using SpawnProjectile, but I don't know how to get it to aim at the player each time. There might be a trick with angles that I do not know about, but I would like some help please.

User avatar
Ænima
Addicted to Zandronum
Posts: 3583
Joined: Tue Jun 05, 2012 6:12 pm

RE: Aiming Custom Projectiles ACS

#2

Post by Ænima » Sat Aug 23, 2014 3:23 pm

Reinforcements: midgame Survival joining/respawning
Doom64: Unabsolved: Doom64 + Diablo II
ZandroSkins: a pack made by our community
AeniPuffs: 3D blood and bullet puff effects, free to use for your own mods
Squad Radio: a WASD-based radio chat menu, add your own custom sounds!
Mercenaries (on hold)
Image

User avatar
ZZYZX
Posts a lot
Posts: 742
Joined: Thu Jun 07, 2012 5:56 pm
Location: Ukraine
Clan: A3
Clan Tag: [A3]

RE: Aiming Custom Projectiles ACS

#3

Post by ZZYZX » Sat Aug 23, 2014 8:10 pm

Didn't he say CUSTOM projectiles? And Thing_ProjectileAimed in ZDoom prior to 2.7.1 requires a spawnid which can't be assigned to custom actors.

User avatar
Ænima
Addicted to Zandronum
Posts: 3583
Joined: Tue Jun 05, 2012 6:12 pm

RE: Aiming Custom Projectiles ACS

#4

Post by Ænima » Sat Aug 23, 2014 8:44 pm

Circunei Z wrote: Didn't he say CUSTOM projectiles? And Thing_ProjectileAimed in ZDoom prior to 2.7.1 requires a spawnid which can't be assigned to custom actors.
Whoops, my bad. Sorry. I've honestly never tried to spawn a custom projectile with that function. :p


You could always just spawn a custom invisible DECORATE actor that A_FaceTarget's the player and fires your projectile instantly.
Reinforcements: midgame Survival joining/respawning
Doom64: Unabsolved: Doom64 + Diablo II
ZandroSkins: a pack made by our community
AeniPuffs: 3D blood and bullet puff effects, free to use for your own mods
Squad Radio: a WASD-based radio chat menu, add your own custom sounds!
Mercenaries (on hold)
Image

User avatar
nambona890
Banned
Posts: 31
Joined: Sat Aug 02, 2014 9:38 am
Location: Australia
Clan Tag: [BAF]
Banned: Permanently

RE: Aiming Custom Projectiles ACS

#5

Post by nambona890 » Sun Aug 24, 2014 2:28 am

Ænima wrote:
Circunei Z wrote: Didn't he say CUSTOM projectiles? And Thing_ProjectileAimed in ZDoom prior to 2.7.1 requires a spawnid which can't be assigned to custom actors.
Whoops, my bad. Sorry. I've honestly never tried to spawn a custom projectile with that function. :p


You could always just spawn a custom invisible DECORATE actor that A_FaceTarget's the player and fires your projectile instantly.
Ok, even though it's a bit tacky doing that, i'll try it.

User avatar
nambona890
Banned
Posts: 31
Joined: Sat Aug 02, 2014 9:38 am
Location: Australia
Clan Tag: [BAF]
Banned: Permanently

RE: Aiming Custom Projectiles ACS

#6

Post by nambona890 » Sun Aug 24, 2014 4:51 am

http://puu.sh/b5sHZ/7c0fe6648a.wad Well I got it sort of done, here is the bare basis of it.

ZzZombo
Forum Regular
Posts: 323
Joined: Mon Jun 11, 2012 12:11 pm
Location: Ravenholm

RE: Aiming Custom Projectiles ACS

#7

Post by ZzZombo » Sun Aug 24, 2014 10:23 am

You can just give the player an CustomInventory that will launch the projectile:

Code: Select all

actor PlayerMissileHelper:CustomInventory
{
	States
	{
		Pickup:
		TNT1 A 0 A_CustomMissile/A_FireCustomMissile(your params)
		stop
	}
}
//ACS
script 3000 RESPAWN//correct it as you need.
{
	GiveInventory("PlayerMissileHelper",1);
}
QZRcon - Qt-based tool for Zandronum/Skulltag servers!
#grandvoid funny stats

User avatar
nambona890
Banned
Posts: 31
Joined: Sat Aug 02, 2014 9:38 am
Location: Australia
Clan Tag: [BAF]
Banned: Permanently

RE: Aiming Custom Projectiles ACS

#8

Post by nambona890 » Sun Aug 24, 2014 10:51 am

ZzZombo wrote: You can just give the player an CustomInventory that will launch the projectile:

Code: Select all

actor PlayerMissileHelper:CustomInventory
{
	States
	{
		Pickup:
		TNT1 A 0 A_CustomMissile/A_FireCustomMissile(your params)
		stop
	}
}
//ACS
script 3000 RESPAWN//correct it as you need.
{
	GiveInventory("PlayerMissileHelper",1);
}
I was talking about have a missile fire at the player from a different source, but never mind, I got it done. It is on my latest terrywad called usewdept. Check it out when Ty puts it into newstuff.

Post Reply