Greasemonkey Script Request

Archival storage to keep things organized and uncluttered. Can't find what you need? Search for old topics here.

Moderator: Tech Team

Forum rules
Please read the Community Guidelines before posting.
Post Reply
User avatar
Silent Hysteria
Posts: 84
Joined: Sun Jul 13, 2008 9:08 am
Gender: Male
Location: Saugus, MA

Greasemonkey Script Request

Post by Silent Hysteria »

Ok, After looking at the developers guide to making GM scripts I have decided that I am not even close to being capable of writing a script. Is there anyone who is capable out there willing to chat with me to write 2 scripts I am looking for?

Script 1: Hide the Auto Attack button.
Script 2: On the My Games page, make it so it shows the names in red or green. Red being if the person is not online and green being if they are. I am sure there is a way to do it as we can see if we go to a persons profile. I just want to be able to see people I am in a game with by looking at the my games page.

Regards,
Silent Hysteria
Last edited by Silent Hysteria on Mon Jan 12, 2009 1:01 pm, edited 2 times in total.
User avatar
homes32
Posts: 86
Joined: Wed Jan 31, 2007 4:05 pm
Location: under your bed

Re: GM help.

Post by homes32 »

you would be better off posting what you are looking for here in the open, that way if there are scripts that do what you want people can point them out to you. also you are more likley to catch someones interest.
-homes32

Highest Score: 1850
cspare
Posts: 101
Joined: Sun Apr 08, 2007 12:56 pm

Re: GM help.

Post by cspare »

I agree with homes32. Just ask your questions here and I'm sure people would gladly help out. That way we are not only helping you but also other people with the same questions in the future.
User avatar
Silent Hysteria
Posts: 84
Joined: Sun Jul 13, 2008 9:08 am
Gender: Male
Location: Saugus, MA

Re: GM help.

Post by Silent Hysteria »

good point. I am looking for a script that hides the auto attack button and also a script that shows users online on the my games page. Like names are red and if they are online the names are green. Something to that effect. I will update the topic with the info. Thanks!
User avatar
yeti_c
Posts: 9624
Joined: Thu Jan 04, 2007 9:02 am
Gender: Male

Re: Greasemonkey Script Request

Post by yeti_c »

Instead of hiding Auto Attack - you could get BOB or CM and they have confirmations on the press of it.

Regarding online/offline - it's tricky to do - because that info is available elsewhere - but not on the my games page - which means the script would have a lot of extra work to do - it could be done - but could increase site traffic a fair amount. (depending on the implementation)

C.
Image
Highest score : 2297
User avatar
Silent Hysteria
Posts: 84
Joined: Sun Jul 13, 2008 9:08 am
Gender: Male
Location: Saugus, MA

Re: Greasemonkey Script Request

Post by Silent Hysteria »

If I can see the auto attack button yeti, I am still gonna use it. Even if I have to confirm it. If it isn't there I can't use it. =)

Would that mean it would bog the site down? I didn't think stuff like that would effect the site itself. I just thought it would be nice to be able to see who was online in the games I am in without having to check everyone's profile. 23 games is a lot of profiles to check. Especially when there is a minimum of 3 people per game. =)

Thanks for the response!

Regards,
SH
User avatar
chipv
Head Tech
Head Tech
Posts: 3092
Joined: Mon Apr 28, 2008 5:30 pm

Re: Greasemonkey Script Request

Post by chipv »

Silent Hysteria wrote:If I can see the auto attack button yeti, I am still gonna use it. Even if I have to confirm it. If it isn't there I can't use it. =)

Would that mean it would bog the site down? I didn't think stuff like that would effect the site itself. I just thought it would be nice to be able to see who was online in the games I am in without having to check everyone's profile. 23 games is a lot of profiles to check. Especially when there is a minimum of 3 people per game. =)

Thanks for the response!

Regards,
SH


Actually this isn't so bad - you would only need one AJAX request.
The thing is you can't see hidden users so this would not be very useful or reliable.

As for hiding the attack button, the code is so simple, it's not really worth putting into a script of its own.
Maybe you could ask yeti nicely if he would provide a hide auto attack button feature in BOB?
cspare
Posts: 101
Joined: Sun Apr 08, 2007 12:56 pm

Re: Greasemonkey Script Request

Post by cspare »

chipv wrote:Actually this isn't so bad - you would only need one AJAX request.
(...)

Hmm, wouldn't you need 1 request for each player? So for 23 active games with 3 people per game that would add up to 69 requests. One profile page is about 22KB size so that would make 22*69 = 1518Kb for every time you refresh the active games page, which probably will be quite alot of times per day.
User avatar
chipv
Head Tech
Head Tech
Posts: 3092
Joined: Mon Apr 28, 2008 5:30 pm

Re: Greasemonkey Script Request

Post by chipv »

cspare wrote:
chipv wrote:Actually this isn't so bad - you would only need one AJAX request.
(...)

Hmm, wouldn't you need 1 request for each player? So for 23 active games with 3 people per game that would add up to 69 requests. One profile page is about 22KB size so that would make 22*69 = 1518Kb for every time you refresh the active games page, which probably will be quite alot of times per day.


No. This is not recommended at all.You could get a maximum of 700 ajax requests for a mygames page with 100 8 player games assuming
all different players. You can get all non-hidden online status with a single AJAX request.
cspare
Posts: 101
Joined: Sun Apr 08, 2007 12:56 pm

Re: Greasemonkey Script Request

Post by cspare »

chipv wrote:
cspare wrote:
chipv wrote:Actually this isn't so bad - you would only need one AJAX request.
(...)

Hmm, wouldn't you need 1 request for each player? So for 23 active games with 3 people per game that would add up to 69 requests. One profile page is about 22KB size so that would make 22*69 = 1518Kb for every time you refresh the active games page, which probably will be quite alot of times per day.


No. This is not recommended at all.You could get a maximum of 700 ajax requests for a mygames page with 100 8 player games assuming
all different players. You can get all non-hidden online status with a single AJAX request.

Sounds interesting, how exactly?:)
User avatar
chipv
Head Tech
Head Tech
Posts: 3092
Joined: Mon Apr 28, 2008 5:30 pm

Re: Greasemonkey Script Request

Post by chipv »

cspare wrote:
chipv wrote:
cspare wrote:
chipv wrote:Actually this isn't so bad - you would only need one AJAX request.
(...)

Hmm, wouldn't you need 1 request for each player? So for 23 active games with 3 people per game that would add up to 69 requests. One profile page is about 22KB size so that would make 22*69 = 1518Kb for every time you refresh the active games page, which probably will be quite alot of times per day.


No. This is not recommended at all.You could get a maximum of 700 ajax requests for a mygames page with 100 8 player games assuming
all different players. You can get all non-hidden online status with a single AJAX request.

Sounds interesting, how exactly?:)


I'll SKype you.

Correction, though, the single AJAX request only tells you online users so you would still need to scrape (#mygames player - #online) users profiles.
lancehoch
Posts: 4183
Joined: Wed Dec 05, 2007 4:13 pm

Re: Greasemonkey Script Request

Post by lancehoch »

Couldn't you just get the information from the bottom of the Index page? Possibly code the script to search the index page and the My Games page for any names that appear on both? Would that be more than one request?
User avatar
chipv
Head Tech
Head Tech
Posts: 3092
Joined: Mon Apr 28, 2008 5:30 pm

Re: Greasemonkey Script Request

Post by chipv »

lancehoch wrote:Couldn't you just get the information from the bottom of the Index page? Possibly code the script to search the index page and the My Games page for any names that appear on both? Would that be more than one request?


chipv wrote:
cspare wrote:
chipv wrote:
cspare wrote:
chipv wrote:Actually this isn't so bad - you would only need one AJAX request.
(...)

Hmm, wouldn't you need 1 request for each player? So for 23 active games with 3 people per game that would add up to 69 requests. One profile page is about 22KB size so that would make 22*69 = 1518Kb for every time you refresh the active games page, which probably will be quite alot of times per day.


No. This is not recommended at all.You could get a maximum of 700 ajax requests for a mygames page with 100 8 player games assuming
all different players. You can get all non-hidden online status with a single AJAX request.

Sounds interesting, how exactly?:)


I'll SKype you.

Correction, though, the single AJAX request only tells you online users so you would still need to scrape (#mygames player - #online) users profiles.


Yup.
User avatar
Silent Hysteria
Posts: 84
Joined: Sun Jul 13, 2008 9:08 am
Gender: Male
Location: Saugus, MA

Re: Greasemonkey Script Request

Post by Silent Hysteria »

Would that be possible to have it search the index page and match them to the mygames page?
cspare
Posts: 101
Joined: Sun Apr 08, 2007 12:56 pm

Re: Greasemonkey Script Request

Post by cspare »

Silent Hysteria wrote:Would that be possible to have it search the index page and match them to the mygames page?

Sure, but it's not so easy. For you I think it would be best to start with hiding the auto-attack button, that should be a good start.
User avatar
Silent Hysteria
Posts: 84
Joined: Sun Jul 13, 2008 9:08 am
Gender: Male
Location: Saugus, MA

Re: Greasemonkey Script Request

Post by Silent Hysteria »

I wouldn't have the first idea with how to write the script. I have asked Yeti to add it to the BOB script so it can be used by anyone that wants it.
cspare
Posts: 101
Joined: Sun Apr 08, 2007 12:56 pm

Re: Greasemonkey Script Request

Post by cspare »

Silent Hysteria wrote:I wouldn't have the first idea with how to write the script. I have asked Yeti to add it to the BOB script so it can be used by anyone that wants it.

Well, if you really want to learn how to write scripts i think this is something you should start with. Even if yeti would add it to BOB. I think implementing this would be one of the easier scripts to make, probably with just a single line of code. To get an idea how scripts work and where to start I suggest you download the source code of a script that you are using regularly. Then you can try to read the code and try to understand what every line does. It might be fun to alter some code and see how it results.
User avatar
Silent Hysteria
Posts: 84
Joined: Sun Jul 13, 2008 9:08 am
Gender: Male
Location: Saugus, MA

Re: Greasemonkey Script Request

Post by Silent Hysteria »

That sounds like a great idea. Thanks!
Post Reply

Return to “Tool Archives”