Raised This Month: $51 Target: $400
 12% 

Hacer entidad solida solo para un team


  
 
 
Thread Tools Display Modes
Author Message
_Pro_
Senior Member
Join Date: Mar 2012
Location: Argentina
Old 07-29-2013 , 01:01   Hacer entidad solida solo para un team
#1

Bueno, estube tratando de hacer una entidad solida para un team, y para el otro no... Le puse un glow que si anda para los tts y para los cts no, pero lo del solido es solido para los 2 teams, ayuda plis D:
PHP Code:
// Gracias roma por el code!

#include <amxmodx>
#include <amxmisc>
#include <fakemeta>
#include <hamsandwich>

#define PLUGIN    "AddToFullPack"
#define AUTHOR    "Gonza.-*"
#define VERSION    "1.0"

new g_ent = -1

public plugin_precache() precache_model("models/Ancestral-Games/Bhop.mdl")

public 
plugin_init()
{
    
register_plugin(PLUGINVERSIONAUTHOR)
    
    
register_clcmd("test""test")
    
    
//register_forward(FM_AddToFullPack, "fw_AddToFullPack")
    
register_forward(FM_AddToFullPack"fw_AddToFullPack"1)
}

public 
fw_AddToFullPack(es_handleeenthosthostflagsplayerpSet)
{
    if (
ent == g_ent/* && is_user_alive(host)*/ && get_user_team(host) == 1)
    {
        
set_es(es_handleES_RenderFxkRenderFxGlowShell)
        
set_es(es_handleES_RenderColor, {25500})
        
        
set_es(es_handleES_SolidSOLID_NOT)
    }
}

