Item_powerup

zahndah

professional letter
aa
Jul 4, 2015
721
642
Your map needs to be in mannpower mode for this to work. To enable mannpower mode type in the console, sv_cheats 1, then tf_powerup_mode 1.
 

Zeklyn

L2: Junior Member
Jul 30, 2016
80
21
If you're using a server hoster remember to change the server config or it wont be saved
 

killohurtz

Distinction in Applied Carving
aa
Feb 22, 2014
1,016
1,277
The trigger_add_tf_player_condition entity might be a good alternative since it's "hard-coded" into the map, works independently from cvars like sv_cheats, and (I think) can be disabled for bots. You can get mostly the same effects, but it'll take a bit more work to set them up. I can go into more detail if this sounds like something you want.
 

TravisTouchdown

L2: Junior Member
Apr 15, 2013
68
5
The trigger_add_tf_player_condition entity might be a good alternative since it's "hard-coded" into the map, works independently from cvars like sv_cheats, and (I think) can be disabled for bots. You can get mostly the same effects, but it'll take a bit more work to set them up. I can go into more detail if this sounds like something you want.


Ok could you. I tried entering the tf_powerup_mode 1 command into the server console and it says it not compatable with MVM.
 

killohurtz

Distinction in Applied Carving
aa
Feb 22, 2014
1,016
1,277
These will work a little differently than Mannpower powerups since they can't be dropped/picked up again like flags, so this mini-tutorial assumes you're fine with putting them in fixed locations and using a "respawn" timer.

First you'll need to create these 2 entities and set some keyvalues:
  • trigger_add_tf_player_condition: place this where you want the powerup to be
    • Condition: 5 for uber, 11 for crit (full list)
    • Duration: however long you want it to last
  • prop_dynamic: for the visual representation
    • Name: anything (unique to the powerup)
    • Model: one of the Mannpower icons (filter for "powerup")
    • Collisions: Not Solid
    • Default Animation: spin
Then go to the trigger's outputs and add these four things:
  • OnStartTouch | !self | Disable | 0.00
  • OnStartTouch | !self | Enable | <desired respawn time in seconds>
  • OnStartTouch | <name of prop> | Disable | 0.00
  • OnStartTouch | <name of prop> | Enable | <desired respawn time in seconds>
Lastly, switch to the trigger's Flags tab and check Clients and Disallow Bots.

I can also go through randomizing powerup spawn locations if you'd like.
 

Powerlord

L3: Member
May 8, 2010
127
60
Crit and Uber already work differently from normal Mannpower runes.

Crit respawned evey 60 seconds and lasted 30 seconds.
Uber respawned every 180 seconds and lasted 30 seconds.

Having said that, I think Valve largely removed those two powerups in favor of the Revenge powerup, which is a Crit powerup that only spawned if the the game was "significantly unbalanced" meaning that the other team had a significantly greater percentage of the normal runes than your team did.

Not that the last part would matter if you're putting them in MvM.

Useless Side note: In MannPower mode, the actual runes are item_powerup_rune and item_powerup_rune_temp (for Uber/Crit), but there is no way to directly set the rune types as it's not an exposed property. Instead, you had to use item_powerup_crit, item_powerup_uber, and info_powerup_spawn points to spawn them.
 
Last edited:

killohurtz

Distinction in Applied Carving
aa
Feb 22, 2014
1,016
1,277
Yes, both of these entities exist all the time, but disabling them just makes them invisible/inactive until re-enabled, simulating a "respawn" time. The trigger is the one giving players the powerup, while the prop does nothing but show players where the trigger is (because triggers are always invisible in-game).