Raised This Month: $ Target: $400
 0% 

[TF2] Make Medi Guns not speed boost if healing a scout


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Nursik
Senior Member
Join Date: Jul 2016
Location: In TF2
Old 07-15-2016 , 09:27   [TF2] Make Medi Guns not speed boost if healing a scout
Reply With Quote #1

I need to do that, but i don't know how to properly make that plugin, i don't know what "public Action" should i use.
Code:
#pragma semicolon 1
#include <sourcemod>
#include <sdktools>
#include <sdkhooks>
#include <tf2_stocks>
#include entity

if(class==TFClass_Medic)
{
	int wepindex = GetEntProp(weapon, Prop_Send, "m_iItemDefinitionIndex"); //for weapon index
	if(wepindex == 29)	//medi gun index
	{
					new healtarget=GetHealingTarget(client, true);
					if(IsValidClient(healtarget) && TF2_GetPlayerClass(healtarget)==TFClass_Scout)
					{
						SetEntPropFloat(client, Prop_Send, "m_flMaxspeed", 320);
					}
		
	}
}
It gives me a lot of errors and warnings. ;-;

Last edited by Nursik; 07-15-2016 at 09:28.
Nursik is offline
Arkarr
Veteran Member
Join Date: Sep 2012
Location: Just behind my PC screen
Old 07-15-2016 , 14:26   Re: [TF2] Make Medi Guns not speed boost if healing a scout
Reply With Quote #2

https://wiki.alliedmods.net/Introduc...rcemod_plugins
As I stated in my previous post, also this thread belongs to the "Script" part of the sourcemod's forum. I believe.
__________________
Want to check my plugins ?
Arkarr is offline
Reply



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 04:37.


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