Advertisement
FlacoBey

Untitled

Jun 14th, 2019
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 1.47 KB | None | 0 0
  1. #pragma semicolon 1
  2. #pragma newdecls required
  3.  
  4. #include <sourcemod>
  5. #include <sdktools>
  6.  
  7. Handle sdkActivatePipe;
  8.  
  9. public Plugin myinfo =
  10. {
  11.     name = "EXPAW2-0",
  12.     author = "BHaType(aka Flaco Bey)",
  13.     description = "Hehe boi",
  14.     version = "0.0",
  15.     url = "https://steamcommunity.com/id/lifehax/"
  16. }
  17.  
  18. public void OnPluginStart()
  19. {
  20.     Handle hGameConf = LoadGameConfigFile("CreatePipeBomb");
  21.     StartPrepSDKCall(SDKCall_Static);
  22.     if( PrepSDKCall_SetFromConf(hGameConf, SDKConf_Signature, "CPipe_Create") == false )
  23.         SetFailState("Could not load the \"CPipe_Create\" gamedata signature.");
  24.     PrepSDKCall_AddParameter(SDKType_Vector, SDKPass_ByRef);
  25.     PrepSDKCall_AddParameter(SDKType_Vector, SDKPass_ByRef);
  26.     PrepSDKCall_AddParameter(SDKType_Vector, SDKPass_ByRef);
  27.     PrepSDKCall_AddParameter(SDKType_Vector, SDKPass_ByRef);
  28.     PrepSDKCall_AddParameter(SDKType_CBasePlayer, SDKPass_Pointer);
  29.     PrepSDKCall_SetReturnInfo(SDKType_CBaseEntity, SDKPass_Pointer);
  30.     sdkActivatePipe = EndPrepSDKCall();
  31.        
  32.     RegConsoleCmd("sm_vomitjar", pipe);
  33. }
  34.  
  35. public Action pipe(int client, int args)
  36. {
  37.     if( !client ) return Plugin_Handled;
  38.  
  39.     float vPos[3], vAng[3];
  40.     GetClientAbsOrigin(client, vPos);
  41.     GetEntPropVector(client, Prop_Data, "m_vecVelocity", vAng);
  42.     vPos[2] -= 84;
  43.     vAng[0] += 100;
  44.     vAng[1] += 100;
  45.     vAng[2] += 800;
  46.     int entity = SDKCall(sdkActivatePipe, vPos, vAng, vAng, vAng, client);
  47.     TeleportEntity(entity, vPos, view_as<float>({0.0, 0.0, 0.0 }), vAng);
  48.     return Plugin_Handled;
  49. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement