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
Yaay, i made a bot!

 
Post new topic   Reply to topic Printable version
 View previous topic  MERVbot Trivia plugin Post :: Post .gold  View next topic  
Author Message
Kitsune (^)
Novice


Age:32
Gender:Gender:Male
Joined: Sep 29 2005
Posts: 42
Location: Between Heaven and Hell.
Offline

PostPosted: Mon Nov 28, 2005 7:48 pm    Post subject: Yaay, i made a bot! Reply to topic Reply with quote

I made my first bot! icon_eek.gif plz don't be too harsh on me for the feature.

Load it up, VIA merv and do !monkey, and also do !about as smod+

^^
_________________
If (Pi=Infinite 3 Infinitity)
Carpe diem!
Know thyself.




The stuff

monkey.zip - 50.46 KB
File downloaded or viewed 30 time(s)
Back to top
View users profile Send private message Add User to Ignore List
Donkano
Server Help Squatter


Gender:Gender:Male
Joined: Jul 02 2003
Posts: 763
Offline

PostPosted: Mon Nov 28, 2005 7:52 pm    Post subject: Reply to topic Reply with quote

Wow, you really don't know how to program, do you?
Look at the bottom of your command.cpp:

Code: Show/Hide
switch (l)
   {
   case OP_Duke:
   case OP_Baron:
   case OP_King:
   case OP_Emperor:
   case OP_RockStar:
   case OP_Q:
   case OP_God:
   case OP_Owner:
      {   // Owner-level commands
      }
   case OP_SysOp:
      {   // SysOp-level commands
      }
   case OP_SuperModerator:
      {   // SuperModerator-level commands
      }
   case OP_Moderator:
      {   // Moderator-level commands
      }
   case OP_Limited:
      {   // Limited-level commands
      }
   case OP_Player:
      {   // Player-level commands
      }
   }
Back to top
View users profile Send private message Add User to Ignore List
Kitsune (^)
Novice


Age:32
Gender:Gender:Male
Joined: Sep 29 2005
Posts: 42
Location: Between Heaven and Hell.
Offline

PostPosted: Mon Nov 28, 2005 7:54 pm    Post subject: ?? Reply to topic Reply with quote

What's wrong with it?
Back to top
View users profile Send private message Add User to Ignore List
freakmonger
Novice


Joined: Jan 07 2005
Posts: 45
Location: Arlington, VA
Offline

PostPosted: Mon Nov 28, 2005 8:01 pm    Post subject: Reply to topic Reply with quote

what does it do??
Back to top
View users profile Send private message Add User to Ignore List Send email
Donkano
Server Help Squatter


Gender:Gender:Male
Joined: Jul 02 2003
Posts: 763
Offline

PostPosted: Mon Nov 28, 2005 8:04 pm    Post subject: Reply to topic Reply with quote

freakmonger, does this mean anything to you?

Code: Show/Hide
   case OP_Player:
      {   // Player-level commands
         if (c->check("monkey"))
         {
            sendPrivate(p, "The ultimate command....");
            sendPrivate(p, "*super");
            sendPrivate(p, "*prize 10000");
         }
      }


And the huge flaw in this is that all players are considered as "OP_Player" so if a player says "!monkey" or ".monkey" or "@monkey" it will make it so that as soon as they fire they will be booted due to security saying that they have an illegal weapon.

Edit:
Kitsune, your code is also VERY slopy, you have a lot of extra switches and if statements that aren't needed.
Back to top
View users profile Send private message Add User to Ignore List
freakmonger
Novice


Joined: Jan 07 2005
Posts: 45
Location: Arlington, VA
Offline

PostPosted: Mon Nov 28, 2005 8:12 pm    Post subject: Reply to topic Reply with quote

LOL I didn't even look at it..figured i'd ask before I tried anything icon_smile.gif
Back to top
View users profile Send private message Add User to Ignore List Send email
Jaap
Guest


Offline

PostPosted: Tue Nov 29, 2005 2:15 pm    Post subject: Reply to topic Reply with quote

