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

[TF2] G-Fortress - 1.0.4a - 2016/4/24


Post New Thread Reply   
 
Thread Tools Display Modes
Author
cheddar
Member
Join Date: Sep 2015
Plugin ID:
5127
Plugin Version:
1.0.4a
Plugin Category:
General Purpose
Plugin Game:
Team Fortress 2
Plugin Dependencies:
Servers with this Plugin:
 
Plugin Description:
Adds TF2 map support to G-mod Maps.
Old 04-09-2016 , 23:31   [TF2] G-Fortress - 1.0.4a - 2016/4/24
Reply With Quote #1


[TF2] G-Fortress
Version 1.0.4a

Description:
This plugin aims to bring plug and play TF2 support to maps designed for Gmod (or potentially other source games). This plugin should require very little technical expertise and should for the most part be fully automated.
**Note, this plugin is for casual/non competitive gameplay. You almost definetely will not spawn in a spawnroom. I would recommend a good uberspawn plugin to help mitigate the likelihood of serious spawn campage.**
Video Demonstration:
https://www.youtube.com/watch?v=WeF-LeLPvbk
Features:
  1. Replaces G-mod spawns with TF2 spawns.
    -- If it finds more than one G-mod spawn it will also begin assigning them equally to red or blue.
  2. Dimensions reduced by 17% for all players
    -- This matches G-Mod size for fitting through doors/passageways. It also can be changed by the cvar "gfortress_size".
  3. Speed reduced by 17% for all players
    -- This matches the players speed with their new dimensions. (See Feature 2)
  4. Jump height reduced by 17% for all players
    -- This matches the players jump height with their new dimensions. (See Feature 2)
  5. +Use activates when you Attack1 OR call for medic(Attack1 by default)
    -- Big thank you to Chdata for his code contribution and the guys at this thread for ideas/support.
  6. Modular Design
    -- Ability to enable/disable each of the above listed features. Controlled via the "gfortress_manage" cvars If you don't want it, disable it.
  7. Automatic enable/disable
    -- This plugin detects if your map is missing TF2 spawns, and doesn't run at all unless it's needed.

Cvars:
  • gfortress_mode | Set G-Fortress Mode | 0 = Force Disabled, 1 = Force Enabled, 2 = Automatic (Recommended) | Default = 2
  • gfortress_zoffset | Controls Z-Offset for spawns. | (Any Float) | Default = 0.25
  • gfortress_size | Controls Default Size/Jump/Speed | (Any Float) | Default = 0.83
  • gfortress_manage_resize | Management of ResizePlayers cvars | 0 = Disabled, 1 = Enabled | Default = 1
  • gfortress_manage_speed | Management of player speed | 0 = Disabled, 1 = Enabled | Default = 1
  • gfortress_manage_jump | Management of player jump | 0 = Disabled, 1 = Enabled | Default = 1
  • gfortress_manage_use | Management of +Use for buttons/doors | 0 = Disabled, 1 = +Use on Attack1, 2 = +Use on Call for Medic | Default = 1
  • gfortress_manage_spawns | Management of spawns | 0 = Disabled, 1 = Enabled | Default = 1

Changelog:
Spoiler


Installation:
  1. You MUST install TF2Attributes
  2. Place G-Fortress.smx into /tf/addonds/sourcemod/plugins folder
    *Don't click "Get Plugin" it will fail to compile because it requires the TF2Attributes include file.
  3. Make sure you set the cvar tf_allow_player_use 1 or doors/buttons may not work!

Plans:
Spoiler


Example Maps:
  • EvoCity_v2d DOWNLOAD
    *Note that I didn't make this map, I merely packed it with materials and models we were missing. If anyone on the EvoCity team wishes me to remove this link please PM me and I will immediately.*

Final Thoughts:
This is the first plugin I've ever released. It will likely have some bugs. I would like the opportunity to learn and grow as a coder through this experience. The SM community is awesome!
Attached Files
File Type: smx G-Fortress.smx (9.2 KB, 605 views)
File Type: sp Get Plugin or Get Source (G-Fortress.sp - 340 views - 9.3 KB)

Last edited by cheddar; 04-24-2016 at 04:51. Reason: 1.0.4a Update
cheddar is offline
WarriorDan007
Senior Member
Join Date: Apr 2014
Location: United States
Old 04-10-2016 , 03:51   Re: [TF2] G-Fortress - 1.0.0 - 2016/4/9
Reply With Quote #2

Really nice-looking mod! I saw and commented on the video. Looks very cool, and may actually revive TF2 a bit, in terms of modded servers!

Question: Would it be possible to release a version of this mod that does not penalize movement speed and jump height, or would this create too many issues? I know you're trying to be authentic, but doing things this way limits some classes, specifically Scout, who is not all that useful when you nerf his movement capabilities. Just my thoughts here.
__________________
WarriorDan007 is offline
Chdata
Veteran Member
Join Date: Aug 2012
Location: Computer Chair, Illinois
Old 04-10-2016 , 03:58   Re: [TF2] G-Fortress - 1.0.0 - 2016/4/9
Reply With Quote #3

Option to replace medic calling with E in addition to the +attack method.
__________________
Chdata is offline
Naydef
Senior Member
Join Date: Dec 2015
Location: Doom Town, Nevada
Old 04-10-2016 , 04:03   Re: [TF2] G-Fortress - 1.0.0 - 2016/4/9
Reply With Quote #4

