[Home] [Downloads] [Search] [Help/forum]

Gammon Software Solutions forum

See www.mushclient.com/spam for dealing with forum spam. Please read the MUSHclient FAQ!

[Folder]  Entire forum
-> [Folder]  MUSHclient
. -> [Folder]  Plugins
. . -> [Subject]  Miniwindow plugin - campaign tracker for Aardwolf

Home  |  Users  |  Search  |  FAQ
Username:
Register forum user name
Password:
Forgotten password?
(New message)
Subject: Miniwindow plugin - campaign tracker for Aardwolf
Name:
Your forum user name.
Register forum user name
Password:
Your forum password.
Forgotten password?
Message:
Message to be posted (in English, please).
Forum codes:
Check this if your message uses 'forum codes' or templates (auto-detected for new posts).
Forum codes Templates

Save this message ...


Subject review (reverse sequence)

Pages: 1  2 

Posted by Nick Gammon   Australia  (18,770 posts)  [Biography] bio   Forum Administrator
Date Tue 04 Sep 2012 11:07 PM (UTC)  quote  ]
Message
Soodik said:

Trying to modify it, so that every mob name on the list is hyperlink.


Hyperlinks to what? As Fiendish says the text is not a hyperlink per se, but you could simulate one by drawing an underline and making a hotspot that spans the text.

Please don't message me asking for more details, I try to answer on the forum as best I can.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Fiendish   USA  (848 posts)  [Biography] bio   Global Moderator
Date Tue 04 Sep 2012 12:57 PM (UTC)  quote  ]
Message
Miniwindows do not have hyperlinks. They just have hotspots that may or may not span the height and width of an arbitrary section of text.

http://aardwolfclientpackage.googlecode.com/
[Go to top] top

Posted by Soodik   (2 posts)  [Biography] bio
Date Tue 04 Sep 2012 06:43 AM (UTC)  quote  ]
Message
Hei

Need a bit help with this campaign tracker plugin.
Trying to modify it, so that every mob name on the list is hyperlink. Any good ideas ?
[Go to top] top

Posted by Jsportive-Thalanvor   Netherlands  (71 posts)  [Biography] bio
Date Fri 09 Mar 2012 01:36 PM (UTC)  quote  ]

Amended on Sat 10 Mar 2012 11:55 PM (UTC) by Jsportive-Thalanvor

Message
shouldn't this be created in a new miniwindow?
if yes, where is that window?

[EDIT] nvm :P got it to work thnx
[Go to top] top

Posted by Twisol   USA  (2,229 posts)  [Biography] bio
Date Sun 03 Jan 2010 11:52 PM (UTC)  quote  ]
Message
Yes, that happens if you happen to add the same plugin twice, or two plugins somehow manage to have the same ID. If it's the former, just remove it from the plugins list and re-add it, or better, just click Reinstall with it selected. If it's the latter, it probably won't hurt in this case to replace the ID in the plugin's XML (where it points it out); you can go to Edit -> Generate Unique ID to get a new ID to put in there.

EDIT: Ninja'd.

'Soludra' on Achaea

Blog: http://jonathan.com/
GitHub: http://github.com/Twisol
[Go to top] top

Posted by Nick Gammon   Australia  (18,770 posts)  [Biography] bio   Forum Administrator
Date Sun 03 Jan 2010 11:51 PM (UTC)  quote  ]
Message
Sounds like you have two plugins of the same ID. Check what other plugins you have loaded.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Plax   (1 post)  [Biography] bio
Date Sun 03 Jan 2010 11:42 PM (UTC)  quote  ]
Message
Line 17: Plugin "id" field must be unique for this world (problem in this file)

<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE muclient>
<!-- Saved on Tuesday, July 15, 2008, 11:06 AM -->
<!-- MuClient version 4.33 -->

<!-- Plugin "Aardwolf_Campaign_Noter" generated by Plugin Wizard -->

<muclient>
<plugin
name="Aardwolf_Campaign_Noter_v2"
author="Nick Gammon"
id="23c3c91af0a26790c625f5d1"
language="Lua"
purpose="Shows remaining campaign objectives"
date_written="2008-07-22"
requires="4.34"
version="1.0"
save_state="y"
>
<description trim="y">
<![CDATA[
Shows outstanding campaign objectives.

To activate, type: cp check
]]>
</description>

</plugin>5d1"
[Go to top] top

Posted by Aardhabit   (4 posts)  [Biography] bio
Date Wed 23 Sep 2009 09:25 PM (UTC)  quote  ]
Message
Thanks for your patience! I haven't had a gq yet, but it appears to be working :-)
[Go to top] top

Posted by Bast   (76 posts)  [Biography] bio
Date Wed 23 Sep 2009 05:40 PM (UTC)  quote  ]
Message
In the zip that you downloaded, copy all the files from the lua directory into <MushclientInstallDir>/lua.

Bast

Bast

Scripts: http://bastmush.googlecode.com
[Go to top] top

Posted by Aardhabit   (4 posts)  [Biography] bio
Date Wed 23 Sep 2009 02:46 PM (UTC)  quote  ]
Message
I must apologize, I'm extremely dense about this stuff :-( But the error I get is:

Line 47: Error parsing script (problem in this file)

Oh, and I didn't notice this yesterday, but I also have a sizable message in my "home" window.

Run-time error
Plugin: miniwin_gq (called from world: Aardwolf)
Immediate execution
[string "Plugin"]:154: module 'miniwin' not found:
no field package.preload['miniwin']
no file '.\miniwin.lua'
no file 'H:\Documents\Curtis\Misc\MUSHclient\lua\miniwin.lua'
no file 'H:\Documents\Curtis\Misc\MUSHclient\lua\miniwin\init.lua'
no file 'H:\Documents\Curtis\Misc\MUSHclient\miniwin.lua'
no file 'H:\Documents\Curtis\Misc\MUSHclient\miniwin\init.lua'
stack traceback:
[C]: in function 'require'
[string "Plugin"]:154: in main chunk
Error context in script:
150 :
151 :
152 : require 'var'
153 : require "commas"
154*: require 'miniwin'
155 : require 'tprint'
156 : require 'pluginhelper'
157 :
158 : gqwin = Miniwin{name="GQ", windowpos=7, font_size=7, font="Verdana", header_height=0}

I'm guessing I'm missing some files necessary to run the plugin, but I don't know where to get these. Sorry for the trouble.
[Go to top] top

Posted by Blainer   (191 posts)  [Biography] bio
Date Tue 22 Sep 2009 11:42 PM (UTC)  quote  ]
Message
Post the errors.
[Go to top] top

Posted by Aardhabit   (4 posts)  [Biography] bio
Date Tue 22 Sep 2009 08:50 PM (UTC)  quote  ]
Message
Thanks very much! :-) If I could only get by the parsing errors, I'd be delighted!
[Go to top] top

Posted by Bast   (76 posts)  [Biography] bio
Date Tue 22 Sep 2009 07:50 PM (UTC)  quote  ]
Message
I have one at http://code.google.com/p/bastmush/

Bast

Bast

Scripts: http://bastmush.googlecode.com
[Go to top] top

Posted by Aardhabit   (4 posts)  [Biography] bio
Date Tue 22 Sep 2009 06:29 PM (UTC)  quote  ]
Message
Has anyone out there successfully made a gq mob tracker similar to the cp mob tracker and willing to share it? I would maybe not be eternally grateful, but I would be grateful for a long, long time.
[Go to top] top

Posted by Jennkei   (7 posts)  [Biography] bio
Date Thu 19 Feb 2009 03:44 AM (UTC)  quote  ]

Amended on Thu 19 Feb 2009 03:50 AM (UTC) by Jennkei

Message
Hiding works beautifully now. Thank you so much, Nick! :)

If it's not too much trouble and you're free, could you possibly help me have a look at what's wrong with my replace-cp-with-gq version, please..? It's alright if you aren't, just thought I'd ask anyway. :D

<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE muclient>
<!-- From Aardwolf_Campaign_Noter_v2 by Nick Gammon -->
<!-- Saved on Tuesday, July 15, 2008, 11:06 AM -->
<!-- MuClient version 4.33 -->

<!-- Plugin "Aardwolf_Gq_Noter" generated by Plugin Wizard -->

<muclient>
<plugin
   name="Aardwolf_gq_Noter"
   author="Nick Gammon -modified-"
   id="23c3c91af0a26790c625f5d2"
   language="Lua"
   purpose="Shows remaining gq objectives"
   date_written="2008-07-22"
   requires="4.34"
   version="1.0"
   save_state="y"
   >
<description trim="y">
<![CDATA[
Shows outstanding gq objectives.

]]>
</description>

</plugin>


<!--  Triggers  -->

<triggers>
  <trigger
   match="^You still have to kill (.*?) \* (.*?)$"
   name="gq_item"
   script="gq_item"
   sequence="100"
   regexp="y"
  >
  </trigger>
  
 <trigger
   enabled="y"
   match="Congratulations, that was one of the GLOBAL QUEST mobs!"
   send_to="10"
   sequence="100"
  >
  <send>gq check</send>
  </trigger>

 <trigger
   enabled="y"
   match="Global Quest: The global quest has been won by"
   sequence="100"
   script="gq_done"
  >
  </trigger>

</triggers>

<!--  Aliases  -->

<aliases>
  <alias
   name="gq_check"
   script="gq_check"
   match="^(gq|gquest) check$"
   enabled="y"
   regexp="y"
   sequence="100"
  >
  <send>gq check</send>
  </alias>
</aliases>


<!--  Script  -->


<script>
<![CDATA[

require "commas"

background_colour = 0xE7FFFF
text_colour = 0x000000
heading_colour = 0x800080
time_colour = 0x82004B

gq_info = {}
 
function capitalize (s)
  return string.sub (s, 1, 1):upper () .. string.sub (s, 2):lower ()
end -- capitalize 

function gq_item (name, line, wildcards)
  local text =  wildcards [1]
  text = string.sub (text, 1, 1):upper () .. string.sub (text, 2)
  table.insert (gq_info, text)
  max_width = math.max (max_width, WindowTextWidth (global, font_id, text))
end -- gq_item

function gq_done (name, line, wildcards)
  WindowShow (global, false)
  gq_info = {}
end -- gq_done

function Display_Line (i, text, id, colour)

local right = 5
local top =  (i * font_height) - font_height

  WindowText (global, id, text, left, top, 0, 0, colour)

end -- Display_Line

function show_gq_text ()

  -- do nothing if no gq
  if #gq_info == 0 or when_required == nil then
    return
  end -- if

  -- recreate the Window the correct size
  check (WindowCreate (global, 
                 0, 0,   -- left, top (auto-positions)
                 max_width + 10,     -- width
                 (#gq_info + 2)   * font_height + 5,  -- height
                 7,       -- auto-position: top middle
                 0,  -- flags
                 0xE7FFFF) )
 
  -- heading
  local text = "Current gq. You need to kill:"
  max_width = math.max (max_width, WindowTextWidth (global, font_id, text))
  Display_Line (1, text, font_id, heading_colour)

  -- list of mobs
  for i, v in ipairs (gq_info) do
    Display_Line (i + 1, v, font_id, text_colour)
  end -- for
     
  WindowShow (global, true)  
end -- show_gq_text

   
  
function gq_check( name, line, wildcards)
  check (EnableTrigger ("gq_item", true))
  gq_info = {}
  max_width = 0
  
end -- gq_check


function OnPluginInstall ()
  global = GetPluginID ()
  font_id = "fn"
  
  font_name = "Comic Sans MS"    -- the actual font
  
  -- make window so I can grab the font info
  check (WindowCreate (global, 
                 0, 0, 1, 1,  
                 1,   -- irrelevant
                 0, 
                 background_colour) )

  check (WindowFont (global, font_id, font_name, 8, false, false, false, false, 0, 0))  -- normal  
  font_height = WindowFontInfo (global, font_id, 1)  -- height
end -- OnPluginInstall

function OnPluginDisable ()
  WindowShow (global, false)
end -- OnPluginDisable

]]>
</script>

</muclient>
[Go to top] top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


20,822 views.

This is page 2, subject is 2 pages long:  [Previous page]  1  2 

[Reply to this subject]  Reply to this subject   [New subject]  Start a new subject   [Refresh] Refresh page

Go to topic:           Search the forum


[Go to top] top

[Home]

Written by Nick Gammon - 5K

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( http://www.gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Internet Contents Rating Association (ICRA) - 2K]    [Web site powered by FutureQuest.Net]