Super-seeker missiles
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Super-seeker missiles
I noticed that regardless of how aggressive you make seeker projectiles, you still have to aim directly at enemies (or just fairly close, with autoaim) for them to have any effect. How would you go about making a seeker projectile that just homes in on the nearest enemy... within reason. I mean, the thing shouldn't fire backwards just because the closest enemy is there. So, I guess, the nearest enemy in a certain "cone" out from the front of the player.
- The NUtcracker
- Posts: 843
- Joined: Sun Jan 14, 2007 9:12 pm
- Location: South Dakota
- Contact:
You can give a monster a very fast movment speed with numerous A_Chase states lasting 1 tic. Give it a melee attack that either instant executes or something that causes it to explode.
You can also try to inheret the Hexen Bloodscourge projectile. It auto-seeks. But it doesnt explode on impact, it kinda goes though or pushes the monsters along. O_o
You can also try to inheret the Hexen Bloodscourge projectile. It auto-seeks. But it doesnt explode on impact, it kinda goes though or pushes the monsters along. O_o
The problem with making it a monster seems to be A_Look... the projectile just kinda floats around while "looking," which looks kinda weird if you want something to keep moving forward while looking.
I messed with the Bloodscourge thing. It did weird stuff and I couldn't really figure it out... like after its death state, it suddenly returns as its spawn state and just sits there and does nothing.
I messed with the Bloodscourge thing. It did weird stuff and I couldn't really figure it out... like after its death state, it suddenly returns as its spawn state and just sits there and does nothing.
I think that Darlos refers to something like Wraithverge (from Hexen).Eriance wrote:You can give a monster a very fast movment speed with numerous A_Chase states lasting 1 tic. Give it a melee attack that either instant executes or something that causes it to explode.
You can also try to inheret the Hexen Bloodscourge projectile. It auto-seeks. But it doesnt explode on impact, it kinda goes though or pushes the monsters along. O_o
Realize that the A_Tracer or simillar projectiles only seeks for one objective.
But you can make a "seeker missile" using this code:
Spoiler: Warning, long code ahead!!!The result of this code should be something like the Wraithverge weapon from hexen.
Well, still... what if there's no enemies around? In that case, I just want it to fly forward like a normal rocket would. During A_Look it just kinda hangs there.
And the wraithverge... ah, there was a cool weapon. It was terrible when those big demon-sorceror guys reflected them back at you, though.
And the wraithverge... ah, there was a cool weapon. It was terrible when those big demon-sorceror guys reflected them back at you, though.
- Ryan Cordell
- Posts: 4349
- Joined: Sun Feb 06, 2005 6:39 am
- Preferred Pronouns: No Preference
- Operating System Version (Optional): Windows 10
- Graphics Processor: nVidia (Modern GZDoom)
- Location: Capital of Explodistan
Code: Select all
print(s:"'big demon-sorceror guy' == Heresiarch.");
Add "A_Wander" in the spawn state, and they should move around randomly.Darlos wrote:Well, still... what if there's no enemies around? In that case, I just want it to fly forward like a normal rocket would. During A_Look it just kinda hangs there.
And the wraithverge... ah, there was a cool weapon. It was terrible when those big demon-sorceror guys reflected them back at you, though.
You maybe need to add the flag "+LOOKALLARROUND".
The Bloodscourge from Hexen seeks out the nearest monster once it gets close enough to one, using P_RoughMonsterSearch. Even Menelkir's attacks aimed at the player will sometimes seek out monsters before homing in on him. If you want to make that kind of homing missile, I'd base it on the Bloodscourge.