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

[USEFUL] Function list (update)


Post New Thread Reply   
 
Thread Tools Display Modes
The-Killer
Senior Member
Join Date: May 2007
Old 08-04-2007 , 01:54   Re: [USEFUL] Function list
Reply With Quote #11

HOLY SHIT I love you nican!
The-Killer is offline
sskillz
Member
Join Date: Apr 2005
Old 08-04-2007 , 22:03   Re: [USEFUL] Function list
Reply With Quote #12

Great work!
sskillz is offline
Nican
Veteran Member
Join Date: Jan 2006
Location: NY
Old 08-05-2007 , 22:25   Re: [USEFUL] Function list
Reply With Quote #13

I just re-wrote the whole inc-reader

Information should be better now...

Please, if you find any bugs report here
__________________
http://www.nican132.com
I require reputation!
Nican is offline
Send a message via ICQ to Nican Send a message via MSN to Nican
^BuGs^
Senior Member
Join Date: May 2007
Old 08-06-2007 , 01:26   Re: [USEFUL] Function list
Reply With Quote #14

A+!
__________________
Sourcemod Plugin Author and Plugin Approver
"The correct way is MAXPLAYERS + 1"
I will not take bugs/new idea reports over the forums. Please use the issue list.
^BuGs^ is offline
Nican
Veteran Member
Join Date: Jan 2006
Location: NY
Old 08-09-2007 , 00:46   Re: [USEFUL] Function list (update)
Reply With Quote #15

UPDATE!

I added that new Code Highligher, with may help people that are starting SM and they are learning from other scripts

Fixed some bugs in the inc reader, and some other stuff...
__________________
http://www.nican132.com
I require reputation!
Nican is offline
Send a message via ICQ to Nican Send a message via MSN to Nican
bl4nk
SourceMod Developer
Join Date: Jul 2007
Old 08-09-2007 , 21:20   Re: [USEFUL] Function list (update)
Reply With Quote #16

The code highlighter is having some problems with quotes (single and double).
bl4nk is offline
Nican
Veteran Member
Join Date: Jan 2006
Location: NY
Old 08-09-2007 , 21:29   Re: [USEFUL] Function list (update)
Reply With Quote #17

Can you show me the code you put in there?


EDIT:
Do you think I should add a comment system?
__________________
http://www.nican132.com
I require reputation!

Last edited by Nican; 08-10-2007 at 02:10.
Nican is offline
Send a message via ICQ to Nican Send a message via MSN to Nican
bl4nk
SourceMod Developer
Join Date: Jul 2007
Old 08-10-2007 , 15:49   Re: [USEFUL] Function list (update)
Reply With Quote #18

I just pasted the code from my namechanger plugin into it, so:

PHP Code:
/**
* namechanger.sp by bl4nk
* Allows an admin with the 'f' flag to change a player's name.
*
* Thanks to:
*   Extreme_One for requesting the plugin.
*   ferret for his easy-to-copy "client checker" code.
*   theY4Kman for a fix with the single quote bug.
*
* Changelog at http://forums.alliedmods.net/showthread.php?t=58825
*/

#pragma semicolon 1

#include <sourcemod>

#define PLUGIN_VERSION "1.2"

public Plugin:myinfo 
{
    
name "Name Changer",
    
author "bl4nk",
    
description "Change the name of a player",
    
version PLUGIN_VERSION,
    
url "http://forums.alliedmods.net"
};

public 
OnPluginStart()
{
    
LoadTranslations("common.phrases");
    
LoadTranslations("namechanger.phrases");
    
    
CreateConVar("sm_namechanger_version"PLUGIN_VERSION"Name Changer Version"FCVAR_PLUGIN|FCVAR_SPONLY|FCVAR_REPLICATED|FCVAR_NOTIFY);
    
RegAdminCmd("sm_name"Command_NameADMFLAG_SLAY"sm_name <user> <name>");
}

public 
Action:Command_Name(clientargs)
{

    if (
args 2)
    {
        
ReplyToCommand(client"[SM] Usage: sm_name <user> <name>");
        return 
Plugin_Handled;
    }

    new 
String:target[64];
    
GetCmdArg(1targetsizeof(target));

    new 
String:name[64];
    
GetCmdArg(2namesizeof(name));

    
ReplaceString(namesizeof(name), " ' ""'");

    new 
clients[2];
    new 
numClients SearchForClients(targetclients2);
    
    if (
numClients == 0)
    {
        
ReplyToCommand(client"[SM] %t""No matching client");
        return 
Plugin_Handled;
    }
    else if (
numClients 1)
    {
        
ReplyToCommand(client"[SM] %t""More than one client matches");
        return 
Plugin_Handled;
    }
    else if (!
CanUserTarget(clientclients[0]))
    {
        
ReplyToCommand(client"[SM] %t""Unable to target");
        return 
Plugin_Handled;
    }
    else if (
IsFakeClient(clients[0]))
    {
        
ReplyToCommand(client"[SM] %t""Cannot target bot");
        return 
Plugin_Handled;
    }

    new 
player clients[0];

    
PrintToChat(player"[SM] %t""Name Changed");
    
ClientCommand(player"name \"%s\""name);

    return 
Plugin_Handled;

bl4nk is offline
Nican
Veteran Member
Join Date: Jan 2006
Location: NY
Old 08-10-2007 , 16:34   Re: [USEFUL] Function list (update)
Reply With Quote #19

Hmm... Funny
Fixed...

The code worked perfectly on my home server...

Well, sorry for the mix up, now it is fixed...
__________________
http://www.nican132.com
I require reputation!
Nican is offline
Send a message via ICQ to Nican Send a message via MSN to Nican
pRED*
Join Date: Dec 2006
Old 08-10-2007 , 17:54   Re: [USEFUL] Function list (update)
Reply With Quote #20

Wow that's crazily awesome. Code highlighter rocks. <3
pRED* 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 01:42.


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