mIRC Home    About    Download    Register    News    Help

Print Thread
#255436 22/10/15 07:18 PM
Joined: Oct 2015
Posts: 8
C
Ceidus Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
C
Joined: Oct 2015
Posts: 8
Hi !

I need a little help. I'm a noob in scripting, really, and don't know how made that I want. That's the script :
Code:
on *:TEXT:$me prend $$1 pour cible*:#: {
  var %rr = $rand(1,6)
  .timer 1 2 describe mets 1 balle dans le barillet puis le fait tourner
  .timer 1 2 describe vise $$1 et tire !
  if (%rr == 1) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
  if (%rr == 4) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
  if (%rr == 5) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
  if (%rr == 6) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
  if (%rr == 2) .timer 1 2 msg $chan BANG! $me regarde le cerveau de $2 éclabousser le mur.
  if (%rr == 3) .timer 1 2 msg $chan le pistolet s'est enrayée, $2 a de la chance pour cette fois ...

I don't know how make it work. In the future I will make a nick list's popup who write : /me prend $$1 pour cible
I need your help please !

Ceidus #255453 24/10/15 08:49 PM
Joined: Feb 2015
Posts: 243
O
Fjord artisan
Offline
Fjord artisan
O
Joined: Feb 2015
Posts: 243
If your future pop up script will use /me the event it will trigger on others' scripts will be
Code:
On *:ACTION:MATCHTEXT:#: {

In your case use
Code:
on *:action:prend*pour cible*:#: {
;<rest of your script here>
}

Give it a try smile

OrFeAsGr #255458 25/10/15 09:02 PM
Joined: Oct 2015
Posts: 8
C
Ceidus Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
C
Joined: Oct 2015
Posts: 8
Hello,

Thank you for your help. But it doesn't work smirk
That's what it made with your modification :
Code:
on *:action:prend*pour cible*:#: {
; var %rr = $rand(1,6)
  .timer 1 2 describe mets 1 balle dans le barillet puis le fait tourner
  .timer 1 2 describe vise $$1 et tire !
  if (%rr == 1) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
  if (%rr == 2) .timer 1 2 msg $chan BANG! $me regarde le cerveau de $2 éclabousser le mur.
  if (%rr == 3) .timer 1 2 msg $chan le pistolet s'est enrayée, $2 a de la chance pour cette fois ...
  if (%rr == 4) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
  if (%rr == 5) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
  if (%rr == 6) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
}


I don't know why ... I try it with : "/me prend nick pour cible"

Ceidus #255459 25/10/15 09:19 PM
Joined: Feb 2015
Posts: 243
O
Fjord artisan
Offline
Fjord artisan
O
Joined: Feb 2015
Posts: 243
Hey! Sorry i made a mistake!
Code:
on *:action:prend*pour*cible*:#: {
var %rr = $rand(1,6)
  .timer 1 2 describe mets 1 balle dans le barillet puis le fait tourner
  .timer 1 2 describe vise $$1 et tire !
  if (%rr == 1) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
  if (%rr == 2) .timer 1 2 msg $chan BANG! $me regarde le cerveau de $2 éclabousser le mur.
  if (%rr == 3) .timer 1 2 msg $chan le pistolet s'est enrayée, $2 a de la chance pour cette fois ...
  if (%rr == 4) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
  if (%rr == 5) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
  if (%rr == 6) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
}

Also this: ; is used as commenting in mIRC so the script ignores the line. Use it only if you want to tell mIRC to ignore the line.

OrFeAsGr #255460 25/10/15 09:30 PM
Joined: Oct 2015
Posts: 8
C
Ceidus Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
C
Joined: Oct 2015
Posts: 8
It doesn't work either smirk

Ceidus #255461 25/10/15 09:35 PM
Joined: Feb 2015
Posts: 243
O
Fjord artisan
Offline
Fjord artisan
O
Joined: Feb 2015
Posts: 243
Code:
on *:action:*:#: {
if (*prend*pour*cible* iswm $1-) {
var %rr = $rand(1,6)
  .timer 1 2 describe mets 1 balle dans le barillet puis le fait tourner
  .timer 1 2 describe vise $$1 et tire !
  if (%rr == 1) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
  if (%rr == 2) .timer 1 2 msg $chan BANG! $me regarde le cerveau de $2 éclabousser le mur.
  if (%rr == 3) .timer 1 2 msg $chan le pistolet s'est enrayée, $2 a de la chance pour cette fois ...
  if (%rr == 4) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
  if (%rr == 5) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
  if (%rr == 6) .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois.
}
}

Lol sorry.. try this.. it will work :P

