Raised This Month: $ Target: $400
 0% 

make entity not collide with anything


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
mammapappa
Member
Join Date: Nov 2008
Old 02-27-2015 , 18:28   make entity not collide with anything
Reply With Quote #1

this is what i did but it collides with some walls still
PHP Code:
if(IsValidBlock(i) && g_bGroups[client][i])
{
              
SetEntityMoveType(iMOVETYPE_VPHYSICS);
              
AcceptEntityInput(i"enablemotion");

              
//what can i do instead of this so the entity doesnt collide with anything at all?
              
SetEntProp(iProp_Data"m_CollisionGroup"1); 


Last edited by mammapappa; 02-28-2015 at 07:24.
mammapappa is offline
Michalplyoutube
Veteran Member
Join Date: Jan 2013
Location: Tank Carrier in Mannhatt
Old 03-01-2015 , 11:09   Re: make entity not collide with anything
Reply With Quote #2

Quote:
Originally Posted by mammapappa View Post
this is what i did but it collides with some walls still
PHP Code:
if(IsValidBlock(i) && g_bGroups[client][i])
{
              
SetEntityMoveType(iMOVETYPE_VPHYSICS);
              
AcceptEntityInput(i"enablemotion");

              
//what can i do instead of this so the entity doesnt collide with anything at all?
              
SetEntProp(iProp_Data"m_CollisionGroup"1); 

Try

DispatchKeyValue(i, "solid", "0");
__________________
The plugin developer of TF2BWR Reborn
And a TF2 Player
Michalplyoutube is offline
mammapappa
Member
Join Date: Nov 2008
Old 03-01-2015 , 17:10   Re: make entity not collide with anything
Reply With Quote #3

this works in the way that the entity has no collision but when i release the entity still has 0 collision and i cant interract with the entity anymore

this is how i tried it
PHP Code:
public Action:Command_grab(clientargs)
{
    if(
g_iDragEnt[client] == 0)
    {
        new 
ent GetClientAimTarget(clientfalse);
        if(
IsValidBlock(ent))
        {
            
g_iDragEnt[client] = ent;
            if(
g_bGroups[client][g_iDragEnt[client]])
            {
                for(new 
i=0;i<2048;++i)
                {
                    if(
IsValidBlock(i) && g_bGroups[client][i])
                    {
                        
SetEntityMoveType(iMOVETYPE_VPHYSICS);
                        
AcceptEntityInput(i"enablemotion");
                        
DispatchKeyValue(i"solid""0");
                    }
                }
            }
            else
            {
                
SetEntityMoveType(g_iDragEnt[client], MOVETYPE_VPHYSICS);
                
AcceptEntityInput(g_iDragEnt[client], "enablemotion");
                
DispatchKeyValue(g_iDragEnt[client], "solid""0");
            }
        }
    }
    else
    {
        new 
Float:fVelocity[3] = {0.00.00.0};
        
TeleportEntity(g_iDragEnt[client], NULL_VECTORg_fAngles[g_iDragEnt[client]], fVelocity);
        if(
g_bGroups[client][g_iDragEnt[client]])
        {
            for(new 
i=0;i<2048;++i)
            {
                if(
IsValidBlock(i) && g_bGroups[client][i])
                {
                    
SetEntityMoveType(iMOVETYPE_NONE);
                    
AcceptEntityInput(i"disablemotion");
                    
DispatchKeyValue(i"solid""1");
                }
            }
        }
        else
        {
            
SetEntityMoveType(g_iDragEnt[client], MOVETYPE_NONE);
            
AcceptEntityInput(g_iDragEnt[client], "disablemotion");
            
DispatchKeyValue(g_iDragEnt[client], "solid""1");
        }
        
g_iDragEnt[client] = 0;
    }


Last edited by mammapappa; 03-01-2015 at 17:11.
mammapappa 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 14:17.


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