[Resolved] read_argv and contain help plz!
Hi, I am trying to have it so you type "/goto <playername>" and you will go to that players origin. I want it so you don't have to type their full name in though, just some of it. Right now when I type "/goto <their name>" nothing happens. When I just type "/goto", it takes me to 0,0,0 i'm guessing and it shouldn't do anything when I type just /goto.
Here is my code so far... Code:
|
Re: read_argv and contain help plz!
Code:
|
Re: read_argv and contain help plz!
Hey, that doesn't seem to work. Maybe I am reading the wrong arg?
Here is my register_clcmd... Code:
|
Re: read_argv and contain help plz!
You have to hook onto say with clcmd and then check 2 args. Arg1 should be "/goto" and if it is, check the second arg.
|
Re: read_argv and contain help plz!
Here is what I have and it still doesn't work :(
Code:
|
Re: read_argv and contain help plz!
Come to think of it, I am not 100% sure you can read two arguments after say like that, and since I'm not willing to test for it at the moment, here is a different method. See if you can change it to your liking.
Code:
EDIT: Try changing to: read_argv(1, ...) read_argv(2, ...) |
Re: read_argv and contain help plz!
I've tryed everything I could think of the last few hours, and I can't seem to get it to work :(.
|
Re: read_argv and contain help plz!
Tested and works. There ya go:
Code:
|
Re: read_argv and contain help plz!
Thanks very much :) +karma
I didn't know it added quotes @_@ |
| All times are GMT -4. The time now is 06:59. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.