Author |
Message |
Live(guest) Guest
Offline
|
Posted: Sat Nov 11, 2006 9:48 am Post subject: twcore/sending a message to a specific player |
 |
|
|
|
How can I send a message to a specific player? I understand using sender as a string so the bot sends a message to the player who said something, but in this case I want the bot to send a message to another bot on a specific event.
I just don't quite get the syntax. Is it m_botAction.sendSmartPrivateMessage(playername, "message");
or if I put that does it assume that 'playername' is a string that I should have defined? |
|
Back to top |
|
 |
Cyan~Fire I'll count you!

Age:37 Gender: Joined: Jul 14 2003 Posts: 4608 Location: A Dream Offline
|
Posted: Sat Nov 11, 2006 12:09 pm Post subject: |
 |
|
|
|
SendMessage(player, format, ...)
Oh wait, that's not TWCore. But it's what you should be using.
(Hint: Use ASSS, bots are so 90s.) _________________ 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 |
|
 |
live(guest) Guest
Offline
|
Posted: Sat Nov 11, 2006 3:58 pm Post subject: |
 |
|
|
|
it was
m_botAction.sendSmartPrivateMessage("playername", "message");
 |
|
Back to top |
|
 |
Cerium Server Help Squatter

Age:42 Gender: Joined: Mar 05 2005 Posts: 807 Location: I will stab you. Offline
|
Posted: Sun Nov 12, 2006 12:07 am Post subject: |
 |
|
|
|
Cyan, that's really starting to bug me. As Distort already said once: Bots are no longer on the 'bleeding edge' of subspace technology, but they haven't been phased out yet. Many zones still use subgame and have no intention of switching to ASSS (See: TW and most zones hosted on their server. Also, anyone who tried ASSS and had a bad experience).
Besides, if someone is having trouble doing something as simple as sending a private message to a player with a core that does 99% of the work for you, do you honestly think it's a good idea to try to get them to (a) setup ASSS and (b) write code that will run on the server? _________________ There are 7 user(s) ignoring me right now. |
|
Back to top |
|
 |
Cyan~Fire I'll count you!

Age:37 Gender: Joined: Jul 14 2003 Posts: 4608 Location: A Dream Offline
|
Posted: Sun Nov 12, 2006 10:51 am Post subject: |
 |
|
|
|
Yes, yes I do. People are always stuck in their old ways doing things completely inefficiently, and need a push in the right direction to thing long-term instead of short-term. It would be beneficial for any zone to switch over in the long-run because it will give them the power to do pretty much anything they want (without modifications to the client, of course).
I'll stop if it's bugging a lot of you guys, but sorry, one user's opinion is not enough to change mine. (It's nothing personal.) |
|
Back to top |
|
 |
D1st0rt Miss Directed Wannabe

Age:37 Gender: Joined: Aug 31 2003 Posts: 2247 Location: Blacksburg, VA Offline
|
Posted: Sun Nov 12, 2006 1:00 pm Post subject: |
 |
|
|
|
Where (realistically) are zones supposed to get a development staff capable of working with ASSS? Most have enough trouble with bots as it is.
Someone who is VERY familiar with ASSS once said
Dr Brain wrote: | About switching to ASSS.
Don't do it unless you meet these three requirements:
1.) You need it. This one is very important. Don't move if you want 1 feature it can offer.
2.) You can code. This is a must. You wont find anyone who will do it for you.
3.) Slightly insane. Self explanatory. Usually fufilled by #2.
4.) You have no population to speak of. I made the mistake of not knowing this, and switched while I had a regular population. Only now, 8 months later do I have a population close to what I lost.
If you meet those, you can *think* about moving to ASSS.
|
_________________
 |
|
Back to top |
|
 |
Cerium Server Help Squatter

Age:42 Gender: Joined: Mar 05 2005 Posts: 807 Location: I will stab you. Offline
|
Posted: Sun Nov 12, 2006 7:45 pm Post subject: |
 |
|
|
|
@Cyan:
I find your eagerness to push people to ASSS similar to Linux zealots trying to push people away from Windows. In both cases it can generally be said that the alternative is better, but it also requires a lot more knowledge and work to properly maintain. What good would Linux do someone if they have trouble using Windows? Likewise, what good is ASSS going to do someone if something like the TWCore still gives them trouble?
What further amplifies this point is that the TWCore is by far the easiest core to work with -- it does everything for you. If someone can't make a bot send a message with that, they have no business writting software that runs at the server level.
Cyan wrote: | I'll stop if it's bugging a lot of you guys, but sorry, one user's opinion is not enough to change mine. (It's nothing personal.) |
That's fine, and I take no offense to that. I just felt the need to let you know it was bothering me and why I feel you've gotten a bit excessive with it. |
|
Back to top |
|
 |
Cyan~Fire I'll count you!

Age:37 Gender: Joined: Jul 14 2003 Posts: 4608 Location: A Dream Offline
|
Posted: Mon Nov 13, 2006 1:08 am Post subject: |
 |
|
|
|
I wouldn't compare the switch from Subgame to ASSS like Windows to Linux, it's more like IE to Firefox. You can setup a working server in ASSS very nearly as fast as you can for subgame, and I'd argue that it's actually easier to maintain. Really the only thing Subgame has going for it is all the documentation and expertise lying around.
And I've never actually coded for TWCore, so I can't really compare the ease, but I can say that if you know C, ASSS is a cinch. |
|
Back to top |
|
 |
