mIRC Home    About    Download    Register    News    Help

Print Thread
#244435 26/02/14 09:47 PM
Joined: Feb 2014
Posts: 1
D
Mostly harmless
OP Offline
Mostly harmless
D
Joined: Feb 2014
Posts: 1
Im having an issue drawing an image, and set it as a button on the toolbar.
It replies with the error: "/toolbar: invalid image size (line 17, script46.ini)"
Code:
alias _MercCounter {
  window -hp +d @MercsCounter 0 0 150 35
  drawfill -r @MercsCounter 13041636 13041636 0 0
  drawtext -pr @MercsCounter 65536 arial 11 10 0 Mercs in:
  drawtext -pr @MercsCounter 65536 arial 11 60 0 1m 1s.
  UpdateToolBar Counting down for mercs
}

alias -l UpdateToolBar {
  drawsave @MercsCounter MercCounter.jpg
  if ($toolbar(MercCounter)) { 
    toolbar -tp MercCounter "Counting down for mercs" MercCounter.jpg 0 0 0 100 "/afm" @MercsCounter
  }
  else {
    toolbar -as MercCounter|
    toolbar -a MercCounter "Counting down for mercs" MercCounter.jpg 0 0 0 100 "/afm" @MercsCounter
  }
}

It fills the full @MercCounter window, and kind of ignores the h & w on the /window
Making my image fullscreen rather then a small image/button

Anyone know where i went wrong?

Joined: Feb 2006
Posts: 181
C
Vogon poet
Offline
Vogon poet
C
Joined: Feb 2006
Posts: 181
Quote:
/toolbar: invalid image size

toolbar -a MercCounter "Counting down for mercs" MercCounter.jpg 0 0 0 100 "/afm" @MercsCounter


Image size: 0 0 0 100?
Invalid (x y w h), 0 width?


Link Copied to Clipboard