public 
test(id)
{
    
g_ent engfunc(EngFunc_CreateNamedEntityengfunc(EngFunc_AllocString"info_target"))
    
    if (!
pev_valid(g_ent)) return
    
    
set_pev(g_entpev_classname"BM_Block")
    
set_pev(g_entpev_solidSOLID_BBOX)
    
    
engfunc(EngFunc_SetModelg_ent"models/Ancestral-Games/Bhop.mdl")
    
engfunc(EngFunc_SetSizeg_entFloat:{-32.0, -32.0, -4.0}, Float:{ 32.032.04.0 })
    
    new 
Float:fOrigin[3]; pev(idpev_originfOrigin)
    
fOrigin[1] -= 60.0
    
    engfunc
(EngFunc_SetOriging_entfOrigin)

_Pro_ is offline
Send a message via MSN to _Pro_ Send a message via Skype™ to _Pro_
DJHD!
Veteran Member
Join Date: Dec 2009
Location: Santiago, Chile
Old 07-29-2013 , 01:11   Re: Hacer entidad solida solo para un team
#2

Porque no simplemente detectas quien la toco y le das el bloqueo respectivo? es mas fácil que usar una función que se ejecuta muchas veces ._.
__________________
Quote:
Originally Posted by XINLEI View Post
Porque rocccos trata de ser el metalicross que nunca va a poder ser.

Last edited by DJHD!; 07-29-2013 at 01:13.
DJHD! is offline
Send a message via MSN to DJHD!
-Fanaticspx1
Senior Member
Join Date: Aug 2010
Location: Venezuela
Old 07-29-2013 , 01:13   Re: Hacer entidad solida solo para un team
#3

-Prueba asi!

PHP Code:
// Gracias roma por el code!

#include <amxmodx>
#include <amxmisc>
#include <fakemeta>
#include <hamsandwich>

#define PLUGIN    "AddToFullPack"
#define AUTHOR    "Gonza.-*"
#define VERSION    "1.0"

new g_ent = -1

public plugin_precache() precache_model("models/Ancestral-Games/Bhop.mdl")

public 
plugin_init()
{
    
register_plugin(PLUGINVERSIONAUTHOR)
    
    
register_clcmd("test""test")
    
    
register_forward(FM_AddToFullPack"fw_AddToFullPack"1)
}

public 
fw_AddToFullPack(es_handleeenthosthostflagsplayerpSet)
{
    if (
ent == g_ent && get_user_team(host) == 1)
    {
    
set_es(es_handleES_RenderFxkRenderFxGlowShell)
    
set_es(es_handleES_RenderColor, {25500})
    }

    
set_es(es_handleES_SolidSOLID_NOT)
}


public 
test(id)
{
        
g_ent engfunc(EngFunc_CreateNamedEntityengfunc(EngFunc_AllocString"info_target"))
    
        if (!
pev_valid(g_ent)) 
     return
    
        
set_pev(g_entpev_classname"BM_Block")
        
set_pev(g_entpev_solidSOLID_BBOX)
    
        
engfunc(EngFunc_SetModelg_ent"models/Ancestral-Games/Bhop.mdl")
        
engfunc(EngFunc_SetSizeg_entFloat:{-32.0, -32.0, -4.0}, Float:{ 32.032.04.0 })
    
        new 
Float:fOrigin[3]; pev(idpev_originfOrigin)
        
fOrigin[1] -= 60.0
    
        engfunc
(EngFunc_SetOriging_entfOrigin)

__________________
DE LOS ERRORES SE APRENDE. ATT: Starsailor

Last edited by -Fanaticspx1; 07-29-2013 at 01:14.
-Fanaticspx1 is offline
Send a message via MSN to -Fanaticspx1 Send a message via Skype™ to -Fanaticspx1
_Pro_
Senior Member
Join Date: Mar 2012
Location: Argentina
Old 07-29-2013 , 02:27   Re: Hacer entidad solida solo para un team
#4

Porque si la toca un tt, y se hace no solida, podran pasar cts tambien, entonses quiero que sea solida para cts, y no solidas para tts.
_Pro_ is offline
Send a message via MSN to _Pro_ Send a message via Skype™ to _Pro_
_Pro_
Senior Member
Join Date: Mar 2012
Location: Argentina
Old 07-29-2013 , 02:27   Re: Hacer entidad solida solo para un team
#5

-Fanaticspx1: Es lo mismo que hice yo, no va a andar, no cambio en nada el code...
_Pro_ is offline
Send a message via MSN to _Pro_ Send a message via Skype™ to _Pro_
-Fanaticspx1
Senior Member
Join Date: Aug 2010
Location: Venezuela
Old 07-29-2013 , 02:47   Re: Hacer entidad solida solo para un team
#6

Probaste como te dije?
__________________
DE LOS ERRORES SE APRENDE. ATT: Starsailor
-Fanaticspx1 is offline
Send a message via MSN to -Fanaticspx1 Send a message via Skype™ to -Fanaticspx1
baneado
Veteran Member
Join Date: Dec 2012
Location: amxmodx-es.com
Old 07-29-2013 , 03:52   Re: Hacer entidad solida solo para un team
#7

debes poner la entidad en SOLID_TRIGGER, luego registras el touch y si es de ese equipo le empujas hacia atrás.

no encontré otra solución
baneado is offline
Neeeeeeeeeel.-
Some Guy Yellin'
Join Date: Jul 2010
Location: Argentina
Old 07-29-2013 , 08:13   Re: Hacer entidad solida solo para un team
#8

En tu propio post tenés la respuesta.
https://forums.alliedmods.net/showpo...39&postcount=4
__________________
Neeeeeeeeeel.- is offline
Send a message via Skype™ to Neeeeeeeeeel.-
alee.cs
Member
Join Date: May 2011
Old 07-29-2013 , 11:58   Re: Hacer entidad solida solo para un team
#9

podrias probar utilizando la base del bm , viste el bloque ct & hay otro que es tt, proba fijandote en esos bloques & trata de adaptarlos
alee.cs is offline
_Pro_
Senior Member
Join Date: Mar 2012
Location: Argentina
Old 07-29-2013 , 17:10   Re: Hacer entidad solida solo para un team
#10

Nel no tengo la respuesta a lo que estoy pidiendo en este post, sino ya lo hubiese hecho.
La forma del BlockMaker no sirve, ya que si es TT la entidad se hace no solida, y cuando esta en no solida puede pasar cualquiera, incluyendo un CT, eso es lo que quiero que no pase u.u
_Pro_ is offline
Send a message via MSN to _Pro_ Send a message via Skype™ to _Pro_
 



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 11:04.


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