Graal Forums  

Go Back   Graal Forums > Development Forums > Future Improvements
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #16  
Old 08-12-2002, 12:10 PM
Warcaptain Warcaptain is offline
Banned
Warcaptain's Avatar
Join Date: Jun 2001
Location: Virginia, USA
Posts: 2,086
Warcaptain is on a distinguished road
Send a message via ICQ to Warcaptain Send a message via AIM to Warcaptain Send a message via Yahoo to Warcaptain
Quote:
Originally posted by G_yoshi


Eh?

I just fail to see the reason to duplicate an existing command. If it fails to work properly, then post it in the bugs forum Maybe Stefan will go back and make sure it works for the next release
tokenize2 +,bob+went to+have+sex;
#t(0)=bob
#t(1)=went
#t(2)=to
#t(3)=have
#t(4)=sex

MY way
tokenize3 +,bob+went to+have+sex;
#t(0)=bob
#t(1)=went to
#t(2)=have
#t(3)=sex

tokenize3 wouldnt do the ADDITIONAL delimeters it would just simply use new delimeters and remove all old forms.

no spaces etc...
Reply With Quote
  #17  
Old 08-12-2002, 12:13 PM
Warcaptain Warcaptain is offline
Banned
Warcaptain's Avatar
Join Date: Jun 2001
Location: Virginia, USA
Posts: 2,086
Warcaptain is on a distinguished road
Send a message via ICQ to Warcaptain Send a message via AIM to Warcaptain Send a message via Yahoo to Warcaptain
Quote:
Originally posted by Python523

Last I checked when you tokened something in quotes, it took everything inside the quotes as 1 token, I'll check again just to make sure later =/

no..
go on my server and type "/me test,test,test

only test will show up

and somewhere along the line, a line of only test will show up.

it uses #I()

which is same as tokenize2 without using command
Reply With Quote
  #18  
Old 08-12-2002, 12:14 PM
G_yoshi G_yoshi is offline
Forbidden
G_yoshi's Avatar
Join Date: Mar 2001
Posts: 7,206
G_yoshi will become famous soon enough
Send a message via AIM to G_yoshi
Quote:
Originally posted by Warcaptain


tokenize2 +,bob+went to+have+sex;
#t(0)=bob
#t(1)=went
#t(2)=to
#t(3)=have
#t(4)=sex

MY way
tokenize3 +,bob+went to+have+sex;
#t(0)=bob
#t(1)=went to
#t(2)=have
#t(3)=sex

tokenize3 wouldnt do the ADDITIONAL delimeters it would just simply use new delimeters and remove all old forms.

no spaces etc...
Again, you've ignored what I said. If tokenize2 is not working right then report it! Don't be stupid by requesting a new command that is just a complete duplicate of an existing command.
__________________
Reply With Quote
  #19  
Old 08-12-2002, 12:17 PM
G_yoshi G_yoshi is offline
Forbidden
G_yoshi's Avatar
Join Date: Mar 2001
Posts: 7,206
G_yoshi will become famous soon enough
Send a message via AIM to G_yoshi
Quote:
Originally posted by Warcaptain



no..
go on my server and type "/me test,test,test

only test will show up

and somewhere along the line, a line of only test will show up.

it uses #I()

which is same as tokenize2 without using command
#I() is for string arrays string arrays != tokenize2 :x
__________________
Reply With Quote
  #20  
Old 08-12-2002, 12:19 PM
Warcaptain Warcaptain is offline
Banned
Warcaptain's Avatar
Join Date: Jun 2001
Location: Virginia, USA
Posts: 2,086
Warcaptain is on a distinguished road
Send a message via ICQ to Warcaptain Send a message via AIM to Warcaptain Send a message via Yahoo to Warcaptain
Quote:
Originally posted by G_yoshi


#I() is for string arrays string arrays != tokenize2 :x

but its the same as if you did:

tokenize2 ,,#s(stringname);

