Raised This Month: $32 Target: $400
 8% 

AddToFullPack exchange?


Post New Thread Reply   
 
Thread Tools Display Modes
SpeeDeeR
Veteran Member
Join Date: Mar 2010
Location: Bulgaria
Old 09-01-2015 , 20:06   Re: AddToFullPack exchange?
Reply With Quote #11

Quote:
Originally Posted by NiHiLaNTh View Post
I am not sure, but pev_groupinfo might help.
Quote:
Originally Posted by BeNq! View Post
An example?
https://forums.alliedmods.net/showthread.php?t=205453
https://forums.alliedmods.net/showpo...3&postcount=14
https://forums.alliedmods.net/showthread.php?t=200238
SpeeDeeR is offline
BeNq!
Senior Member
Join Date: Mar 2009
Old 09-02-2015 , 10:17   Re: AddToFullPack exchange?
Reply With Quote #12

Hm:

Code:
#include <amxmodx>
#include <fakemeta>
#include <hamsandwich>

#include <codmod.inc>

new const perk_name[] = "Wykrywacz Metali";
new bool:ma_perk[33];

public plugin_init() {
	register_plugin(perk_name, "2.1", "QTM_Peyote");
	
	cod_register_perk(
		perk_name, 
		"Visible mine"
	);
	
	RegisterHam(Ham_Spawn, "player", "OnCBasePlayer_Spawn_Post", true);
}

public cod_perk_enabled(id){		
	ma_perk[id] = true;
}

public cod_perk_disabled(id)
	ma_perk[id] = false;

public OnCBasePlayer_Spawn_Post(id){
	if(!is_user_connected(id))
		return;
	
	if(!ma_perk[id])
		return;
	
	new classname[5], ent;
	pev(ent, pev_classname, classname, charsmax(classname));
	
	if(!pev_valid(ent))
		return;
	
	if(equal(classname, "mine")){
		set_pev(ent, pev_renderamt, 255); 
	}
}
?
BeNq! is offline
SpeeDeeR
Veteran Member
Join Date: Mar 2010
Location: Bulgaria
Old 09-02-2015 , 20:55   Re: AddToFullPack exchange?
Reply With Quote #13

Quote:
Originally Posted by BeNq! View Post
I'm working with amxx plugin for the Call of Duty modification for CS 1.6 server and I have a question about one class.
The first class has invisibility and the second class can see that first guy.
For now I'm using AddToFullPack function for the second guy to see the first oneinvisible player but it's really hard on the processor usage, it simply executes too many times...
Is there any other function I could use for that kind of check with better optimalization, not so resource heavy?
https://forums.alliedmods.net/showpo...14&postcount=8

Last edited by SpeeDeeR; 09-02-2015 at 20:56.
SpeeDeeR is offline
Depresie
Veteran Member
Join Date: Nov 2013
Old 09-02-2015 , 22:33   Re: AddToFullPack exchange?
Reply With Quote #14

post the code of plugin of the entity you want to set rendering to
Depresie is offline
BeNq!
Senior Member
Join Date: Mar 2009
Old 09-04-2015 , 16:54   Re: AddToFullPack exchange?
Reply With Quote #15

Code:
#include <amxmodx>
#include <fakemeta>
#include <hamsandwich>
#include <engine>

#include <codmod.inc>

#define Mask(%0)    ( 1<<(%0 & 31) )

new const perk_name[] = "Wykrywacz Metali";
new bool:ma_perk[33];

public plugin_init() {
	register_plugin(perk_name, "2.1", "QTM_Peyote");
	
	cod_register_perk(
		perk_name, 
		"Visible mine"
	);
}

public cod_perk_enabled(id){		
	ma_perk[id] = true;
	set_pev( id, pev_groupinfo, Mask(id));
	
	widzenie_miny(id);
}

public cod_perk_disabled(id){
	set_pev(id, pev_groupinfo, pev(id, pev_groupinfo ) & ~Mask( id ) )
	ma_perk[id] = false;
}

public widzenie_miny(id){
	if(!is_user_alive(id))
		return;
	
	if(!ma_perk[id])
		return;
	
	if(!Mask(id))
		return;
	
	client_print(0, print_chat, "MINE - MASK")
		
	new ent = create_entity("info_target");
	
	if(!pev_valid(ent)) // YES
		return;
	
	client_print(0, print_chat, "MINE - VALID") // YES
	
	new mine[5], szClassName[32];
	entity_get_string(ent ,EV_SZ_classname, mine, charsmax(mine))
	
	if(equal(szClassName, "mine")){ // NOT WORK
		set_pev(ent, pev_rendermode, kRenderTransAlpha); 
		set_pev(ent, pev_renderamt, 255.0); 
		client_print(id, print_chat, "MINE - ID")
		client_print(0, print_chat, "MINE - ALL")
	}
	
	client_print(0, print_chat, "MINE - END") // yes 
}
Not working
BeNq! is offline
Depresie
Veteran Member
Join Date: Nov 2013
Old 09-04-2015 , 21:19   Re: AddToFullPack exchange?
Reply With Quote #16

As i said above...
Post the full mine plugin, not the plugin which should set rendering to it
Or else i can't help you >.>
Depresie is offline
BeNq!
Senior Member
Join Date: Mar 2009
Old 09-05-2015 , 04:56   Re: AddToFullPack exchange?
Reply With Quote #17

This is a perk for COD MOD...
BeNq! is offline
BeNq!
Senior Member
Join Date: Mar 2009
Old 09-07-2015 , 11:09   Re: AddToFullPack exchange?
Reply With Quote #18

Help?
BeNq! is offline
BeNq!
Senior Member
Join Date: Mar 2009
Old 09-11-2015 , 14:48   Re: AddToFullPack exchange?
Reply With Quote #19

Help
BeNq! is offline
BeNq!
Senior Member
Join Date: Mar 2009
Old 09-21-2015 , 11:17   Re: AddToFullPack exchange?
Reply With Quote #20

??
BeNq! 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 00:56.


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