What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » [HELP]match New question Solved!

[HELP]match New question Solved!
Author: Message:
DaAniv
Junior Member
**


Posts: 19
31 / Male / Flag
Joined: Jan 2009
O.P. RE: [HELP]match new question
code:
a = Math.floor((Math.random()*(Nouns.length-1)));
b = Math.floor((Math.random()*(VerbsES.length-1)));
d = Math.floor(((Math.random()*16)+14));
e = Math.floor((Math.random()*(Places.length-1)));
f = Math.floor((Math.random()*(PlacesPrepos.length-1)));
g = Math.floor((Math.random()*(Adjectives.length-1)));
//person
if (string.match(/!person/i)){
    c = Math.floor((Math.random()*(Person.length-1)));
    string=string.replace(/!person/i, Person[c])}
//verb
if (!(c==0||c==1||c==2||c==3||string.match(/!i/i)||string.match(/!you/i)||string.match(/!we/i)||string.match(/!they/i)))
    string=string.replace(/!verbs/, VerbsES[b])
else
{
    string=string.replace(/!verbs/i, Verbs[b])
    string=string.replace(/!/g,"")
}
well I want It replace more then one time but every time different number
e.g
string=!person !person
and every person is different but I don't want to use useless loops or anything

This post was edited on 01-24-2009 at 12:25 PM by DaAniv.
01-24-2009 12:19 PM
Profile E-Mail PM Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
[HELP]match New question Solved! - by DaAniv on 01-24-2009 at 09:59 AM
RE: [HELP]match - by Danny22 on 01-24-2009 at 10:16 AM
RE: [HELP]match - by DaAniv on 01-24-2009 at 11:10 AM
RE: [HELP]match - by Matti on 01-24-2009 at 11:11 AM
RE: [HELP]match - by DaAniv on 01-24-2009 at 11:22 AM
RE: [HELP]match Solved - by Danny22 on 01-24-2009 at 11:38 AM
RE: [HELP]match new question - by DaAniv on 01-24-2009 at 12:19 PM
RE: [HELP]match New question - by Matti on 01-24-2009 at 12:49 PM
RE: [HELP]match New question - by DaAniv on 01-24-2009 at 01:44 PM
RE: [HELP]match Solved - by DaAniv on 01-24-2009 at 02:49 PM


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On