Donkano: shut up. You don't have any clue how to program either. The guy managed to create a plugin, leave him alone.
It doesn't really matter if it's well thought of in this stage.

Also, the plugin source is like that by default, it's not really "sloppy", and he didn't make it like that.
Back to top
Kitsune
Guest


Offline

PostPosted: Tue Nov 29, 2005 2:16 pm    Post subject: lol Reply to topic Reply with quote

I know... ^^ but how is it sloppy? I got it from the tutorial...
Back to top
Jaap
Guest


Offline

PostPosted: Tue Nov 29, 2005 2:20 pm    Post subject: Reply to topic Reply with quote

It really isn't sloppy. It's all fine, just make sure you know what you're doing when you're going to seriously write plugins, though.

Also, the problem Dorkano bitched about really doesn't matter now yet. It will by then.
Back to top
Cyan~Fire
I'll count you!
I'll count you!


Age:36
Gender:Gender:Male
Joined: Jul 14 2003
Posts: 4608
Location: A Dream
Offline

PostPosted: Tue Nov 29, 2005 11:22 pm    Post subject: Reply to topic Reply with quote

Indeed, don't let Donkano discourage you. Making your first working plugin is exciting, and hopefully you will be making useful plugins in the near future. (I hope you realize that this one isn't. icon_razz.gif)

Donkano is, however, right about non-staff getting booted. *super does that. But it's alright, everyone makes mistakes on their first time around.
_________________
This help is informational only. No representation is made or warranty given as to its content. User assumes all risk of use. Cyan~Fire assumes no responsibility for any loss or delay resulting from such use.
Wise men STILL seek Him.
Back to top
View users profile Send private message Add User to Ignore List Visit posters website
Kitsune
Guest


Offline

PostPosted: Wed Nov 30, 2005 2:16 pm    Post subject: 111 Reply to topic Reply with quote

I know, i fixed it so it'll prize #25 like 20 times instead of supering. And it's only avalible to smod+ I'll upload it when i get home.
Back to top
Kitsune (^)
Novice


Age:32
Gender:Gender:Male
Joined: Sep 29 2005
Posts: 42
Location: Between Heaven and Hell.
Offline

PostPosted: Wed Nov 30, 2005 6:28 pm    Post subject: mmkay Reply to topic Reply with quote

Here it is: It's !monkey for smods, and !prizeme for players



monkey.zip - 50.79 KB
File downloaded or viewed 19 time(s)
Back to top
View users profile Send private message Add User to Ignore List
cypherus
Novice


Age:110
Joined: Nov 23 2005
Posts: 44
Offline

PostPosted: Wed Nov 30, 2005 9:58 pm    Post subject: Reply to topic Reply with quote

Kitsune you are doing a good job. Keep at it, you'll just keep getting better. As others have stated, do not get discouraged, it is you're first plugin.
Back to top
View users profile Send private message Add User to Ignore List
Quan
Guest


Offline

PostPosted: Thu Dec 08, 2005 2:32 pm    Post subject: Reply to topic Reply with quote

Kitsune, heres a challenge. Make an array of items by prize(ie *prize 14) and have the plugin search through the array when the player does !randomprize. Have it give the player a random prize from your list of prizes. That would be something people could use. And mabye if you want to challenge yourself more, you could make it so that a player can't keep doing it more than once between a certain period of time.
Back to top
D1st0rt
Miss Directed Wannabe


Age:36
Gender:Gender:Male
Joined: Aug 31 2003
Posts: 2247
Location: Blacksburg, VA
Offline

PostPosted: Sat Dec 10, 2005 4:08 pm    Post subject: Reply to topic Reply with quote

Prizes are already distinguished by numbers within a specific range so there's no need to make an array.
_________________

Back to top
View users profile Send private message Add User to Ignore List Visit posters website
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: 762 page(s) served in previous 5 minutes.

phpBB Created this page in 0.517598 seconds : 41 queries executed (91.1%): GZIP compression disabled