Saturday 3 December 2011

Soft sleeper train travel

In order to get from Shanghai to Xi'an, I booked a "soft sleeper" bed in an overnight train. This costs around 550 RMB (~115 NZD), and I bought the ticket at the local Jing'an ticketing office. The lady at the counter spoke English, but to spot the store you probably need to know the characters for train. I followed instructions from an online forum, and still spent a bit of time hunting for it.  If you look at the blue strip at the top and squint a bit to make up for the ipod camera photo quality, you can see 火车票 (AKA train ticket) are the leftmost characters.

2011-11-14 - Shanghai - 01 - Train ticketing office

The soft sleeper cabin is pretty comfortable looking. You get a pillow and a duvet.

2011-11-15 - Shanghai-Xian train - 01 - Soft sleeper cabin

There's a television, in theory.

2011-11-15 - Shanghai-Xian train - 02 - Cabin television

And the controls on the wall beside the bed, within easy reach. Of course, no train I have been on shows anything on TV other than a blue screen.

2011-11-15 - Shanghai-Xian train - 03 - Cabin television controls

There's a convenient power socket if you feel like using your laptop, or run out of power on some device. Not sure the air conditioning dial made much difference.

2011-11-15 - Shanghai-Xian train - 04 - Bedside electricals

And overhead luggage space.

2011-11-15 - Shanghai-Xian train - 05 - Luggage space

My travelling companion was an engineer who worked making axles for rotors for boats and generally most any machine, or something similar. He travels around China quite a bit for meetings related to this, taught himself reasonable English from a CD, and lived in the states for two years.

On my Xi'an to Beijing leg, I bought the ticket at the Xi'an train station.  This cost around 440 RMB.  One thing to note, is that apparently some train stations have special lounges where those who paid out for the soft option can wait away from the teeming masses. Here's the one at the Xi'an train station.

2011-11-20 - Train - Xi'an to Beijng - 01 - Soft sleeper lounge

The soft sleeper lounge also has a special entrance, where you don't need to get into the queue where everyone pushes forward to get their ticket checked and access to the train.

2011-11-20 - Train - Xi'an to Beijng - 02 - Soft sleeper entrance

Seeing a foreigner sit down, the girl above came over and asked to look at my ticket. She obviously planned to let me know when my train was departing. When a group of other foreigners came in, she sat them down beside her and told them she'd let them know when they were to go. I was expecting the private entrance to give earlier access to the train than the teeming masses got, but going through immediately when my train was announced, the masses were already present and teeming their way to the train.

For this leg to Beijing, the cabin had four men including myself, and one child who shared a bunk with his history teacher father. The history teacher was the only one who could speak English, and had also taught himself from CDs. At some stage, the ticket collectors came through and charged him for his trip which he didn't seem to have paid for yet. He paid ~178 RMB, which I should have asked him about, it being less than half what I paid.

On the way back to Shanghai, the ticket was around 475 RMB for the cheaper train (16:58 PM departure, 06:30 arrival).  There were no televisions, and a lady came around and accounted for each passenger by swapping their ticket for a plastic card.  When it was your stop, she would come around sometime before, wake you, trading your ticket back for the card.  It's quite a good system from the perspective of a foreigner, as it ensures you won't miss your stop.  Especially if you are disembarking somewhere along the way.

I read some foreigners complaining about not realising they'd be on a train for a day and a half and not having any food, but that's not a real problem, at least not on any train I took.  A food card came around every half hour, both in the morning and evening.  There was also a food carriage where you could get freshly cooked meals, beers, cokes, and sprites.

This is so much better than flying, or taking a high-speed train during the day.  You get the bulk of the day before and after to yourself, and a good nights sleep.

Wednesday 30 November 2011

Shanghai - Pan-fried dumplings

I've bought dumplings once from here on the way past, and wanted to buy them again before I left Shanghai.

2011-11-14 - Shanghai - Dumplings - 01 - Storefront

Large round, filled with mystery meat and soupish liquid.  They're also pan-fried which gives them additional flavour.  Bying two lots of four at 5 RMB each, the price had gone up from 4 RMB, but I always wonder if maybe I just get "random foreigner price which is higher than what locals pay".  You never know.. although sometimes you do and can't be bothered bargaining.

2011-11-14 - Shanghai - Dumplings - 02 - Pans

I went to Jing'an park to look for a place to sit down and eat, and found this performance.  This lady was loudly singing Chinese songs, and had people up on stage singing with her.  Grandchildren and grandmothers, maybe some sort of school holiday activity or some such.  But more importantly, they had spare seats.

