AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting (https://forums.alliedmods.net/forumdisplay.php?f=107)
-   -   Furien Mod - Need help converting it to CS GO (https://forums.alliedmods.net/showthread.php?t=288025)

quilhos 09-19-2016 22:01

Furien Mod - Need help converting it to CS GO
 
Hey guys,

First of all I'm making a stable version of furien mod for cs go (ported from cs 1.6), but I'm kind of struggling with some core parts of the plugin.´

If you guys dont mind losing a bit of time helping I would be very grateful.

Making terrorist team invisible I'm using sv_disable_immunity_alpha (I read somewhere that It should make this code work).
Code:

if(IsClientInGame(i) && IsPlayerAlive(i) && GetClientTeam(i) == 2)
{
        keys = GetClientButtons(i);
        if (keys & IN_FORWARD || keys & IN_BACK || keys & IN_MOVELEFT || keys & IN_MOVERIGHT)
        {
                SetEntityRenderMode(i, RENDER_NORMAL);
        }
}
else
{
        SetEntityRenderMode(i, RENDER_NONE);
}

Wallhang
I'm using https://forums.alliedmods.net/showth...ight=wall+walk
I read some topics about it being ported to cs go but didn't find any real fix.

Thx in advanced guys ;)

8guawong 09-20-2016 00:23

Re: Furien Mod - Need help converting it to CS GO
 
if you want transparency you want to do
SetEntityRenderMode(client, RENDER_TRANSCOLOR);
SetEntityRenderColor(client, 255, 255, 255, x)

where x is how transparent you want the client to be

setting SetEntityRenderMode(i, RENDER_NONE) just make the player disappear and you don't need to touch sv_disable_immunity_alpha

for the wallhang you didn't say what needs to be fixed
but maybe https://forums.alliedmods.net/showthread.php?t=265896 is what you are looking for?

quilhos 09-20-2016 12:32

Re: Furien Mod - Need help converting it to CS GO
 
I found a way to make the invisibility work, but it's a little bit redundant.

About the wallhang, in cs go if a player is using wall hang it can walk through the air, like a slow and solid noclip.
I already had read that topic but didnt quite understand how should I fix it. Something to do with tracerays I imagine.

quilhos 09-28-2016 13:21

Re: Furien Mod - Need help converting it to CS GO
 
I completely forgot to post the wallhang script:

PHP Code:

public OnGameFrame()
{
    
//Declare:
    
decl MaxPlayers;

    
//Initialize:
    
MaxPlayers GetMaxClients();

    
//Loop:
    
for(new 1MaxPlayersX++)
    {
        
//Connected:
        
if(IsClientInGame(X) && GetClientTeam(X) == 2)
        {
            
//Alive:
            
if(IsPlayerAlive(X))
            {
                if(
g_Trepar[X])
                {
                    
//Wall?
                    
new bool:NearWall false;

                    
//Circle:
                    
for(new AngleRotate 0AngleRotate 360AngleRotate += 30)
                    {

                        
//Declare:
                        
decl Handle:TraceRay;
                        
decl Float:StartOrigin[3], Float:Angles[3];

                        
//Initialize:
                        
Angles[0] = 0.0;
                        
Angles[2] = 0.0;
                        
Angles[1] = float(AngleRotate);
                        
GetClientEyePosition(XStartOrigin);

                        
//Ray:
                        
TraceRay TR_TraceRayEx(StartOriginAnglesMASK_SOLIDRayType_Infinite);

                        
//Collision:
                        
if(TR_DidHit(TraceRay))
                        {

                            
//Declare:
                            
decl Float:Distance;
                            
decl Float:EndOrigin[3];

                            
//Retrieve:
                            
TR_GetEndPosition(EndOriginTraceRay);

                            
//Distance:
                            
Distance = (GetVectorDistance(StartOriginEndOrigin));

                            
//Allowed:
                            
if(Distance 50NearWall true;

                        }

                        
//Close:
                        
CloseHandle(TraceRay);
                    }

                    
//Ceiling:
                    
decl Handle:TraceRay;
                    
decl Float:StartOrigin[3];
                    new 
Float:Angles[3] =  {270.00.00.0};

                    
//Initialize:
                    
GetClientEyePosition(XStartOrigin);

                    
//Ray:
                    
TraceRay TR_TraceRayEx(StartOriginAnglesMASK_SOLIDRayType_Infinite);

                    
//Collision:
                    
if(TR_DidHit(TraceRay))
                    {
                        
//Declare:
                        
decl Float:Distance;
                        
decl Float:EndOrigin[3];

                        
//Retrieve:
                        
TR_GetEndPosition(EndOriginTraceRay);

                        
//Distance:
                        
Distance = (GetVectorDistance(StartOriginEndOrigin));

                        
//Allowed:
                        
if(Distance 50NearWall true;
                    }

                    
//Close:
                    
CloseHandle(TraceRay);

                    
//Near:
                    
if(NearWall)
                    { 
                        
                        
//Almost Zero:
                        
SetEntityGravity(XPow(Pow(100.03.0), -1.0));

                        
//Buttons:
                        
decl ButtonBitsum;
                        
ButtonBitsum GetClientButtons(X);

                        
//Origin:
                        
decl Float:ClientOrigin[3];
                        
GetClientAbsOrigin(XClientOrigin);

                        
//Angles:
                        
decl Float:ClientEyeAngles[3];
                        
GetClientEyeAngles(XClientEyeAngles);

                        
//Declare:
                        
decl Float:VeloXFloat:VeloYFloat:VeloZ;

                        
//Initialize:
                        
VeloX = (Speed Cosine(DegToRad(ClientEyeAngles[1])));
                        
VeloY = (Speed Sine(DegToRad(ClientEyeAngles[1])));
                        
VeloZ = (Speed Sine(DegToRad(ClientEyeAngles[0])));


                        
//Jumping:
                        
if(ButtonBitsum IN_JUMP)
                        {

                            
//Stop:
                            
new Float:Velocity[3] = {0.00.00.0};
                            
TeleportEntity(XClientOriginNULL_VECTORVelocity);
                        }

                        
//Forward:
                        
if(ButtonBitsum IN_FORWARD)
                        {

                            
//Forward:
                            
new Float:Velocity[3];
                            
Velocity[0] = VeloX;
                            
Velocity[1] = VeloY;
                            
Velocity[2] = (VeloZ - (VeloZ 2));
                            
TeleportEntity(XClientOriginNULL_VECTORVelocity);
                        }

                        
//Backward:
                        
else if(ButtonBitsum IN_BACK)
                        {

                            
//Backward:
                            
new Float:Velocity[3];
                            
Velocity[0] = (VeloX - (VeloX 2));
                            
Velocity[1] = (VeloY - (VeloY 2));
                            
Velocity[2] = VeloZ;
                            
TeleportEntity(XClientOriginNULL_VECTORVelocity);
                        }

                        
//Null:
                        
else 
                        {

                            
//Stop:
                            
new Float:Velocity[3] = {0.00.00.0};
                            
TeleportEntity(XClientOriginNULL_VECTORVelocity);
                        }

                    }

                    
//Default:
                    
else SetEntityGravity(X0.3);    
                }    
            }
        }
    }


The problem is that when a Furien is using WallHang they have a "slower no clip", basicly they can float arround the map, instead of being stuck to the wall.

ESK0 09-28-2016 20:12

Re: Furien Mod - Need help converting it to CS GO
 
Something like this ? :)

quilhos 09-29-2016 15:29

Re: Furien Mod - Need help converting it to CS GO
 
Yes, exacly that. Are you helping or just showing that you have it ^^?

ESK0 09-29-2016 17:39

Re: Furien Mod - Need help converting it to CS GO
 
Well :) I just wanted to show you what i have but im kind today.


Code:

public Action OnPlayerRunCmd(int client, int &buttons, int &impulse, float vel[3], float angles[3], int &weapon, int &subtype, int &cmdnum, int &tickcount, int &seed, int mouse[2])


if(cVb_WallHang == true)
        {
          if(IsClientVIP(client, g_AccType[ACC_EVIP]) || i_bShop[client][Shop_Wallhang] == 1)
          {
            if(buttons & IN_USE && b_ClientWallHang[client] == false)
            {
              float f_FinallVector[3];
              float f_EyePosition[3];
              float f_EyeViewPoint[3];
              GetClientEyePosition(client, f_EyePosition);
              GetPlayerEyeViewPoint(client, f_EyeViewPoint);
              MakeVectorFromPoints(f_EyeViewPoint, f_EyePosition, f_FinallVector);
              if(GetVectorLength(f_FinallVector) < 30)
              {
                b_ClientWallHang[client] = true;
              }
            }
            else if(buttons & IN_JUMP && b_ClientWallHang[client] == true)
            {
              SetEntityMoveType(client, MOVETYPE_WALK);

              float f_cLoc[3];
              float f_cAng[3];
              float f_cEndPos[3];
              float f_vector[3];
              GetClientEyePosition(client, f_cLoc);
              GetClientEyeAngles(client, f_cAng);
              TR_TraceRayFilter(f_cLoc, f_cAng, MASK_ALL, RayType_Infinite, TraceRayTryToHit);
              TR_GetEndPosition(f_cEndPos);
              MakeVectorFromPoints(f_cLoc, f_cEndPos, f_vector);
              NormalizeVector(f_vector, f_vector);
              ScaleVector(f_vector, 320.0);
              TeleportEntity(client, NULL_VECTOR, NULL_VECTOR, f_vector);
              b_ClientWallHang[client] = false;
            }
            if(b_ClientWallHang[client] == true)
            {
              SetEntityMoveType(client, MOVETYPE_NONE);
              float f_Velocity[3] = {0.0, 0.0, 0.0};
              TeleportEntity(client, NULL_VECTOR, NULL_VECTOR, f_Velocity);
            }
          }
        }
      }
public bool TraceRayTryToHit(int entity,int mask)
{
        if(entity > 0 && entity <= MaxClients)
  {
    return false;
  }
        return true;
}
stock bool GetPlayerEyeViewPoint(int client, float pos[3])
{
  float f_Angles[3];
  float f_Origin[3];
  GetClientEyeAngles(client, f_Angles);
  GetClientEyePosition(client, f_Origin);
  Handle h_TraceFilter = TR_TraceRayFilterEx(f_Origin, f_Angles, MASK_SOLID, RayType_Infinite, TraceEntityFilterPlayer);
  if(TR_DidHit(h_TraceFilter))
  {
    TR_GetEndPosition(pos, h_TraceFilter);
    CloseHandle(h_TraceFilter);
    return true;
  }
  CloseHandle(h_TraceFilter);
  return false;
}
public bool TraceEntityFilterPlayer(int iEntity,int iContentsMask)
{
        return iEntity > MaxClients;
}

It should be all :) "i hope"

quilhos 09-30-2016 19:11

Re: Furien Mod - Need help converting it to CS GO
 
It's working, thx a lot mate, I'll make sure that you get credits for it ;)

Pims72 10-21-2016 08:21

Re: Furien Mod - Need help converting it to CS GO
 
Hi !

Then , have you got the furien's mod ? Is it working ? I try to find him since a lot of month... I'm desesperate.

If you can drop me this mod , i will introduce it in france, and put you in credit of server :wink:

See you :p


(sorry for my bad english , i'm french :bee: )


All times are GMT -4. The time now is 02:51.

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