AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Module Coding (https://forums.alliedmods.net/forumdisplay.php?f=9)
-   -   Module: SemiclipEx (https://forums.alliedmods.net/showthread.php?t=261852)

hzqst 04-22-2015 00:05

Module: SemiclipEx
 
1 Attachment(s)
SemiclipEx

Author: hzqst
Version: 1.0 (no more update maybe)
Description: this module allows player and bullet (traceline) to pass through any entities in condition that decided by amxx plugin author.
Quote:

The semiclip condition could be changed dynamically by amxx.
All kinds of entities could be semiclip, which means terrorists may go through a wall entity but CTs can not.
Linux:
Quote:

you have to compile this module yourself, the Detours library is useless so you can remove them.
I have compiled a sample plugin for you so just
Quote:

put everything from SemiclipEx\ to cstrike\
Example plugin:
PHP Code:

#include <amxmodx>
#include <amxmisc>
#include <fakemeta>
#include <SemiclipEx>

#define PLUGIN "SemiclipEx Test"
#define VERSION "1.0.0"
#define AUTHOR "hzqst"

public PM_ShouldCollide(playerindexentindex)
{
    if(!
is_user_alive(entindex) || playerindex == entindex)
        return 
1;
    if(
get_user_team(playerindex) == get_user_team(entindex))
        return 
0;
    return 
1;
}

public 
ShouldCollide(playerindexentindex)
{
    new 
ret;
    if(!
is_user_alive(entindex) || playerindex == entindex)
        
ret 1;
    else if(
get_user_team(playerindex) == get_user_team(entindex))
        
ret 0;
    else
        
ret 1;
    
forward_return(FMV_CELLret);
    return 
FMRES_SUPERCEDE;
}

public 
AddToFullPack_Post(es_handle,e,ent,host,hostflags,player,pSet)
{
    if(
PM_ShouldCollide(hostent) == 0)
    {
        
set_es(es_handleES_SolidSOLID_NOT);
    }
    return 
FMRES_HANDLED;
}

public 
plugin_init()
{
    
register_plugin(PLUGINVERSIONAUTHOR)
    
    
// Add your code here...
    
SCE_RegisterForward(func_PM_ShouldCollide"PM_ShouldCollide");
    
register_forward(FM_ShouldCollide"ShouldCollide")
    
//Just for client-side prediction
    
register_forward(FM_AddToFullPack,"fw_AddToFullPack_Post",1)



Kia 04-22-2015 01:54

Re: Module: SemiclipEx
 
Sounds interesting, but wasn't this possible with normal AMXX code already or is there really a need for a module?

hzqst 04-22-2015 01:56

Re: Module: SemiclipEx
 
Quote:

Originally Posted by Kia (Post 2288900)
Sounds interesting, but wasn't this possible with normal AMXX code already or is there really a need for a module?

AMXX can't make bullet/traceline semiclip because there is a bug on server-side engine phys code and i fixed it.

yokomo 04-22-2015 02:55

Re: Module: SemiclipEx
 
This is semiclip module too, everything is decided by module, no need an amxx plugin.

Freezo Begin 04-22-2015 09:36

Re: Module: SemiclipEx
 
Thanks for sharing , will try it when i get my computer .

claudiuhks 04-22-2015 11:48

Re: Module: SemiclipEx
 
You should try to get client's team by get_pdata_int(Id, 114 /* Offset CSCZ Team */) - it is safer for mods such Zombie Plague.

baneado 04-27-2015 09:12

Re: Module: SemiclipEx
 
Quote:

Originally Posted by yokomo (Post 2288910)
This is semiclip module too, everything is decided by module, no need an amxx plugin.

Didn't you see the BIG advantage?
On that module you only can set semiclip per team or per all, but it doesn't individually.
Now, with this module you can select the player you want to set semiclip by a var per example.

Continue working on it, it's GREAT :)

lazarev 05-15-2015 23:03

Re: Module: SemiclipEx
 
Just an example how ppl can use this module: https://www.youtube.com/watch?v=7P-Mrw1TrPU


Bugs found:
Quote:

1. Collision no longer work after pausing semiclipex.amxx ( possible solution: send something to module at plugin_pause() )
2. After enabling semiclipex.amxx back, there's no damage from falling until player passes through any team-mate

baneado 06-27-2015 04:08

Re: Module: SemiclipEx
 
Can someone compile this module for linux, please?

Xalus 07-14-2015 17:01

Re: Module: SemiclipEx
 
This looks something I needed last months for finishing my Bomberman,
to bad only window .dll

Could someone fix a linux-compiled version (sorry for bumping thread)..


All times are GMT -4. The time now is 11:30.

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