Q button and Mirror effect

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
Kagur
Posts: 165
Joined: Fri Mar 14, 2014 12:40 am

Q button and Mirror effect

Post by Kagur »

Some of the most popular mods out there have a Q button for many important functions like kicking. There is also buttons for taunting like the usual F.

My question comes off a bit more complex for these button based actions. Suppose I want 'Q' button to do different things for different classes in my game, or F button does a different taunt for the different classes.

I have thought of making a custom inventory item "taunt' and 'special ability', that acts as a centralized switch button that all character classes respond to. I'm wondering how I can make it so that these two inventory items become parents for an array of 'taunts' and 'special abilities' that correspond to a specific character. A jumpifinventory setup like in each of Brutal Doom's weapons is what I had in mind, but I wish to avoid the chance of one character using another character's taunt or special ability.

What can be the best way to achieve this?

My second question is in regard to a rear view mirror effect I'm trying to make. By pressing Q, one of the characters would go to a state in which he would be able to see whats behind him and in front of him in a split screen like view. I had posted this question on the "How to thread.." and Edward850 gave a helpful response, but I still don't have much to work with on this. If anyone can provide more information, I'll really appreciate it.

Thank you
User avatar
Dancso
Posts: 1906
Joined: Wed Oct 11, 2006 10:39 am
Location: at home.. Status: lazy like hell

Re: Q button and Mirror effect

Post by Dancso »

If you don't mind getting your hands dirty with some ACS, you could try the GetPlayerInput command, using one of the four available custom binds (BT_USER1-4). You'd of course then default-bind it to Q. To do different things based on class, there's the PlayerClass function.

For the mirror effect, you'd have to print the camera texture on the screen using hudMessage with a custom font set to the camera texture. Though if I understood correctly, the mirror image might not be updated until you see the texture in the map physically, which makes the whole idea impossible to pull off. I could be wrong though, do give it a try. I may even try it myself soon as I think it's a pretty cool idea :D
Kagur
Posts: 165
Joined: Fri Mar 14, 2014 12:40 am

Re: Q button and Mirror effect

Post by Kagur »

For the mirror bit, I have just decided to use a chase cam instead. It resolves the issue of looking at what is behind the player. For the Q button special functions for various classes... I'm still working out a solution. :geek:
Locked

Return to “Editing (Archive)”