2011-11-14 - Shanghai - Dumplings - 04 - Park performance

The dumplings, still too hot to eat.

2011-11-14 - Shanghai - Dumplings - 03 - Bought

The innards.  The leaked liquid can be seen surrounding this last dumpling.  Really four would have been enough for me, and eight was overdoing it.

2011-11-14 - Shanghai - Dumplings - 05 - Innards

I prefer the smaller more standard shaped dumplings, as there's less liquid and a higher ratio of burnt surface to the rest of them.  But these were fine for a change.

Tuesday 29 November 2011

Open source web-based consoles

I'm looking to bring both my MUD and networked roguelike code-base into the 90's, erm.. that should be 00's these days.  A web-based console with connectivity to the backend server through the web server is the way to go.

I've been collecting candidate "already written wheels" and wanted to collect them in one place.

Forum thread: HTML+JS Tech Demo (demo).

A GPL licensed code-base which uses an array of character cells to emulate a curses-like display.

Advantages:
  • Cleanly written code.
Disadvantages:
  • Restrictively licensed.
  • Code bound to existing game implementation.
Forum thread: js-like beta (first version!) released (demo).
A BSD licensed code-base which implements three different display mechanisms, canvas, array of character cells and image based.

Advantages:
  • Liberally licensed.
  • More library like, than game specific.
Disadvantages:
  • Code is somewhat hard to follow.
Forum thread: DecafMUD (demo)
A unknown licensed code-base which provides a complete out of the box web-based MUD client. Supports different code pages, and able to interpret the complete telnet stream from negotiation to escape codes. Tries to use web sockets for connectivity, but can fall back on flash if they are not usable.

Advantages:
  • Complete solution
  • Straight-forward code.
Disadvantages:
  • Windows-incompatible repository contents, errors when cloned.
  • Official web-site down.
  • Telnet protocol support is superfluous, a modern MUD server should be have a direct connection and not be encumbered by these complications.
While the GPL license is indeed restrictive, and reason enough to avoid using a project.  In this case, given a client is kept separated from the server, it shouldn't encumber the server-side in any way that matters.

Sunday 27 November 2011

Dwarf fortress forum notes #1

On the overnight train from Beijing to Shanghai the other night, while the man on the bunk below me munched away on sunflower seeds, I really wanted to browse the Bay 12 forums.  The reason for this is that I've been thinking about procedural world generation lately, and not the graphical kind.  Having an ontology which defines a wide range of relevant scientific, cultural and historic facts would allow generation to produce something with a direct, if not subconscious, recognisable believability.

Browsing the Bay 12 forums some time back I came across posts by people who were researching geological, geographical, historical and other areas in order to suggest more correct and realistic directions for Dwarf Fortress brought to mind.  This is pretty much the same thing, except rather than gathering them in the hope (one acknowledged to be unlikely) that someone would incorporate them into their game, I'd be looking to generate my own from them.