Last edited by OrFeAsGr; 25/10/15 09:35 PM.
OrFeAsGr #255462 25/10/15 09:43 PM
Joined: Oct 2015
Posts: 8
C
Ceidus Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
C
Joined: Oct 2015
Posts: 8
Thank you, some news :

  • the two describes are write on "statuts" channel, and not in the chan where we write.
  • the script don't work with me, only with other peoples oO So I can't use it, that's useless for me :x
  • the script don't reconize commands.


That's what I have on statuts channel :

Quote:
[22:39:43] -> *mets* 1 balle dans le barillet puis le fait tourner
-
[22:39:43] -> *vise* prend et tire !
-
[22:39:43] 1 Unknown command
-
[22:39:43] 1 Unknown command
-
[22:39:43] mets No such nick
-
[22:39:43] vise No such nick
-


Edit : Ok, some news again.

I add $chan after the 2 describe, and it write it on the chan now. It made this :

Quote:
[22:51:18] * @testeur prend Ceidus pour cible
[22:51:18] * @Ceidus mets 1 balle dans le barillet puis le fait tourner
[22:51:18] * @Ceidus vise prend et tire !
[22:51:18] <@Ceidus> CLICK! prend est chanceux, et survis pour cette fois.


It make like if "prend" is the nick, but it's not that (prend (french) = take (english))
And it doesn't work again with me, only with another people (testeur).

Last edited by Ceidus; 25/10/15 09:54 PM.
Ceidus #255463 25/10/15 09:57 PM
Joined: Jan 2004
Posts: 1,358
L
Hoopy frood
Offline
Hoopy frood
L
Joined: Jan 2004
Posts: 1,358
You can't trigger your own text events, you'd need an input event for that.

Joined: Oct 2015
Posts: 8
C
Ceidus Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
C
Joined: Oct 2015
Posts: 8
Again a new, with $$2 it work with the right nick :°

But how can I made it work with me ? Like a slap, but in better smirk It's useless if I can't use it ...

Last edited by Ceidus; 25/10/15 09:59 PM.
Ceidus #255465 25/10/15 10:05 PM
Joined: Feb 2015
Posts: 243
O
Fjord artisan
Offline
Fjord artisan
O
Joined: Feb 2015
Posts: 243
uuhmmm..
Firstly.. i haven't noticed that you didn't use {
Also describe needs the $chan as parameter
Code:
on *:action:*:#: {
if (*prend*pour*cible* iswm $1-) {
var %rr = $rand(1,6)
  .timer 1 2 describe $chan mets 1 balle dans le barillet puis le fait tourner
  .timer 1 2 describe $chan vise $$1 et tire !
  if (%rr == 1) { .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois. }
  if (%rr == 2) { .timer 1 2 msg $chan BANG! $me regarde le cerveau de $2 éclabousser le mur. }
  if (%rr == 3) { .timer 1 2 msg $chan le pistolet s'est enrayée, $2 a de la chance pour cette fois ... }
  if (%rr == 4) { .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois. }
  if (%rr == 5) { .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois. }
  if (%rr == 6) { .timer 1 2 msg $chan CLICK! $$1 est chanceux, et survis pour cette fois. }
}
}

Secondly.. yes indeed. on action triggers when others do ACTION .
Code:
alias ceslap {
var %rr = $rand(1,6)
  .timer 1 2 describe $active mets 1 balle dans le barillet puis le fait tourner
  .timer 1 2 describe $active vise $$1 et tire !
  if (%rr == 1) { .timer 1 2 msg $active CLICK! $$1 est chanceux, et survis pour cette fois. }
  if (%rr == 2) { .timer 1 2 msg $active BANG! $me regarde le cerveau de $2 éclabousser le mur. }
  if (%rr == 3) { .timer 1 2 msg $active le pistolet s'est enrayée, $2 a de la chance pour cette fois ... }
  if (%rr == 4) { .timer 1 2 msg $active CLICK! $$1 est chanceux, et survis pour cette fois. }
  if (%rr == 5) { .timer 1 2 msg $active CLICK! $$1 est chanceux, et survis pour cette fois. }
  if (%rr == 6) { .timer 1 2 msg $active CLICK! $$1 est chanceux, et survis pour cette fois. }
}

You can use this on any channel you want:
type /ceslap <nick>
Replace <nick> with the nick you want.
smile

Last edited by OrFeAsGr; 25/10/15 10:05 PM.
OrFeAsGr #255466 25/10/15 10:22 PM
Joined: Oct 2015
Posts: 8
C
Ceidus Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
C
Joined: Oct 2015
Posts: 8
Yes it's perfect now !

Thank you very much ! laugh

Ceidus #255467 25/10/15 10:24 PM
Joined: Feb 2015
Posts: 243
O
Fjord artisan
Offline
Fjord artisan
O
Joined: Feb 2015
Posts: 243
No problem smile Glad i helped!!!


Link Copied to Clipboard