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

[Request] Execute File(s) on Clients


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Yerallo
Junior Member
Join Date: Mar 2007
Old 11-21-2007 , 13:30   [Request] Execute File(s) on Clients
Reply With Quote #1

I have been browsing through the approved plugin section and high-traffic plugins and could not find what I am looking for. I was wondering if anyone knows or can make a plugin that allows you to execute a whole while on a certain client/team/all.

There is a plugin that almost does this. Amx_exec is the plugin that does this, however you can execute commands on client but you cannot execute a whole file on the client.

I would really appreciate it if someone could make a plugin or tell me where I can find one that will execute a file on a certain client/team/all so that I can solve client problems at their request (example change rates/set their values right).

Ex: amx_exec aa.cfg "STEAMID"

Thx.
Yerallo is offline
hugz`
Veteran Member
Join Date: Jul 2007
Location: In a house
Old 11-21-2007 , 14:04   Re: [Request] Execute File(s) on Clients
Reply With Quote #2

Was looking for this kind of plugin for a while, but I don't think you can make clients download .cfg files, but there is a way to make a plugin execute a whole bunch of commands, just not sure if there is any around.
__________________
hugz` is offline
Send a message via AIM to hugz`
M249-M4A1
I <3 Mac
Join Date: May 2005
Location: Not interested
Old 11-21-2007 , 16:13   Re: [Request] Execute File(s) on Clients
Reply With Quote #3

Uh... with amx_exec you can do: amx_exec "Player" "exec config.cfg", granted the user has the file
__________________
M249-M4A1 is offline
hugz`
Veteran Member
Join Date: Jul 2007
Location: In a house
Old 11-21-2007 , 16:28   Re: [Request] Execute File(s) on Clients
Reply With Quote #4

But what if I want a certain, custom config executed on the client? You can't force the clients download them, so only way is to actually put the commands and binds in the plugin.
__________________
hugz` is offline
Send a message via AIM to hugz`
purple_pixie
Veteran Member
Join Date: Jun 2007
Location: Winchester, England
Old 11-22-2007 , 04:51   Re: [Request] Execute File(s) on Clients
Reply With Quote #5

Or you just open the file, read through it and execute it line by line.

EDIT: Like so <UNTESTED>:

Code:
/* Plugin generated by AMXX-Studio */ #include <amxmodx> #include <amxmisc> #if !defined charsmax     #define charsmax(%1) sizeof(%1)-1 #endif #define ADMIN_LEVEL ADMIN_CFG public plugin_init() {     register_plugin("File Exec", "1.0", "Pixie")     register_clcmd("amx_execfile","exec_file",ADMIN_LEVEL,"amx_execfile <target> <(server) filename>") } public exec_file(id,level,cid) {     if ( !cmd_access(id,level,cid,3) )     {         console_print(id,"No access / bad parameters")         return PLUGIN_HANDLED ;     }         static target,file[128] ;     static arg1[32],arg2[32] ;         read_argv(1,arg1,charsmax(arg1))         if ( (target = cmd_target(id,arg1) ) == 0 )     {         console_print(id,"Could not find/target %s",arg1)         return PLUGIN_HANDLED ;     }         get_configsdir(file,charsmax(file) ) ;     read_argv(2,arg2,charsmax(arg2)) ;         format(file,charsmax(file),"%s/%s",file,arg2)         if ( !file_exists(file) )     {         console_print(id,"File does not exist: %s",file)         return PLUGIN_HANDLED ;     }         new line,length,text[64] ;     while ( ( line = read_file(file,line,text,charsmax(text),length) ) ) // read each line     {         client_cmd(target,text) ;     }         return PLUGIN_HANDLED ; }

The file to execute should be in the configs directory.

Specify it as if you were currently in that folder.

e.g. "player_config.cfg"

Last edited by purple_pixie; 11-22-2007 at 10:44.
purple_pixie is offline
hugz`
Veteran Member
Join Date: Jul 2007
Location: In a house
Old 11-22-2007 , 09:30   Re: [Request] Execute File(s) on Clients
Reply With Quote #6

So all you do is put the .cfg in FTP's cstrike and execute it on people?
__________________

Last edited by hugz`; 11-22-2007 at 09:32.
hugz` is offline
Send a message via AIM to hugz`
purple_pixie
Veteran Member
Join Date: Jun 2007
Location: Winchester, England
Old 11-22-2007 , 09:46   Re: [Request] Execute File(s) on Clients
Reply With Quote #7

Well in the configs folder, actually.

Then run the amx_execfile command on the player you want to execute it on.
purple_pixie is offline
Alucard^
AMXX Moderator: Others
Join Date: Sep 2007
Location: Street
Old 11-22-2007 , 10:37   Re: [Request] Execute File(s) on Clients
Reply With Quote #8

somebody test this plugin? work?
Alucard^ is offline
Send a message via Skype™ to Alucard^
purple_pixie
Veteran Member
Join Date: Jun 2007
Location: Winchester, England
Old 11-22-2007 , 10:42   Re: [Request] Execute File(s) on Clients
Reply With Quote #9

Should do ;-)

Why not test it?
purple_pixie is offline
Yerallo
Junior Member
Join Date: Mar 2007
Old 11-22-2007 , 23:31   Re: [Request] Execute File(s) on Clients
Reply With Quote #10

will try ty bud.
Yerallo 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 05:00.


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