suguested small change for functions.lua

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Message
Author
User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

suguested small change for functions.lua

#1 Post by lisa » Wed Jan 12, 2011 9:19 pm

I was wondering if it would be a good idea to have the bot use a different colour when printing it is loading a WP. At the moment there is a sea of prints of changing to different waypoint coords which is all green and then it changes WP and also green, so hard to find sometimes.

Code: Select all

cprintf(cli.rgreen, language[0], __WPL:getFileName());	-- Loaded waypoint path
to maybe red?

Code: Select all

cprintf(cli.red, language[0], __WPL:getFileName());	-- Loaded waypoint path
So now it will say
Loaded waypoint path XXXX.
In a more noticable colour.

Just a thought.

Edit: I quoted wrong code, fixed now.
Last edited by lisa on Wed Jan 12, 2011 10:28 pm, edited 2 times in total.
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: suguested small change for bot.lua

#2 Post by rock5 » Wed Jan 12, 2011 9:38 pm

The question I think you need to be answering is "why should the 'moving to waypoint' messages be singled out from all the other green messages?".
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: suguested small change for bot.lua

#3 Post by lisa » Wed Jan 12, 2011 10:00 pm

because it's a major change in what the bot is doing. changing from 1 WP to the next is an event that I know I personally look for if reading what bot is doing and at the moment it takes reading each line to see it.

It's not a change I would do an update for, just something to concider changing when the next update occurs. I've already changed mine to red, so I'm fine, not sure if anyone else would like it though.
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: suguested small change for bot.lua

#4 Post by rock5 » Wed Jan 12, 2011 10:17 pm

I'd like to hear from anyone else who supports this idea.

I don't know about red. I think red is harder to read than green, well on my projector anyway. And red means 'error, something is seriously wrong'. Maybe 'lightgreen' so it just stands out? Actually I wouldn't mind making all the colors 'light'. It makes them a lot easier to see and read.
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: suguested small change for functions.lua

#5 Post by lisa » Wed Jan 12, 2011 10:29 pm

Original thought was orange but when I tried it the Textcolor hasn't been set for orange, so I just went with red.
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: suguested small change for bot.lua

#6 Post by rock5 » Wed Jan 12, 2011 10:49 pm

I just checked. The 'lightest' colors in order (by my eyes) are:
white
yellow
lightblue/lightgreen/lightgray
pink
lightred
forestgreen/gray/turquoise/green

The last 4 colors are just barely acceptable. I wouldn't mind changing green to lightgreen, red to lightred and using white/yellow/lightblue/lightgreen/lightgray/pink to highlight other messages as needed.
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: suguested small change for functions.lua

#7 Post by lisa » Wed Jan 12, 2011 11:55 pm

I find the green hard to read, White is very easy to read but there is already so much of it with it being skills used.
I hadn't really put any thought into redoing the colour scheme but for me personally I'd change the skills to not white and have things that I want to grab my attention to be white.
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: suguested small change for functions.lua

#8 Post by rock5 » Thu Jan 13, 2011 3:50 am

lisa wrote:I find the green hard to read, White is very easy to read but there is already so much of it with it being skills used.
I hadn't really put any thought into redoing the colour scheme but for me personally I'd change the skills to not white and have things that I want to grab my attention to be white.
Actually the skills are lightgray.
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: suguested small change for functions.lua

#9 Post by lisa » Thu Jan 13, 2011 4:12 am

I've got my load WP set to yellow, same as the message you would get if you don't have a return path. Kinda fits together that way I think.
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: suguested small change for functions.lua

#10 Post by rock5 » Thu Jan 13, 2011 4:43 am

Administrator suggests user settings so the user can change the colors.
Something like;

Code: Select all

["MESSAGE_COLOR_ERROR"] = cli.red,
["MESSAGE_COLOR_WARNING"] = cli.yellow,
["MESSAGE_COLOR_STANDARD"] = cli.green,
I still think we could review the default colors used.

I think we need to define a system of levels. Something like;
error = lightred
warning = yellow
skilluse = lightgray

Maybe multiple levels of info colors
infolow = green
infomedium = lightgreen
info high = lightblue

Then decide what color messages should use. The least important and often never read messages should use infolow. Messages that still come out often but are a bit more important should be info medium. Maybe 'move to waypoint' messages fall in this category. Messages that don't come out often and are more important would use infohigh, messages like loading waypoint file or reversing direction or using a function to changes a setting. You get the idea.
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: suguested small change for functions.lua

#11 Post by lisa » Thu Jan 13, 2011 6:06 am

sounds like a good plan, I like the user settings idea too as not everyone has the same setup or liking of colours.
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual

Alkaiser
Posts: 222
Joined: Sat Sep 25, 2010 2:03 pm

Re: suguested small change for functions.lua

#12 Post by Alkaiser » Thu Jan 13, 2011 8:37 am

I agree that cli.red is hard to read. I use cli.white for my own custom notifications. I don't think that allowing for more user customization has a downside. :)

User avatar
jduartedj
Posts: 599
Joined: Sat Dec 19, 2009 12:18 am
Location: Lisbon
Contact:

Re: suguested small change for functions.lua

#13 Post by jduartedj » Thu Jan 13, 2011 2:55 pm

rock5 wrote:Administrator suggests user settings so the user can change the colors.
Something like;

Code: Select all

