Jump to content
UBot Underground

change sequence randomly


Recommended Posts

Hey :-)

 

i have 3 lists and with this i can post 3 random links, 1 from each list.

type text(<name="xhpc_message_text">, "{$random list item(%links1)}{$new line}{$random list item(%links2)}{$new line}{$random list item(%links3)}", "Standard")

But can i change the sequence of the links by chance ?

 

random link list 1 --- random link list 2 --- random link list 3

 

and for the next post:

 

random link list 3 --- random link list 2 --- random link list 1

 

and so on.... ??

Link to post
Share on other sites

Thanks for your help. Now I have a new list4 with 3 correct links. But randomly grab the links from that new list4 returns sometimes 1 link 2 or 3 times.

 

I found no option to use and clear the used link (because its grab randomly) or grab every link only one time.

For this now i shuffle the list4 and have a new list5 and use this.

 

Maybe there is a better way, (never i use the sequence link1 - link2 - link3) but it works.  :) 

Link to post
Share on other sites

You can create you own way to do this. I would suggest after using the link you want, add it to a list, and b4 selecting a new link, create a new list subtracting the list of links that have already been used.

 

 

Also you do not have to create a remove list for each set of links.. You can use one for all of them.

Link to post
Share on other sites

Pretty sure this is what you are looking for.. 

 


add list to list(%master links1, %links1, "Delete", "Global")
add list to list(%master links2, %links2, "Delete", "Global")
add list to list(%master links3, %links3, "Delete", "Global")
comment("Can start your loop or w/e below here..")
set(#list1, $random list item(%links1), "Global")
set(#list2, $random list item(%links2), "Global")
set(#list3, $random list item(%links3), "Global")
type text(<name="xhpc_message_text">, "{#list1}{$new line}{#list2}{$new line}{#list3}", "Standard")
add item to list(%remove list, $list from text(#list1, ""), "Delete", "Global")
add item to list(%remove list, $list from text(#list2, ""), "Delete", "Global")
add item to list(%remove list, $list from text(#list3, ""), "Delete", "Global")
clear list(%links1)
clear list(%links2)
clear list(%links3)
add list to list(%links1, $subtract lists(%master links1, %remove links), "Delete", "Global")
add list to list(%links2, $subtract lists(%master links2, %remove links), "Delete", "Global")
add list to list(%links3, $subtract lists(%master links3, %remove links), "Delete", "Global")

There is also another way i thought of doing it with find replace regex.. kinda busy right now.. If this doesn't work, Let me know il try to the other way.. Hope i could help.. :)

 

P.S. i didn't test this. Sorry if it doesn't work :(

  • Like 1
Link to post
Share on other sites

EDIT:  sorry, wrote before read your secound post.. thanks for this, I´ll try it !  :)

 

"after using the link you want, add it to a list"

    add item to list(%list4, $random list item(%links1), "Delete", "Global")
    add item to list(%list4, $random list item(%links2), "Delete", "Global")
    add item to list(%list4, $random list item(%links3), "Delete", "Global")
/* ... now I have list4 with 3 links ... */
    add item to list(%finallinks, $random list item(%list4), "Delete", "Global")
 

I want to use a random link, how can I add this random link to an other (substarcting) list ?

Link to post
Share on other sites

@Security

 

it´s an interesting way, but for an other problem.

 

What i need:

 

I have a list1 with some links:

list1link1   

list1link2   

list1link3   and so on

 

the same with list2:

list2link1   

list2link2   

list2link3 ....

 

and the same with list3...

 

Now i´ll post every hour:

 

1 random link from list  

new line   

1 random link from list2  

new line   

1 random link from list3

 

That´s easy, but the sequence should not be always the same. The next post should be:

 

1 random link from list3  

new line   

1 random link from list1  

new line   

1 random link from list2   

 

I don´t need to remove or clear links, because i use all this links from list1, list2 and list3 over and over again.

 

Sorry for my bad english.  :rolleyes:  Can understand me ?

Link to post
Share on other sites

yes this is why once you are done, once all the links have been used, you just start over.. This is why you have the links stored in "Master links 1, 2, and 3..

Link to post
Share on other sites

This is Assuming Master links 1, 2 and 3 all have the same amount of links in them..

 

This script will post a link from each list, add the links it has already posted to another list ( the remove list) assuring you will not post the same link more then once, From each list of links. It will go through the list, then will wait for 1 hour b4 repeating the process.

ui open file("Load links:", #loadlinks1)
ui open file("Load links:", #loadlinks2)
ui open file("Load links:", #loadlinks3)
add list to list(%master links1, $list from file(#loadlinks1), "Delete", "Global")
add list to list(%master links2, $list from file(#loadlinks2), "Delete", "Global")
add list to list(%master links3, $list from file(#loadlinks3), "Delete", "Global")
loop($list total(%master links1)) {
    load list()
    set(#list1, $random list item(%links1), "Global")
    set(#list2, $random list item(%links2), "Global")
    set(#list3, $random list item(%links3), "Global")
    type text(<name="xhpc_message_text">, "{#list1}{$new line}{#list2}{$new line}{#list3}", "Standard")
    add item to list(%remove list, $list from text(#list1, ""), "Delete", "Global")
    add item to list(%remove list, $list from text(#list2, ""), "Delete", "Global")
    add item to list(%remove list, $list from text(#list3, ""), "Delete", "Global")
    clear list(%links1)
    clear list(%links2)
    clear list(%links3)
    add list to list(%links1, $subtract lists(%master links1, %remove links), "Delete", "Global")
    add list to list(%links2, $subtract lists(%master links2, %remove links), "Delete", "Global")
    add list to list(%links3, $subtract lists(%master links3, %remove links), "Delete", "Global")
    wait(360)
}
define load list {
    add list to list(%master links1, %links1, "Delete", "Global")
    add list to list(%master links2, %links2, "Delete", "Global")
    add list to list(%master links3, %links3, "Delete", "Global")
}

Link to post
Share on other sites

If you would like you could PM me or we could speak on skype. Or you could just post the entire code here.. As long as you are comfortable with me knowing exactly what you are doing, i dnt think it would be to hard for me to fix this for you. I'm almost 1000% sure i know what you are trying to do. I have a few minutes now to help.. Let me know ..

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...