Raised This Month: $ Target: $400
 0% 

arguments - whats wrong ?


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
MC-Olivenoel
Member
Join Date: Oct 2004
Old 10-20-2004 , 04:49   arguments - whats wrong ?
Reply With Quote #1

Hi

need help with the arguments of a command

first...

****** ****ing arguments ******* ******. this *************** small is n ************ language. ******

ok now lets have a look at the problem



(its n test script....)
Code:
#include <amxmod> #include <amxmisc>   public plugin_init() {  register_plugin("test","073","MC-Olivenoel")  register_clcmd("make_test","maketest",0,"make the test")   } public maketest(id) { new varil0 if (read_argc() == 0) {     //no argument ...     console_print(id,"- no argument = same as make_test 0")     varil0 = 0     return PLUGIN_HANDLED }else{ read_argv(1,varil0,3)   //here is the ************* error ?? } if (varil0 == 0){ //varil0 is 0     client_cmd(id,"say varil0 is 0") return PLUGIN_HANDLED } if (varil0 == 1){ //varil0 is 0     client_cmd(id,"say varil0 is 1") return PLUGIN_HANDLED } if (varil0 == 10){ //varil0 is 0     client_cmd(id,"say varil0 is 10") return PLUGIN_HANDLED } if (varil0 == 200){ //varil0 is 0     client_cmd(id,"say varil0 is 200") return PLUGIN_HANDLED } // here if the argument is wrong     client_cmd(id,"say varil0 is not 0,1,10 or 200")         return PLUGIN_HANDLED }

ok there are lottttts of errors

Code:
(22) : error 035: argument type mismatch (argument 1)
(29) : warning 217: loose indentation
(35) : warning 217: loose indentation
(41) : warning 217: loose indentation
(47) : warning 217: loose indentation
(52) : warning 217: loose indentation
(54) : warning 217: loose indentation
i want that it works... if i make consol commands

make_test
make_test 0
make_test 1
make_test 10
make_test 20
make_test 100
make_test 200
make_test 1000

can someon tell me how to use the "read_argv" in correckt way _??

cucu
MC-Olivenoel is offline
 


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


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