Cerium Server Help Squatter

Age:42 Gender: Joined: Mar 05 2005 Posts: 807 Location: I will stab you. Offline
|
Posted: Mon Nov 13, 2006 2:14 am Post subject: |
 |
|
|
|
Cyan~Fire wrote: | I wouldn't compare the switch from Subgame to ASSS like Windows to Linux, it's more like IE to Firefox. You can setup a working server in ASSS very nearly as fast as you can for subgame, and I'd argue that it's actually easier to maintain. Really the only thing Subgame has going for it is all the documentation and expertise lying around.
And I've never actually coded for TWCore, so I can't really compare the ease, but I can say that if you know C, ASSS is a cinch. |
You're missing the point: The people who are skilled enough to use ASSS aren't having trouble sending private messages with Java-based bot cores. |
|
Back to top |
|
 |
hellzlaker Registered Cap Buster Popping men in the ass since Oct 2005
Gender: NEVER ENOUGH! Joined: Oct 27 2005 Posts: 34 Offline
|
Posted: Mon Nov 13, 2006 10:46 am Post subject: |
 |
|
|
|
i tried switching to asss but i had following problems
1) how the Beep you login as sysop?!?!?!?!? and after u log in *super?!?!?!?!
2) how the beeep you set settings for ships? i mean its easser to make settings in cfg and then convert it to config then staart of at config!?!?!?!
3) modules dont do as much stuff as mervbot does,
1+2+3=send asss to recycle bin
(ps: im still tryna switch to ass cuz i self host it for now and hosting 4 windows at the same time get annoying =( ) |
|
Back to top |
|
 |
Cyan~Fire I'll count you!

Age:37 Gender: Joined: Jul 14 2003 Posts: 4608 Location: A Dream Offline
|
Posted: Mon Nov 13, 2006 11:01 am Post subject: |
 |
|
|
|
@Cerium: No, I'm not missing the point. I said that I don't know much about TWCore and therefore cannot compare the two. (Anyway, I don't think people who aren't skilled enough to use ASSS should code period, they'll just make bad code.)
@Hellz: Are you sure you actually tried ASSS? It doesn't really sound like it to me...
1. OK, I'll admit this is slightly trickier than subgame just because ASSS doesn't, by default, use a biller. Add yourself to staff.conf, and then, in game, use ?passwd to set your current password so ASSS can actually verify you.
2. Did you read the manual? Settings in ASSS are laid out in per-arena directories in the "arena" subdirectory. Just edit arena.conf in the desired arena. (It uses the same settings as subgame with the exception of some [Misc] and [Flag], if I recall correctly.)
3. You're right, they do more. |
|
Back to top |
|
 |
hellzlaker Registered Cap Buster Popping men in the ass since Oct 2005
Gender: NEVER ENOUGH! Joined: Oct 27 2005 Posts: 34 Offline
|
Posted: Mon Nov 13, 2006 12:00 pm Post subject: |
 |
|
|
|
lol cean i take my words bak lol, i found the file shipwarbird.conf and its just as ez to edit ship settings lol
then i did the passwd thing and now it worked as soon as i enter game im already a sysop, i like this thing beter cuz gets anoying typing *1231321
the bots, for now im gona put bots in my asss zone and when more modules comeout ill replace them
things on top restore=asss =D
the only hard part is how you put lvz in asss |
|
Back to top |
|
 |
Dr Brain Flip-flopping like a wind surfer

Age:39 Gender: Joined: Dec 01 2002 Posts: 3502 Location: Hyperspace Offline
|
Posted: Mon Nov 13, 2006 7:51 pm Post subject: |
 |
|
|
|
As a sysop, ASSS being more complicated is not an excuse. It would be for the average player, but people running zones should be competent . If you can't figure ASSS out, then you shouldn't be developing bots. _________________ Hyperspace Owner
Smong> so long as 99% deaths feel lame it will always be hyperspace to me |
|
Back to top |
|
 |
BDwinsAlt Agurus's Posse

Age:34 Gender: Joined: Jun 16 2003 Posts: 1145 Location: Alabama Offline
|
Posted: Tue Nov 14, 2006 7:47 am Post subject: |
 |
|
|
|
Live isn't the dev guy, he's just having fun playing with bots. Bare with him, he's a newb. (No offense)
Good luck with your bots. If you need any help you know where I stay.
To The Hellz guy: ASSS can do what merv does and more. I've seen some of what ASSS can do that Merv could never do. It's so much easier to do things when it's server-side after you figure everything out.
Practice will help you. Follow the guide and play around with it. Code a few modules. Since you don't seem like a really in depth ASSS guy you probably don't know how to compile C modules for AS3. So since python doesn't have to be compiled, try some of these.
http://wiki.minegoboom.com/index.php/Writing_Modules_In_Python
That will help you with python.
from asss import *
chat = get_interface(I_CHAT)
def c_hello(cmd, params, p, targ):
chat.SendMessage(p, "Hello, " + p.name + ".") //There are better ways to do this.
cmd1 = add_command("hello", c_hello)
|
I wrote this quickly since I'm about to go to school, if you see any errors please correct me. |
|
Back to top |
|
 |
|