Raised This Month: $ Target: $400
 0% 

how can i get setinfo of strtok string?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
lucky109
Senior Member
Join Date: Jan 2005
Old 06-28-2008 , 01:56   how can i get setinfo of strtok string?
Reply With Quote #1

sample:
Player a's config: setinfo "type" "10 20 30"

how can i get the string of 30 ?
lucky109 is offline
v3x
Veteran Member
Join Date: Oct 2004
Location: US
Old 06-28-2008 , 02:01   Re: how can i get setinfo of strtok string?
Reply With Quote #2

Something like this should work:

PHP Code:
new type[12];
get_user_info(id"type"type11);

new 
type1[3], type2[3], type3[3];
parse(typetype12type22type33);

client_print(idprint_chat"Type 1: %s - Type 2: %s - Type 3: %s"type1type2type3); 
type3 would hold the 3rd argument.
__________________
What am I doing these days? Well, I run my own Rust server. It's heavily modded. If you'd like to join, the ip is 167.114.101.67:28116

I also created a website called Rust Tools. It will calculate and tell you the raw amounts of resources needed to craft items.
v3x is offline
lucky109
Senior Member
Join Date: Jan 2005
Old 06-28-2008 , 03:16   Re: how can i get setinfo of strtok string?
Reply With Quote #3

work fine.
thanks v3x
lucky109 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 19:44.


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