Server Help Forum Index Server Help
Community forums for Subgame, ASSS, and bots
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   StatisticsStatistics   RegisterRegister 
 ProfileProfile   Login to check your private messagesLogin to check your private messages   LoginLogin (SSL) 

Server Help | ASSS Wiki (0) | Shanky.com
Bot Question

 
Post new topic   Reply to topic Printable version
 View previous topic  staff plugin for merv Post :: Post Moving LVZ map-objects with a bot, on ...  View next topic  
Author Message
Irapliskin
Newbie


Joined: Mar 12 2007
Posts: 4
Offline

PostPosted: Sun Mar 25, 2007 10:46 pm    Post subject: Bot Question Reply to topic Reply with quote

I was wondering if someone could help me with a question

I want my bot warp everyone to the co-ords i give it when i type !Warpall What do i have to do to do this
Back to top
View users profile Send private message Add User to Ignore List
Animate Dreams
Gotta buy them all!
(Consumer whore)


Age:37
Gender:Gender:Male
Joined: May 01 2004
Posts: 821
Location: Middle Tennessee
Offline

PostPosted: Sun Mar 25, 2007 11:51 pm    Post subject: Reply to topic Reply with quote

Why not do it yourself with a mod command, *warp?
Back to top
View users profile Send private message Add User to Ignore List Send email Visit posters website AIM Address MSN Messenger
BDwinsAlt
Agurus's Posse


Age:34
Gender:Gender:Male
Joined: Jun 16 2003
Posts: 1145
Location: Alabama
Offline

PostPosted: Mon Mar 26, 2007 12:15 am    Post subject: Reply to topic Reply with quote

OMG hey irap! How's it going?
Been a while since you gave me that prorat trojan. icon_biggrin.gif

What I would do if look at the loop like on the merv tutorial:

Code: Show/Hide

// Inside your command already.

_listnode <Player> *parse = playerlist->head;   //set to first link of the player linked list

while (parse)   //parse will be NULL when we reach the last link
{
   Player *p = parse->item;   //item is the actual data stored in the link

   // do functionality here
   // Example 1: sendPrivate(p,"*watchdamage"); // turns on all pilot's watchdamage
   // Example 2: if (p->safety != 0) sendPrivate(p,"*spec"); // spec all pilots in safe zone
         sendPrivate(p, "*warpto %s %s", xcoord, ycoord);  // Might work?
   parse = parse->next;   //set parse to the next link
}


Erm not sure how to split a string in C++. Google to the rescue!

Note: I had no way to test this. I don't even really use C++ or Merv.
Would this work?
Code: Show/Hide

string xcoord;
string ycoord;
. . .
xcoord, ycoord = c->final.split(":");   // Completely guessing here.
Back to top
View users profile Send private message Add User to Ignore List Send email Visit posters website AIM Address Yahoo Messenger MSN Messenger
Maverick
broken record


Age:40
Gender:Gender:Male
Joined: Feb 26 2005
Posts: 1521
Location: The Netherlands
Offline

PostPosted: Mon Mar 26, 2007 3:51 am    Post subject: Reply to topic Reply with quote

My plugin, Generalbot, can do this. (Mervbot)

You can download it here.
_________________
Nickname: Maverick (I changed my name!)
TWCore developer | Subspace statistics
Back to top
View users profile Send private message Add User to Ignore List Visit posters website
Irapliskin
Newbie


Joined: Mar 12 2007
Posts: 4
Offline

PostPosted: Sun Apr 01, 2007 9:00 pm    Post subject: Thanks Reply to topic Reply with quote

Thanks Guys, and Sorry bout that BD, that was a while back when i was a script kiddie tongue.gif anyways. thanks..it worked perfect
Back to top
View users profile Send private message Add User to Ignore List
Witchie NL
Seasoned Helper


Age:35
Gender:Gender:Male
Joined: Jul 24 2005
Posts: 112
Location: Veere, Zeeland, Netherlands
Offline

PostPosted: Mon Apr 02, 2007 3:44 am    Post subject: Reply to topic Reply with quote

Code: Show/Hide

// Inside your command already.

_listnode <Player> *parse = playerlist->head;

while (parse)
{
   Player *p = parse->item;

         sendPrivate(p, "*warpto "+(String)xcoord+" "+(String)ycoord);  // Will work if xcoord and ycoord are decleared as variables

   parse = parse->next;   
}


Code: Show/Hide

String xcoord, ycoord;

ycoord = c->final;
xcoord = ycoord.split(":");   // Leave the right part besides : in ycoord and put the part infront of : in xcoord


This should do the trick.

This should work
Back to top
View users profile Send private message Add User to Ignore List Send email Visit posters website MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    Server Help Forum Index -> Bot Questions All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum
View online users | View Statistics | View Ignored List


Software by php BB © php BB Group
Server Load: 36 page(s) served in previous 5 minutes.

phpBB Created this page in 0.507581 seconds : 30 queries executed (89.1%): GZIP compression disabled