Template talk:Alternate tilesets
Below is a compilation of discussions relating to this page, originally posted on NetHackWiki:Community_Portal, User_talk:Prometheus77, User_talk:Bcode, and User_talk:Paxed.
Original discussion
I am one of a growing number of NetHack players using smartphones and tablets to play the game. Most of us use one of various graphical tilesets because they are more friendly to the new media (I prefer the Abigaba/Chozo tileset myself). As such, I've long wanted to add alternate tiles to articles on monsters/items/etc. to make NetHackWiki more usable to people like me. I create the Template:Alternate_tilesets for this purpose, which produces a result like so:
| giant ant (alternate tilesets) | |
|---|---|
| Default (32x32) |
|
| Absurd (128x128) | |
| RLTiles |
|
| PixelHack | |
| NeXTSTEP |
|
| Abigaba |
|
| Geoduck | |
| lagged | |
I'd like some help to get this ready for production:
- Does anyone have a way of systematically cutting up large tileset files into numbered subfiles that can be renamed and uploaded to the wiki?
- Can someone please fix the template to float *below* the monster, weapon, etc. template rather than next to it?
- Can someone please fix the template to be expandable (e.g. "more" button) rather than always appearing, as it's quite large and could be distracting to many non-smartphone/tablet players
Any other improvement suggestions welcome. Thanks! --Prometheus77 (talk) 23:19, 28 March 2013 (UTC)
- This should be easy to automate, yes. I don't have an account with the bot flag set, though, and I certainly don't want to flood Special:RecentChanges with automated uploads (and it'd be good form to ask first, anyway).
- Someone with a better knowledge of CSS might want to look at that.
- Done.
- Would there be a problem with renaming the name parameter/converting it into a numbered parameter? It seems it'd be the "main" parameter, anyway, so {{alternate tilesets|giant ant}} might be better. —bcode talk | mail 12:28, 29 March 2013 (UTC)
- Thanks, that's a significant improvement. Poking around on bilious.alt.org last night I found a page that does what we're looking for, but it seems to do it by loading the entire tileset file and cropping.
- http://bilious.alt.org/~paxed/nethack/nhsshot/tilecmp.php
- I'm not a skilled enough html programmer to try to implement something like this in the template, but it seems like it may be a better solution. It would be ideal if there was a way to have the template lookup xy coordinates for each tile, but I don't know if it's possible to put lookup functionality into a template.
- --Prometheus77 (talk) 13:42, 29 March 2013 (UTC)
- I'm not sure there's a good MediaWiki solution for this. The lookup thing could be done in a {{#switch:…}}, though I'm not sure it's worth it. That HTML/CSS-based cropping seems quite hackish to me. (Also, it doesn't allow us to link to a single tile, like this.) —bcode talk | mail 14:57, 29 March 2013 (UTC)
- The more I think about it, the less enthused I am with that solution. For one thing, it sounds difficult to implement. For another, it would entail loading several full tilesets for each page rather than just the tiles in question, which could bog down load times. I guess we're probably better off going the mass upload route.
- On that note, if anyone has a solution that would allow them to cut up the files, I'm happy to take on doing the renaming by hand. We'll also need a way to do a mass upload to the server, since I'm not of a mind to upload several thousand individual files.
- --Prometheus77 (talk) 20:37, 29 March 2013 (UTC)
- I already wrote a program to cut the tilesets (tested it on Geoduck's only so far, but should work on any tileset) and split them into many tiles.
- As for uploading them, that should also be easy to automate, but it should be done using a bot-flagged account once there's consensus on the method to be used (no use for hundreds of unused images if it's done some other way). —bcode talk | mail 20:48, 29 March 2013 (UTC)
- I edited the template to remove the multiple instances of Default (you really only need 32x32) and attempted to make all of the tiles scale to the same size (64 height). For some reason, it won't force smaller images to scale up to 64, however, so you still have for example NeXTSTEP tiles appearing at an unrecognizably small size. I note that looking at the file's page does scale it up in a nicely pixellated fashion (http://nethackwiki.com/wiki/File:NeXTSTEP_giant_ant.png), but apparently the [[file:foo.png|x32px]] syntax doesn't scale up, only down. Any help?
- Also, I noticed bilious has several tilesets that I didn't include: itakura, aoki, aoki2k5, and Kins. Any others we ought to include?
- --Prometheus77 (talk) 11:20, 30 March 2013 (UTC)
- (There is no need to use an external link. You can just link to File:NeXTSTEP giant ant.png. Please also see Help:Images.)
- They're all 64px high now. I decided to mostly keep the aspect ratio for Geoduck's and lagged's tiles, though. —bcode talk | mail 16:20, 30 March 2013 (UTC)
Continued on User:bcode's page
Figured I'd continue the discussion on here so the community forum didn't get too clogged by our back-and-forth (now that we've pretty much agreed on what to do and just need to handle the technical details). You mentioned you've written the code to split up several tilesets. I recommend we go with:
- Default: (Default_tileset_scaled_to_32x32)
- Abigaba: http://www.multifoliate.com/nh/
- Absurd 64x64 (http://sourceforge.net/projects/noegnud/files/tilesets_nethack-3.4.1/absurd%2064x64/)
- Aoki: http://bilious.alt.org/~paxed/nethack/nhsshot/tileset/aoki_nethack.png
- Aoki 2k5: http://bilious.alt.org/~paxed/nethack/nhsshot/tileset/aoki-2k5_nethack.png
- Geoduck: http://cook.web.eschelon.com/nhack.html
- Itakura: http://bilious.alt.org/~paxed/nethack/nhsshot/tileset/itakura_nethack.png
- Kins: http://bilious.alt.org/~paxed/nethack/nhsshot/tileset/kins32-nh343.png
- Lagged: http://lagged.deviantart.com/art/12x20-Nethack-tileset-1308112
- NeXTSTEP: http://nethackwiki.com/wiki/File:Nh343-nextstep.png
- PixelHack: http://pixelhack.blogspot.com/
- RLTiles: http://rltiles.sourceforge.net/ (may need to be chopped manually)
Unless you're aware of any other ones worth including. Once you get the tiles chopped up, I'm happy to do the renaming, you can zip and send to my personal e-mail at AARONSAMA AT GMAIL DOT COM. I'm not exactly sure of the best way to go about uploading it. Do you happen to know of the site maintainer or an admin we can ask about getting this done more efficiently?
--Prometheus77 (talk) 21:02, 2 April 2013 (UTC)
- You don't need to do the renaming; my code already saves the tiles using the tile names given in win/share/(monsters|objects|other).txt.
- As for uploading it, AFAIK the vanilla tiles have been uploaded automatically using a bot; that would be quite easy to do for these tiles, too. Alternatively, you could ask User:Paxed (who admins the server NetHackWiki runs on).
- On doing the upload automatically myself: I can't do that without a bot account (technically I could, but that'd be a bad idea for various reasons), so I'd have to ask a bureaucrat about that. I would preferably have an administrator approve before I upload thousands of files, anyway (7231 currently, and that's not including the tilesets I haven't split yet; about 4 MiB per tileset). —bcode talk | mail 22:06, 2 April 2013 (UTC)
- Awesome. I put a note on Paxed's talk page asking for help.
Continued on User:Paxed's page
Hi! bcode and I have built a template that creates a collapsible floating table displaying alternate tilesets for a given monster/item/feature. We need to do a mass upload of the tiles to the wiki in order to get the template to work properly (currently looking like it will be ~7500 small image files). Rather than doing this the long way, we figured it would be more efficient and cleaner to work with you to upload them as a package. Can you let us know how you'd like to handle that? More details here, and here. Thanks for your help! --Prometheus77 (talk) 15:58, 3 April 2013 (UTC)
- Specifically, splitting the tilesets results in 12684 PNG files taking about 54 MiB.
- IIRC the importImages.php maintenance script would work for this purpose.
- (I'm still somewhat unsure about the actual names to use, though – the names in monsters.txt/objects.txt/other.txt aren't unique and sometimes not really useful anyway. "silver / polymorph" is the name of both a wand tile and a spellbook tile, for example.) —bcode talk | mail 16:37, 3 April 2013 (UTC)
- It seems to me you'd want to use the randomized appearance rather than the underlying item. A "silver wand" is going to look silver, a "black potion" is going to be black, and a "dog-eared spellbook" is going to have a fold in it. Looks like that's how the default tiles were uploaded (see:
) - --Prometheus77 (talk) 23:18, 3 April 2013 (UTC)
- It seems to me you'd want to use the randomized appearance rather than the underlying item. A "silver wand" is going to look silver, a "black potion" is going to be black, and a "dog-eared spellbook" is going to have a fold in it. Looks like that's how the default tiles were uploaded (see:
Continued on User:Prometheus77's page
Hi, in response to your request to upload all those tiles: User:Paxed usually decides such things, since he's the one running the server. However, he's traveling right now, so please don't take it personally if you don't get a speedy reply. Once he's back, the quickest way to reach him is via irc.freenode.net in #nethack.
That said, I'd vote to give you a bot account. You might want to prepare by making User:Prometheus77bot (or similar). --Tjr (talk) 19:20, 11 April 2013 (UTC)
- I'd probably recommend against creating User:Prometheus77bot now so in case the files are uploaded via the maintenance script, there's no unused account around. (Of course, one user more or less wouldn't change much, but somehow it would seem a little bit odd, IMHO.)
- (Besides, if someone is going to upload it the "hard" way, it might be best to avoid sending the files from my system to User:Prometheus77's system who'd send them to NetHackWiki and instead have me upload them directly (as User:bcodebot or whoever). That's assuming uploading it the hard way is the way that'll be used, which might be somewhat painful anyway (testing on localhost makes me think it could take hours, perhaps – though my local system isn't exactly a good approximation of NetHackWiki's server).)
- (Also, all this fragmentation probably makes the discussion hard to read… so far there are parts on NetHackWiki:Community Portal, User talk:Bcode, User talk:Paxed and User talk:Prometheus77. A bit surprising none of it is on Template talk:Alternate tilesets, which might be the most appropriate page for the discussion.) —bcode talk | mail 20:03, 11 April 2013 (UTC)
- I don't need a bot account, but would vote to give one to bcode. He has the files on his machine already, and I'm not technically savvy enough to know what to do with it anyway. I'm not a regular on IRC, but since you seem to be connected to Paxed, it would be great if you'd be willing to follow up with him. Obviously there's no hurry, I just wanted to be sure that he still looked at his NHW talk page, hence the posting at rgrn for help. --Prometheus77 (talk) 14:56, 16 April 2013 (UTC)