Some initial interesting threads:

  • Geologic structures and the 3D ore veins.

    The first post touches on a lot of subjects related to underground geological generation.  Second post builds on this, and recommends a free book "Petrology of Sedimentary Rocks".  Pictures of giant crystals in real life caves.  Fault lines and similar things, with ascii diagrams.  Suggested potential use of perlin noise to model ore deposits.  Pointer to this "scientifically plausible"  world building open source project.

  • Add real solid density values for stones.

    From a world ontology point of view, this is gold. It not only has discussion about density and colour, but also temperatures like their melting points.  This was kind of what I was looking for when I was looking in the latest release of OpenCyc lately.. but failed to find within it.  There's even a link to data on various woods.  People are even having samples shipped to them and measuring them themselves, in order to get their facts straight.

  • Alchemists.

    Starts off talking with respect to the way the game works, rather than related aspects featured in history.  Turns to how it was featured in history, rather than in fictional sources like AD&D.  Veers to astronomy and the person responsible for modern perspective of alchemy.  Then to dwarf and magic related talk unrelated to history.

  • Evil plants in real life.

    Using actual plants that exist as a baseline for the believability of game plants, seems to be pretty relevant.  Initial post links to a cracked.com article about 10 creepy plants, then another post links to a cracked.com article about 6 things that shouldn't explode but did (specifically the sandbox tree).

  • Complete Weapons Database.

    A variety of Dwarf Fortress weapon definitions, the given weapon properties may or may not be generically useful or realistic.  No references given.  Pointer to a D&D pole-arm quiz, of unknown correctness.  Veered to mention of asian weapons, which is outside the scope of my 13th century England focus.

  • Absent pre-1400 technologies.

    Started with a list of pre-1400 technologies that are not currently found in Dwarf Fortress, with the note that its developer has stated that these are the only ones to be in the game.  Moved onto bows and blowguns, to actual guns and then to mysterious unreproducible inventions (damascus steel / archimedes mirror).  Then more about different kinds of bows and their uses and users.  And finally, back on topic with pre-1400 technology wishlist.

  • A few thoughts for the new city maps.

    Starts off with general wishes, but then moves on to relating how real cities came about, with links over to similar past posts in the "Future of the Fortress" topic.  Roman city planning.  Pictures and links to existing cities.

  • Alien Creature Behaviours and Myths.

    References to monster archetypes within original historical myths. A desire for Gaelic and other cultural faeries, with detail of specific stories.  Link to Russian house spirits wikipedia page.  Link to flying asian vampire head and introduction of Monstropedia, which might be a good source for further examples.  The Dullahan is brought up, said to be "a cross between the headless horseman and the grim reaper".  Something about Kitsune that I didn't read because Japanese culture is out of scope.  Then the topic gets further Kitsune detail, before heading off into wishful thinking territory.

  • Cooking and Brewing Diversity: The Food and Drink Megathread.

    Starts off with a breakdown of how cooking should ideally work, which is a good starting point for the elements that would be the breakdown for this part of the ontology.  Someone posts a list of recent cooking threads which look to cover a wide range of interesting parts of the big picture.  Reference to a wikipedia page on the history of alcohol.  Use of honey for preservation, and vinegar for cleaning.  Pies and their history are brought up.  The mining and storage of ice are next.  An uber-post with lots of history food-related pointers.

To be done:
Sources:
  • DF Suggestions board.

    Some of the topic titles infer presence of useful information, but there are a lot there.  A better idea is to start with known threads of interest and work my way through the posts made by people who post the most useful history/science-related posts.

  • Poster: Jeoshua (processed up to: May 06, 2011, 02:54:50 pm).

  • Poster: NW_Kohaku (processed from: April 11, 2011, 12:21:22 pm up to: May 19, 2011, 04:12:47 pm).

Anyway, that's a good start.

Next post: Dwarf fortress forum notes #2.

Miscellaneous food pictures

Back in mooncake season, I really wanted to eat a meat mooncake with decent flavour. So.. I bought this cheap beef one from the local supermarket, otherwise known as Century Mart.

2011-08-27 - Century Mart beef mooncakes - 01 - Outards

Bland with an unpleasing lard texture to the pastry unfortunately. But for 2.5 RMB per, what can I expect..

2011-08-27 - Century Mart beef mooncakes - 02 - Innards

Another attempt at buying cheap mooncakes of one sort or other. In this case, cheap pineapple mooncake from one of the corner store chains, Family Mart.

2011-09-06 - Pineapple mooncake - 01 - Packet

A look inside the packet.

2011-09-06 - Pineapple mooncake - 02 - In tray

Tastes a lot like flour, water and gelatine.  Not sure there's anything that tasted like pineapple, but there was a hint of "pineapple flavour" :-)

2011-09-06 - Pineapple mooncake - 03 - Innards

One Chinese dish I fall back to if nothing else appeals on the menu, is this one. In this case, I went to the restaurant across the road from my apartment complex and ordered it from the picture on the wall. It was very well made, spicy and tasty. At ~11 RMB, it wasn't a bad deal.

2011-08-21 - Across Street Restaurant - 01 - Eggs and tomatoes

In the corner store beside work, they had a new drink. I'm all for healthy food, and drinking vinegar is supposed to be good for what ails you. It.. well, I have no idea why. But this tasted like mild apple cider vinegar, too sugary for my taste.

2011-09-04 - Apple Vinegar drink sachet - 02 - Back

The back:

2011-09-04 - Apple Vinegar drink sachet - 01 - Front

It is hard to find what I consider to be healthy food in China. If it doesn't have sugar, bread, rice or isn't deep fried then it won't be easy to buy. One of the things that is easy to find here, is yogurt. In this case, I wasn't clear what exactly the difference between fermented milk and yogurt was. I am still not clear, but what I do know is that this was not very thick and was sweetened. Not recommended.

2011-11-18 - Fermented milk - 01 - Sachet - Front

The back:

2011-11-18 - Fermented milk - 02 - Sachet - Back

The style of packaging is more used for fabric softener back home.