For the first time I see "CreateEdict()" native in action. What is this native for?
PHP Code:
CreateSpawn(Float:origin[3], Float:angles[3], TFTeam:redblu)
{
    new 
tf2spawn CreateEdict();
    
tf2spawn CreateEntityByName("info_player_teamspawn");
    
DispatchKeyValueVector(tf2spawn"origin"origin);
    
DispatchKeyValueVector(tf2spawn"angles"angles);
    
DispatchSpawn(tf2spawn);
    
SetEntProp(tf2spawnProp_Send"m_iTeamNum"redblu);

__________________
My plugins:
*None for now*


Steam:
naydef

Last edited by Naydef; 04-10-2016 at 13:51.
Naydef is offline
cheddar
Member
Join Date: Sep 2015
Old 04-10-2016 , 07:59   Re: [TF2] G-Fortress - 1.0.0 - 2016/4/9
Reply With Quote #5

Quote:
Originally Posted by WarriorDan007 View Post
Really nice-looking mod! I saw and commented on the video. Looks very cool, and may actually revive TF2 a bit, in terms of modded servers!

Question: Would it be possible to release a version of this mod that does not penalize movement speed and jump height, or would this create too many issues? I know you're trying to be authentic, but doing things this way limits some classes, specifically Scout, who is not all that useful when you nerf his movement capabilities. Just my thoughts here.
Thanks Dan, I just updated the version to 1.0.1 it includes the feature to enable/disable speed control among others. This said, the nerf is applied as a percentage and everyone does not run at the same speed. EVERYONE is nerfed (to 83% of their normal speed) so the scout still is just as fast (from a ratio standpoint) and should not effect gameplay. At least that's been my logic.

Quote:
Originally Posted by Chdata View Post
Option to replace medic calling with E in addition to the +attack method.
I know, I'd like to implement that method, as I said, the method I'm using isn't quite the ideal one that was spoken of in the forums. This is my very first plugin and was taking forever to develop. I just needed to release it. It's not perfect, but it works as is.

Quote:
Originally Posted by Naydef View Post
For the first I see "CreateEdict()" native in action. What is this native for?.
Ahh... you're absolutely right. CreateEdict() is not needed here. It was left over from when I was trying to make entities "stay" when the game began. (Solved by hooking to teamplay_round_start) The updated version removed this unneeded code. Thank you for pointing this out.

Last edited by cheddar; 04-10-2016 at 19:42.
cheddar is offline
341464
Senior Member
Join Date: Dec 2010
Location: GetClientEyePosition
Old 04-10-2016 , 13:04   Re: [TF2] G-Fortress - 1.0.1 - 2016/4/10
Reply With Quote #6

Interesting, might use this in the future.
__________________
341464 is offline
Send a message via Skype™ to 341464
Chdata
Veteran Member
Join Date: Aug 2012
Location: Computer Chair, Illinois
Old 04-11-2016 , 15:04   Re: [TF2] G-Fortress - 1.0.2b - 2016/4/11
Reply With Quote #7

PHP Code:
public OnPluginStart() { AddCommandListener(cdVoiceMenu"voicemenu"); }


public 
Action:cdVoiceMenu(iClient, const String:sCommand[], iArgc)
{
    if (
iArgc 2)
    {
        return 
Plugin_Handled;
    }

    
decl String:sCmd1[3], String:sCmd2[3];
    
    
GetCmdArg(1sCmd1sizeof(sCmd1));
    
GetCmdArg(2sCmd2sizeof(sCmd2));
    
    
// Capture call for medic commands (represented by "voicemenu 0 0")

    
if (sCmd1[0] == '0' && sCmd2[0] == '0')
    {
          
// +use code here
          
return Plugin_Handled;
    }

    return 
Plugin_Continue;

__________________

Last edited by Chdata; 04-11-2016 at 15:05.
Chdata is offline
cheddar
Member
Join Date: Sep 2015
Old 04-11-2016 , 19:11   Re: [TF2] G-Fortress - 1.0.2b - 2016/4/11
Reply With Quote #8

Quote:
Originally Posted by Chdata View Post
PHP Code:
public OnPluginStart() { AddCommandListener(cdVoiceMenu"voicemenu"); }


public 
Action:cdVoiceMenu(iClient, const String:sCommand[], iArgc)
{
    if (
iArgc 2)
    {
        return 
Plugin_Handled;
    }

    
decl String:sCmd1[3], String:sCmd2[3];
    
    
GetCmdArg(1sCmd1sizeof(sCmd1));
    
GetCmdArg(2sCmd2sizeof(sCmd2));
    
    
// Capture call for medic commands (represented by "voicemenu 0 0")

    
if (sCmd1[0] == '0' && sCmd2[0] == '0')
    {
          
// +use code here
          
return Plugin_Handled;
    }

    return 
Plugin_Continue;

Omg, Thank you! I'll be working to integrate tonight!

UPDATE: I've implemented the medic call use method. See what you guys think. I just changed it again so you can choose between Attack1 or Call for Medic to activate +Use

Last edited by cheddar; 04-12-2016 at 04:27.
cheddar is offline
MaloModo
Veteran Member
Join Date: Aug 2008
Old 04-12-2016 , 11:11   Re: [TF2] G-Fortress - 1.0.3a - 2016/4/12
Reply With Quote #9

So maps still have to be bsp?
MaloModo is offline
cheddar
Member
Join Date: Sep 2015
Old 04-12-2016 , 12:15   Re: [TF2] G-Fortress - 1.0.3a - 2016/4/12
Reply With Quote #10

Quote:
Originally Posted by MaloModo View Post
So maps still have to be bsp?
Yes.
cheddar 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 07:09.


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