Raised This Month: $ Target: $400
 0% 

[TF2] Forcing Sentry Level


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
ReFlexPoison
☠☠☠
Join Date: Jul 2011
Location: ☠☠☠
Old 11-29-2013 , 23:16   [TF2] Forcing Sentry Level
Reply With Quote #1

Just looking for a way to force a sentry's building level to level 2 once it's built. Setting m_iUpgradeLevel and m_iHighestUpgradeLevel 0.1 seconds after doesn't seem to work. Haven't put much work into just looking for quick response.

Last edited by ReFlexPoison; 11-29-2013 at 23:16.
ReFlexPoison is offline
Dr. Greg House
Professional Troll,
Part-Time Asshole
Join Date: Jun 2010
Old 11-30-2013 , 03:38   Re: [TF2] Forcing Sentry Level
Reply With Quote #2

Try calling this:
Quote:
368 366 CObjectSentrygun::StartUpgrading(void)
First offset is for Linux, second for Windows.
__________________
Santa or Satan?

Watch out when you're paying people for private requests! Most stuff already exists and you can hardly assess the quality of what you'll get, and if it's worth the money.
Dr. Greg House is offline
friagram
Veteran Member
Join Date: Sep 2012
Location: Silicon Valley
Old 11-30-2013 , 06:18   Re: [TF2] Forcing Sentry Level
Reply With Quote #3

Is because when you make the blueprints, its an obj sentry. Try using the event player buildobject or building upgraded, or use a timer onentitycreated that repeats, and set the netprops at the appropriate time. It does work though, pretty sure I did this before.. i changed percentage constructed as well if i recall.
__________________
Profile - Plugins
Add me on steam if you are seeking sp/map/model commissions.
friagram is offline
MasterOfTheXP
Veteran Member
Join Date: Aug 2011
Location: Cloudbank
Old 11-30-2013 , 06:26   Re: [TF2] Forcing Sentry Level
Reply With Quote #4

m_iHighestUpgradeLevel works 100%. Try setting it after the sentry plays the "building finished" sound...although there's hopefully something better to hook at that time, like an event, rather than a sound.
__________________
Plugins / My Steam / TF2 Sandbox (plugin beta testing!)
MasterOfTheXP 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 01:58.


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