Raised This Month: $32 Target: $400
 8% 

[TF2 MvM] Destroy/Edit The Tank via SM


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Potato Uno
Veteran Member
Join Date: Jan 2014
Location: Atlanta, Georgia
Old 08-28-2015 , 11:06   [TF2 MvM] Destroy/Edit The Tank via SM
Reply With Quote #1

So I want an admin command called "sm_destroy_tank" that will scan the map for all active tank entities and either:

(A) Force the tank that the admin wants destroyed to explode
(B) Change the health of the tank (raise it, lower it, etc)

So this code would find all the active tanks on the map:

PHP Code:
int iEntity = -1;
while ((
iEntity FindEntityByClassname(iEntity"tank_boss")) != -1)
{
    
// Something goes here?

What commands (like AcceptEntityInput) do I need to call to make the tank explode? What netprop (SetEntProp) do I need to call to change the tank's health?

Datamaps:

Spoiler


Netprops:

Spoiler


Thanks for any and all help!

EDIT: I do see this on the datamaps dump:

PHP Code:
InputSetSpeed (Input)(0 Bytes) - SetSpeed
InputSetHealth (Input)(0 Bytes) - SetHealth
InputSetMaxHealth (Input)(0 Bytes) - SetMaxHealth
InputAddHealth (Input)(0 Bytes) - AddHealth
InputRemoveHealth (Input)(0 Bytes) - RemoveHealth 
I have no idea how to trigger them or use them. I also still cannot find the tank explosion trigger either.

The sv_cheats 1 command tf_mvm_tank_kill will force a tank on the map to explode, so that's something I want to write an SM command alias of (but with more options).

Last edited by Potato Uno; 08-28-2015 at 11:09.
Potato Uno is offline
 


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 19:37.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode