Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
Katsute authored May 30, 2024
1 parent 95ce16e commit e61e46d
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 52 deletions.
13 changes: 0 additions & 13 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,19 +22,6 @@ jobs:
- name: Compile Plugin
run: spcomp -i addons/sourcemod/include TF100.sp

# - name: Prepare Files
# run: |-
# mkdir addons/sourcemod/scripting
# mv TF100.smx addons/sourcemod/scripting
# mkdir addons/sourcemod/gamedata
# mv tf2.100.txt addons/sourcemod/gamedata

# - name: Deploy to GitHub Releases
# uses: AButler/[email protected]
# with:
# files: "addons/*;item_whitelist.txt"
# repo-token: ${{ secrets.GITHUB_TOKEN }}

- name: Deploy to GitHub Releases
uses: AButler/[email protected]
with:
Expand Down
40 changes: 1 addition & 39 deletions TF100.sp
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
#include <sourcemod>
#include <sdktools>

// ConVar mp_tournament;

static const int len = 32;

static const char entities[32][] = {
Expand Down Expand Up @@ -37,7 +35,6 @@ static const char entities[32][] = {
"move_rope",
"point_spotlight",
"prop_physics_multiplayer",
// "prop_physics_override", // payload
"prop_physics_respawnable",
"prop_physics",
"prop_ragdoll",
Expand Down Expand Up @@ -134,23 +131,6 @@ public void OnPluginStart(){
// Map Entities
for(int i = 0; i < len; i++)
DeleteEntities(entities[i]);

// // Whitelist Patch https://forums.alliedmods.net/showthread.php?t=346702

// mp_tournament = FindConVar("mp_tournament");
// mp_tournament.Flags &= ~FCVAR_NOTIFY;

// Handle gamedata = LoadGameConfigFile("tf2.100");

// // broken ↓
// Handle hookReload = DHookCreateFromConf(gamedata, "ReloadWhitelist");
// DHookEnableDetour(hookReload, false, TournamentEnable);
// DHookEnableDetour(hookReload, true, TournamentDisable);

// // broken ↓
// Handle hookLoadout = DHookCreateFromConf(gamedata, "GetLoadoutItem");
// DHookEnableDetour(hookLoadout, false, TournamentEnable);
// DHookEnableDetour(hookLoadout, true, TournamentDisable);
}

public void OnEntityCreated(int entity, const char[] classname){
Expand All @@ -159,14 +139,6 @@ public void OnEntityCreated(int entity, const char[] classname){
DeleteEntity(entity);
return;
}

// doesn't work b/c model hasn't been set yet
// if(StrEqual(classname, "item_healthkit_small") || StrEqual(classname, "item_healthkit_medium")){
// char model[256];
// GetEntPropString(entity, Prop_Data, "m_ModelName", model, 256);
// if(!StrContains(model, "plate"))
// DeleteEntity(entity);
// }
}

public void DeleteEntity(const int entity){
Expand All @@ -178,14 +150,4 @@ public void DeleteEntities(const char[] classname){
int entity = -1;
while((entity = FindEntityByClassname(entity, classname)) != -1)
DeleteEntity(entity);
}

// MRESReturn TournamentEnable(int entity, DHookReturn hReturn) {
// mp_tournament.SetBool(true, true, false);
// return MRES_Ignored;
// }

// MRESReturn TournamentDisable(int entity, DHookReturn hReturn) {
// mp_tournament.SetBool(false, true, false);
// return MRES_Ignored;
// }
}

0 comments on commit e61e46d

Please sign in to comment.