Player taunting using a hotkey?

Archive of the old editing forum
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.
Locked
User avatar
Graaicko
Posts: 532
Joined: Tue Jun 17, 2014 11:22 pm
Graphics Processor: nVidia (Legacy GZDoom)

Player taunting using a hotkey?

Post by Graaicko »

Hello, was wonding if theres a way to create a player taunting system. I found a bunch of sweet swearing files and would liek to use them as player taunts using a hotkey. I reckon we would need to use acs functions? Thanks.
User avatar
R4L
Global Moderator
Posts: 420
Joined: Fri Mar 03, 2017 9:53 am
Preferred Pronouns: He/Him
Operating System Version (Optional): Windows 11 Pro
Graphics Processor: ATI/AMD with Vulkan/Metal Support
Contact:

Re: Player taunting using a hotkey?

Post by R4L »

Take a look at wildweasel's Diaz wad. You can taunt and aggro enemies with the reload button if you have fists out.
User avatar
Matt
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
Contact:

Re: Player taunting using a hotkey?

Post by Matt »

If you don't want to replace the playerclasses and you don't want to use ZScript (or you don't want this to be dependent on a custominventory item remaining in the player's inventory), ACS will be required.

Here's how it's done in HD:
new keybind defined to a custom command

custom command defined to use a custominventory item

custominventory item given to player at start
(ignore the surrounding code, it's usually better to just do this as a player.startitem or to give the item on an ACS ENTER script (and RESPAWN for deathmatch compatibility) or ZScript PlayerEntered (and PlayerRespawned) event)

custominventory shoots a projectile that calls A_AlertMonsters
(you can just call A_AlertMonsters directly but it's weird to have someone respond to what you say just as you begin talking - there are more efficient ways to create this delay in ZScript now but I won't get into that unless asked)
Locked

Return to “Editing (Archive)”