["MESSAGE_COLOR_ERROR"] = cli.red,
["MESSAGE_COLOR_WARNING"] = cli.yellow,
["MESSAGE_COLOR_STANDARD"] = cli.green,
I still think we could review the default colors used.

I think we need to define a system of levels. Something like;
error = lightred
warning = yellow
skilluse = lightgray

Maybe multiple levels of info colors
infolow = green
infomedium = lightgreen
info high = lightblue

Then decide what color messages should use. The least important and often never read messages should use infolow. Messages that still come out often but are a bit more important should be info medium. Maybe 'move to waypoint' messages fall in this category. Messages that don't come out often and are more important would use infohigh, messages like loading waypoint file or reversing direction or using a function to changes a setting. You get the idea.
Maybe a function could be done for that something like

Code: Select all

function printbot(msg,type,ingame)
local color;
local colorStr;

if not msg then
  return
end

-- define colors
if type == "warning" then
   color = cli.yellow;
   -- colorStr =   some code for ingame chat color system
end
-- and so on... ... ..
if not type then
  color = cli.white
  colorStr = ""
end

if ingame then
   --code to print in game chat using colorStr
end

cprintf(color,msg);

end
What do you think?

Code: Select all

printbot(msg[,type,ingame]);
EDIT: oops forgot about ["MESSAGE_COLOR_ERROR"] so it would be more like color = profile.settings.MESSAGE_COLOR_ERROR;
Thanks for reading! :D

Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: suguested small change for functions.lua

#14 Post by rock5 » Fri Jan 14, 2011 1:48 am

I like it but I'm not sure about mixing ingame and MM. Mainly because it could cause confusion but also because the colors you would use in the mm window would not necessarily be the same as you would use ingame.

I think it would be better to have a dedicated printtoclient function to make things clearer.

Also I'm not sure of the function name. Maybe 'printMSG'?
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: suguested small change for functions.lua

#15 Post by rock5 » Fri Jan 14, 2011 1:52 am

Then again, whats the difference between

Code: Select all

printf(type,msg)
and

Code: Select all

printbot(msg,type)
?
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

User avatar
jduartedj
Posts: 599
Joined: Sat Dec 19, 2009 12:18 am
Location: Lisbon
Contact:

Re: suguested small change for functions.lua

#16 Post by jduartedj » Fri Jan 14, 2011 5:27 am

rock5 wrote:I like it but I'm not sure about mixing ingame and MM. Mainly because it could cause confusion but also because the colors you would use in the mm window would not necessarily be the same as you would use ingame.
The idea here would be that some people (I at least) would like some information to be presented on the client. For example I print my daily quests count in both MM and client.
Keeping the colors the same was only a matter of coherence between MM and game chat window.
rock5 wrote: Also I'm not sure of the function name. Maybe 'printMSG'?
printBot was an example we can use whatever. what about 'Text(msg,type)'?
rock5 wrote:Then again, whats the difference between printf(type,msg) and printbot(msg,type) ?
Not sure what you mean here. are you comparing cprintf(color,msg) with printbot(msg,type) ? or is it the order of args? anyway I think it is way simpler to write "error" than to remember that cli.lightred is the color used for errors, and also it would get the color from "settings.MESSAGE_COLOR_ERROR".

Also i included 'ingame' arg as OPTIONAL so that you can simply choose not to post to ingame which would be most common, yet sometimes you would like to post to ingame.
Thanks for reading! :D

Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: suguested small change for functions.lua

#17 Post by rock5 » Fri Jan 14, 2011 7:03 am

What I meant by "whats the difference between printf(type,msg) and printbot(msg,type) ?" is they are both just as easy to write and function the same (besides the arguments being reversed).

So the only reason to have the printbot function is so you can optionally write to the client but like I said I don't like using 1 function to do both.

So why not use

Code: Select all

printf(settings.MESSAGE_COLOR_ERROR,"Unable to read memory!") 
when writing to the mm window.

And have another function for writing to the client. You could also add other messaging options besides color like the options used with SendChatMessage

Still not convinced? :)
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

User avatar
jduartedj
Posts: 599
Joined: Sat Dec 19, 2009 12:18 am
Location: Lisbon
Contact:

Re: suguested small change for functions.lua

#18 Post by jduartedj » Sat Jan 15, 2011 10:59 pm

rock5 wrote:What I meant by "whats the difference between printf(type,msg) and printbot(msg,type) ?" is they are both just as easy to write and function the same (besides the arguments being reversed).

So the only reason to have the printbot function is so you can optionally write to the client but like I said I don't like using 1 function to do both.

So why not use

Code: Select all

printf(settings.MESSAGE_COLOR_ERROR,"Unable to read memory!") 
when writing to the mm window.

And have another function for writing to the client. You could also add other messaging options besides color like the options used with SendChatMessage

Still not convinced? :)
Convinced!
Thanks for reading! :D

Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: suguested small change for functions.lua

#19 Post by rock5 » Sun Jan 16, 2011 2:29 am

Actually, I recently came across the rombot function "addMessage(message)". It will send the message ingame. So the function you are looking for is already there if a bit low on options. :)
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: suguested small change for functions.lua

#20 Post by lisa » Sun Jan 16, 2011 3:13 am

I thought we talked about using addMessage a couple of weeks ago when someone was trying to add messages to a certain tab on their chat screen?
Remember no matter you do in life to always have a little fun while you are at it ;)

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests