Raised This Month: $51 Target: $400
 12% 

[TF2] Homing Projectiles


Post New Thread Reply   
 
Thread Tools Display Modes
Author
Tylerst
Veteran Member
Join Date: Oct 2010
Plugin ID:
2852
Plugin Version:
1.0.0
Plugin Category:
Fun Stuff
Plugin Game:
Team Fortress 2
Plugin Dependencies:
    Servers with this Plugin:
    24 
    Plugin Description:
    Set a target(s) projectiles to home in on the nearest target
    Old 03-28-2012 , 01:29   [TF2] Homing Projectiles
    Reply With Quote #1

    Description: Set a target(s) projectiles to home in on the nearest target

    Just a random plugin a made to mess around with really, but I figured I'd share it.

    Works with:
    Soldier Primarys(Rockets and Laser Cannon)
    Medic Primarys(Needles and Crossbow Arrows)
    Engineer Sentrygun Rockets
    Pyro Flares
    Sniper Arrows
    I was hoping to get it to work with other projectiles like demo grenades/jarate/laser pistol, but unfortunately they seem to be unaffectable for whatever reason.

    I'm not planning to do anything else with this aside from bugfixes, as it was just an experiment(and for fun).


    Cvars:
    sm_homingprojectiles_version "1.0.0"

    Commands:
    sm_homproj "target" "1/0" - Set target(s) projectiles to homing - Default Slay Flag

    Changelog
    Code:
    Version 1.0.0 - March 28, 2012
    *Initial Release
    Attached Files
    File Type: sp Get Plugin or Get Source (TF2 Homing Projectiles.sp - 9584 views - 4.9 KB)

    Last edited by Tylerst; 03-28-2012 at 02:06.
    Tylerst is offline
    ReFlexPoison
    ☠☠☠
    Join Date: Jul 2011
    Location: ☠☠☠
    Old 03-28-2012 , 02:18   Re: [TF2] Homing Projectiles
    Reply With Quote #2

    Is there a specific admin flag for this, or is it for everyone?
    ReFlexPoison is offline
    Tylerst
    Veteran Member
    Join Date: Oct 2010
    Old 03-28-2012 , 02:30   Re: [TF2] Homing Projectiles
    Reply With Quote #3

    The command is the Slay flag, an admin can use the command to set anyone to homing projectiles.

    Last edited by Tylerst; 03-28-2012 at 02:32.
    Tylerst is offline
    ReFlexPoison
    ☠☠☠
    Join Date: Jul 2011
    Location: ☠☠☠
    Old 03-28-2012 , 02:51   Re: [TF2] Homing Projectiles
    Reply With Quote #4

    Quote:
    Originally Posted by Tylerst View Post
    The command is the Slay flag, an admin can use the command to set anyone to homing projectiles.
    Neat. Would be interesting if this could be set as a cvar to enable only for the Flag selected.
    All in all, neat plugin idea
    I'll try it out later tommorow.
    ReFlexPoison is offline
    Leonardo
    Veteran Member
    Join Date: Feb 2010
    Location: 90's
    Old 03-28-2012 , 04:22   Re: [TF2] Homing Projectiles
    Reply With Quote #5

    okay...
    Leonardo is offline
    FlaminSarge
    Veteran Member
    Join Date: Jul 2010
    Old 03-28-2012 , 06:14   Re: [TF2] Homing Projectiles
    Reply With Quote #6

    The OnGameFrame stuff seems kinda taxing on the server.
    Also, is the homing functionality the same as in TF2CoolRocket/ https://forums.alliedmods.net/showpo...3&postcount=11 ? Or does it behave differently?
    __________________
    Bread EOTL GunMettle Invasion Jungle Inferno 64-bit will break everything. Don't even ask.

    All plugins: Randomizer/GiveWeapon, ModelManager, etc.
    Post in plugin threads with questions.
    Steam is for playing games.
    You will be fed to javalia otherwise.
    Psyduck likes replays.
    FlaminSarge is offline
    Tylerst
    Veteran Member
    Join Date: Oct 2010
    Old 03-28-2012 , 06:39   Re: [TF2] Homing Projectiles
    Reply With Quote #7

    Quote:
    Originally Posted by FlaminSarge View Post
    The OnGameFrame stuff seems kinda taxing on the server.
    Also, is the homing functionality the same as in TF2CoolRocket/ https://forums.alliedmods.net/showpo...3&postcount=11 ? Or does it behave differently?
    Regardless of what I use, it'll have to repeat very rapidly to keep tracking. From what I tested of it, it didn't cause any noticable lag/slowdown, even with infinite ammo and setting my rate of fire way up.

    Never saw it before, but that CoolRocket plugin is similar, though the way it does it is different. It uses eyeposition as opposed to client position, and teleportentity instead of setting the direction manually. It also uses sdkhooks to keep track of the rockets, and picks targets differently.

    Similar end result I suppose, though there aren't many different ways you can go about doing homing things.

    Last edited by Tylerst; 03-28-2012 at 06:47.
    Tylerst is offline
    Irrelevant
    Junior Member
    Join Date: Oct 2009
    Old 03-30-2012 , 04:14   Re: [TF2] Homing Projectiles
    Reply With Quote #8

    The projectiles don't check for line of sight and go straight into walls most of the time.
    Irrelevant is offline
    Pirate Jesus
    Member
    Join Date: Aug 2010
    Old 10-16-2012 , 14:41   Re: [TF2] Homing Projectiles
    Reply With Quote #9

    Any way to make the projectiles follow a map's AI nodes until they get within sight of their target?

    It'd make for amusing across the map impossible shots.
    Pirate Jesus is offline
    PieCoPresident
    New Member
    Join Date: Oct 2012
    Old 10-21-2012 , 23:22   Re: [TF2] Homing Projectiles
    Reply With Quote #10

    I love this plugin, but i'm having a bit of trouble. Randomly, the plugin will stop working. It will say i enabled/disabled homing in the chat/console, but it doesn't work. The console spams the error:
    Code:
    L 10/21/2012 - 14:25:57: [SM] Native "IsPlayerAlive" reported: Client 3 is not in game
    L 10/21/2012 - 14:25:57: [SM] Displaying call stack trace for plugin "TF2 Homing Projectiles.smx":
    L 10/21/2012 - 14:25:57: [SM]   [0]  Line 145, /home/groups/alliedmodders/forums/files/9/4/3/2/5/101208.attach::GetClosestTarget()
    L 10/21/2012 - 14:25:57: [SM]   [1]  Line 117, /home/groups/alliedmodders/forums/files/9/4/3/2/5/101208.attach::SetHomingProjectile()
    L 10/21/2012 - 14:25:57: [SM]   [2]  Line 102, /home/groups/alliedmodders/forums/files/9/4/3/2/5/101208.attach::OnGameFrame()
    Sometimes it will start working again, but not for long if it does. Thank you for making this.
    My plugins: Third person, Sentry immunity, God, AdvancedInfiniteAmmo, Ammopacks, MediPacks, RTD, TargetCrits, SDKHooks, and of course this.
    Another note: I have a 2nd server that ill sometimes to use to mess around on MvM or something, and i have the same plugins there. But homing seems to work fine on that server. ( I know its not settings or something, they have pretty much identical files.) Could it be to many people cause it to stop working?
    PieCoPresident 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 20:07.


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