User talk:Aichon: Difference between revisions
From The Urban Dead Wiki
Jump to navigationJump to search
(Archiving) |
|||
Line 44: | Line 44: | ||
::What I'd like to know is if this will break any of Aichon's current scripts... >_< --{{User:Axe Hack/Sig}} 21:34, 12 October 2010 (BST) | ::What I'd like to know is if this will break any of Aichon's current scripts... >_< --{{User:Axe Hack/Sig}} 21:34, 12 October 2010 (BST) | ||
:::It doesn't. The changes he made don't affect any of my other scripts from what I can see. I'll have an updated copy linked from my userscripts page in a sec. I did move the coords to the front of the name, and I also turned off the display for dark buildings and educational buildings, since I had inadvertently uploaded that version of the script awhile back (I use that myself for my Philosophe Knight, since we care about Centers of Learning, but I didn't mean to put it up for general use), but otherwise left it pretty much as you had it, Thvortex. {{User:Aichon/Signature}} 21:41, 12 October 2010 (BST) | :::It doesn't. The changes he made don't affect any of my other scripts from what I can see. I'll have an updated copy linked from my userscripts page in a sec. I did move the coords to the front of the name, and I also turned off the display for dark buildings and educational buildings, since I had inadvertently uploaded that version of the script awhile back (I use that myself for my Philosophe Knight, since we care about Centers of Learning, but I didn't mean to put it up for general use), but otherwise left it pretty much as you had it, Thvortex. {{User:Aichon/Signature}} 21:41, 12 October 2010 (BST) | ||
::Aichon, For the non-descript locations I did a search/replace with regular expressions where the replace string can have <tt>\1</tt>, <tt>\2</tt>, etc. to substitute in parenthesized parts of the regex match. To handle the building names, I actually wrote a Python script that processed the Javascript array definitions to figure out which names are duplicate and therefore need to have the suburb added to the link. If you're curious, I can give you that little script as well. For a few like "The Dewberry Building" I had to go back and fix the links by hand. And I meant to say 10,000 locations not 100,000 :) | |||
::And I agree that putting the GPS coordinates in the front is a better idea. | |||
::While I do a lot of programming at work, it's all operating system code in C. I'm still somewhat of a newb when it comes to Javascript and Web development in general.--[[User:Thvortex|Thvortex]] 22:17, 12 October 2010 (BST) |
Revision as of 21:17, 12 October 2010
Aichon:Talk
Announcement: I'm no longer active. My talk page is still your best bet to get in touch. —Aichon— 04:39, 15 December 2018 (UTC)
- New conversations should be started at the bottom using a level two header (e.g.
==Header==
). - I like to keep conversations wherever they start, but if a conversation ends up here, I will keep it here.
- I will format comments for stylistic reasons, delete comments for whatever reason, and generally do anything else within reason.
Massively Overdue Quizzle Prize
Dancing Bear made of Gold! | |
Yonnua has given Aichon an animated .gif of a dancing bear made of gold for solving a quizzle! (It might take a second to load) |
--Yonnua Koponen Talk ! Contribs 23:24, 2 October 2010 (BST)
Improvements to UDMap Script
I made several improvements to the UDMap script that I'd like to share with the rest of the world. My version of the script is currently available here. Would you be willing to incorporate these changes back into your own script page? I figured it would be easier for people to download off of your page since they already know where to find it, etc. I don't even have my own User:Thvortex page setup yet on the wiki. Anyway, below is the list of improvements I made.
- Clicking on a space in the suburb map opens the wiki page for that location in a new browser window. Yes, this works for all 100,000 locations :) It's handy for checking the recent status of a building. It did make the script about 300KB larger to include the link information.
- When moving the mouse over the suburb, there is now a GPS coordinate added to the name of the building or street over which the mouse is hovering.
- Clicking on the city map to change the suburb view did not work in Firefox and GreaseMonkey because of the security model that GreaseMonkey uses. Basically window.switch_map doesn't work but GreaseMonkey has a workaround in the form of unsafeWindow.switch_map. Please verify my script still works in Safari though.
- I make use of DumbWitness a lot, and I noticed that UDMap didn't quite work right in the captured screenshot. Basically, moving the mouse over the suburb map was not displaying the building names anymore. Turns out that DumbWitness was munging the page a little bit and when it saw a \" double-quote escape in a Javascript string it would cut off the rest of the code. So in one place I switched to using single quotes and apparently DumbWitness doesn't mind a \' escape. Of course, clicking on the city map in the DumbWitness screenshot still won't do anything because that requires a call-back to the user script, and that's no longer accessible in the captured screenshot.
--Thvortex 20:58, 12 October 2010 (BST)
- Holy cow, those changes are awesome and that's a lot of work you did there. Looking through the diff file, I don't see anything unexpected, and after installing it on Safari and fooling around with it a bit, I absolutely love the changes you made (and, yep, the
unsafeWindow
change works fine).
- How did you get all of the location links anyway? I had considered a feature like that at one point, but didn't feel like making a program to go through and determine the valid ones links from the invalid. I figured it'd just be easier and more generally useful at this point to push through a wiki project which aimed to create pages for each set of coordinates which then redirect to the actual location page, but I hadn't gotten around to that either. >_<
- The only change I might make is to put the coordinates at the front of the line, rather than the end, that way they don't look like they bounce around so much, but otherwise I absolutely love it all.
- Also, I get the distinct impression that you're much more proficient at this stuff than I am (it's just an idle time hobby for me), so any changes you want to suggest to other scripts would be most welcome. —Aichon— 21:29, 12 October 2010 (BST)
- What I'd like to know is if this will break any of Aichon's current scripts... >_< --•▬ ▬••▬ • •••• •▬ ▬•▬• ▬•▬ #nerftemplatedsigs 21:34, 12 October 2010 (BST)
- It doesn't. The changes he made don't affect any of my other scripts from what I can see. I'll have an updated copy linked from my userscripts page in a sec. I did move the coords to the front of the name, and I also turned off the display for dark buildings and educational buildings, since I had inadvertently uploaded that version of the script awhile back (I use that myself for my Philosophe Knight, since we care about Centers of Learning, but I didn't mean to put it up for general use), but otherwise left it pretty much as you had it, Thvortex. —Aichon— 21:41, 12 October 2010 (BST)
- Aichon, For the non-descript locations I did a search/replace with regular expressions where the replace string can have \1, \2, etc. to substitute in parenthesized parts of the regex match. To handle the building names, I actually wrote a Python script that processed the Javascript array definitions to figure out which names are duplicate and therefore need to have the suburb added to the link. If you're curious, I can give you that little script as well. For a few like "The Dewberry Building" I had to go back and fix the links by hand. And I meant to say 10,000 locations not 100,000 :)
- What I'd like to know is if this will break any of Aichon's current scripts... >_< --•▬ ▬••▬ • •••• •▬ ▬•▬• ▬•▬ #nerftemplatedsigs 21:34, 12 October 2010 (BST)
- And I agree that putting the GPS coordinates in the front is a better idea.
- While I do a lot of programming at work, it's all operating system code in C. I'm still somewhat of a newb when it comes to Javascript and Web development in general.--Thvortex 22:17, 12 October 2010 (BST)