Please download and have a look at "queuetest.txt" to get an idea on how you can use the Queue System.
The parts related to your script would summarized be:
For putting players in the queue, lets say we pick event #1
prontera,155,189,4 script<tab>Queue<tab>123,{
// Check party size
getpartymember(getcharid(1));
if($@partymembercount != 2){ // If the party is not of size 2
close;
}
// Put them in the queue
set @result, callfunc("push", 1, 1, 0, 0);
if(@result == 0){
mes "Your party has entered the queue";
}
close;
}
For getting people from the queue, still event #1
while(true){
while(callfunc("pull", 1, 1, 2, 1)) sleep 100; // Keep pulling untill we don't have an error
set .@queue_size, $@queue_size;
copyarray .@queue[0], $@queue[0], .@queue_size;
// We now have AID of 2 people who are in the same party
// in the array .@queue (.@queue[0] and .@queue[1])
// Now we could warp them
for(set .@i, 0; .@i < .@queue_size; set .@i, .@i + 1){
if(attachrid(.@queue[.@i])){
warp "Izlude", 0, 0;
}
}
}