[which is what i did untill i found out about #I()]
Reply With Quote
  #21  
Old 08-12-2002, 12:21 PM
G_yoshi G_yoshi is offline
Forbidden
G_yoshi's Avatar
Join Date: Mar 2001
Posts: 7,206
G_yoshi will become famous soon enough
Send a message via AIM to G_yoshi
Quote:
Originally posted by Warcaptain



but its the same as if you did:

tokenize2 ,,#s(stringname);

[which is what i did untill i found out about #I()]
Still, if tokenize2 is not working then why have you not reported it? Use your head
__________________
Reply With Quote
  #22  
Old 08-12-2002, 12:30 PM
Warcaptain Warcaptain is offline
Banned
Warcaptain's Avatar
Join Date: Jun 2001
Location: Virginia, USA
Posts: 2,086
Warcaptain is on a distinguished road
Send a message via ICQ to Warcaptain Send a message via AIM to Warcaptain Send a message via Yahoo to Warcaptain
Quote:
Originally posted by G_yoshi


Still, if tokenize2 is not working then why have you not reported it? Use your head

tokenize2 is working....

its dividing things up into delims of spaces and also
NPC Code:

// NPC made by Warcaptain -Leader- (Abaddon)
if (created||timeout) {
setstring test,bob,had,sex today;
tokenize2 ,,#s(test);
for (i=0;i<tokenscount;i++; ){
showimg i,@Kristen ITC@c@Token #v(tokenscount-1-i): #t(tokenscount-1-i),playerx+1.5,playery-(i*1);
changeimgvis i,2;
showimg i+tokenscount,@Kristen ITC@c@Token #v(tokenscount-1-i): #t(tokenscount-1-i),playerx+1.5+.1,playery-(i*1)+.1;
changeimgcolors i+tokenscount,0,0,1,0;
changeimgvis i+tokenscount,1;
}
timeout=0.05;
}



try that out mister muster
Reply With Quote
  #23  
Old 08-12-2002, 12:32 PM
G_yoshi G_yoshi is offline
Forbidden
G_yoshi's Avatar
Join Date: Mar 2001
Posts: 7,206
G_yoshi will become famous soon enough
Send a message via AIM to G_yoshi
Quote:
Originally posted by Warcaptain



tokenize2 is working....

its dividing things up into delims of spaces and also
NPC Code:

// NPC made by Warcaptain -Leader- (Abaddon)
if (created||timeout) {
setstring test,bob,had,sex today;
tokenize2 ,,#s(test);
for (i=0;i<tokenscount;i++{
showimg i,@Kristen ITC@c@Token #v(tokenscount-1-i): #t(tokenscount-1-i),playerx+1.5,playery-(i*1);
changeimgvis i,2;
showimg i+tokenscount,@Kristen ITC@c@Token #v(tokenscount-1-i): #t(tokenscount-1-i),playerx+1.5+.1,playery-(i*1)+.1;
changeimgcolors i+tokenscount,0,0,1,0;
changeimgvis i+tokenscount,1;
}
timeout=0.05;
}



try that out mister muster
*sigh* -_-

Get off your lazy ass and report it if its not working like it is supposed to!
__________________
Reply With Quote
  #24  
Old 08-12-2002, 12:53 PM
G_yoshi G_yoshi is offline
Forbidden
G_yoshi's Avatar
Join Date: Mar 2001
Posts: 7,206
G_yoshi will become famous soon enough
Send a message via AIM to G_yoshi
Now please, stop your complaining. I've done for you what you should've done when you first encountered the problem Next time, please think through all your options first. The last thing needed is a duplicate command
__________________
Reply With Quote
  #25  
Old 08-12-2002, 12:54 PM
Warcaptain Warcaptain is offline
Banned
Warcaptain's Avatar
Join Date: Jun 2001
Location: Virginia, USA
Posts: 2,086
Warcaptain is on a distinguished road
Send a message via ICQ to Warcaptain Send a message via AIM to Warcaptain Send a message via Yahoo to Warcaptain
obviously you arent listening....

it IS working fine.

but i want a command that doesnt use spaces at all when tokenizing.

so you dont do "s around the token to use spaces
Reply With Quote
  #26  
Old 08-25-2002, 12:13 AM
emortylone emortylone is offline
Registered User
Join Date: Apr 2002
Location: Control-NPC
Posts: 834
emortylone is on a distinguished road
Argit. There isn't MUCH point to this... x.X If you feel it is necessary to do this, just use arrays!
setstring client.text,;
addstring client.text,bob;
addstring client.text,went to;
addstring client.text,the market;
That way you get the following:
client.text[0]=bob
client.text[1]=went to
client.text[2]=the market
Simple as that... there isn't a MAJOR purpose for your explanation of tokenize3 either... there are ways around it.
---Shifter
__________________
Quote:
*Stefan: it seems sometimes they hire newbie scripters everywhere x-x
*Stefan: scripters are sometimes like people that draw paintings
*Stefan: all that counts is that it looks nice
Reply With Quote
  #27  
Old 08-25-2002, 03:05 AM
Falcor Falcor is offline
Darth Cucumber
Falcor's Avatar
Join Date: Mar 2001
Location: At School
Posts: 2,874
Falcor is on a distinguished road
Send a message via ICQ to Falcor Send a message via AIM to Falcor Send a message via MSN to Falcor Send a message via Yahoo to Falcor
uhm, Variables can't hold characters. Atleast not in Gscript. I think you have a warped understanding of Graal string arrays.
__________________

subliminal message: 1+1=3
Reply With Quote
  #28  
Old 08-25-2002, 03:28 AM
Warcaptain Warcaptain is offline
Banned
Warcaptain's Avatar
Join Date: Jun 2001
Location: Virginia, USA
Posts: 2,086
Warcaptain is on a distinguished road
Send a message via ICQ to Warcaptain Send a message via AIM to Warcaptain Send a message via Yahoo to Warcaptain
Quote:
Originally posted by Falcor
uhm, Variables can't hold characters. Atleast not in Gscript. I think you have a warped understanding of Graal string arrays.
client.text[0]=int; for numerical arrays is the equivilant of
insertstring client.text,0,alphabetical;
i know i use it alot on enigma for msgsystem
Reply With Quote
  #29  
Old 08-26-2002, 01:03 AM
konidias konidias is offline
Old Bee
konidias's Avatar
Join Date: Jul 2001
Location: Orlando, FL
Posts: 7,222
konidias will become famous soon enough
Send a message via AIM to konidias
LoL GYoshi, you look like a big ass.

tokenize2 does what it is supposed to. He wants a tokenize3 that does not use " " and "," as delimiters. tokenize2 does, but it is supposed to.

But like explained earlier, if you did

string as: Bob "went to the" market

and used tokenize2, it would come out as

token1: Bob
token2: went to the
token3: market

So that is what you wanted, wasn't it?
__________________

Put this image in your sig if you support Bomy Island! (g2k1 revision)
play bomberman while you wait!


Reply With Quote
  #30  
Old 08-27-2002, 11:00 AM
G_yoshi G_yoshi is offline
Forbidden
G_yoshi's Avatar
Join Date: Mar 2001
Posts: 7,206
G_yoshi will become famous soon enough
Send a message via AIM to G_yoshi
Quote:
Originally posted by konidias
LoL GYoshi, you look like a big ass.

tokenize2 does what it is supposed to. He wants a tokenize3 that does not use " " and "," as delimiters. tokenize2 does, but it is supposed to.

But like explained earlier, if you did

string as: Bob "went to the" market

and used tokenize2, it would come out as

token1: Bob
token2: went to the
token3: market

So that is what you wanted, wasn't it?
Sorry...but this thread is a little stale, btw...I saw my error long ago
__________________
Reply With Quote
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 +2. The time now is 09:05 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.