Monthly Target: $400 Donations: $140
 35% 

[STOCK] zp_get_user_human


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
edon1337
Penguin Enthusiast
Join Date: Jun 2016
Location: Macedonia
Old 02-11-2017 , 19:33   [STOCK] zp_get_user_human
Reply With Quote #1

.: Description :.
Quote:
This stock checks if user is human. Returns true on success and false on fail.
.: Stock :.
PHP Code:
stock zp_get_user_human(id) {
    
    if(!
zp_get_user_survivor(id) && !zp_get_user_zombie(id) && !zp_get_user_nemesis(id)) 
    return 
true;
    
    return 
false;

.: Usage :.
PHP Code:
#include <amxmodx>
#include <zombieplague>

#define PLUGIN "[STOCK] zp_get_user_human"
#define VERSION "1.0"
#define AUTHOR "DoNii"


public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
}

public 
zp_user_humanized_post(id) {
    
    if(
zp_get_user_human(id)) 
    
client_print(idprint_chat"You're A Human");
}

stock zp_get_user_human(id) {
    
    if(!
zp_get_user_survivor(id) && !zp_get_user_zombie(id) && !zp_get_user_nemesis(id)) 
    return 
true;
    
    return 
false;

__________________
edon1337 is offline
Relaxing
Senior Member
Join Date: Jun 2016
Location: California, USA
Old 02-12-2017 , 16:32   Re: [STOCK] zp_get_user_human
Reply With Quote #2

Is this a thing? *never messed around with zp*
Attached Files
File Type: inc zp_get_user_human.inc (280 Bytes, 9 views)
File Type: sma Get Plugin or Get Source (test.sma - 6 views - 547 Bytes)
__________________
Have A Relaxing Day
Relaxing is offline
edon1337
Penguin Enthusiast
Join Date: Jun 2016
Location: Macedonia
Old 02-12-2017 , 16:54   Re: [STOCK] zp_get_user_human
Reply With Quote #3

You don't need a new include file for a simple stock.
__________________
edon1337 is offline
Reply


Thread Tools
Display Modes

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 23:36.


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