I am Bok, a British-born expat living in China. I was born in Lancashire but identify as a 'plassie-Scouser'. I spent my youth growing up in Cumbria. Here I developed a great taste for exploration, climbing mountains and camping in the wilderness - a taste for travel that has defined my life.
People of another world arrested me and Samantha Carter and locked us in some kind of van. We could see that two men were patrolling outside, guarding us. We discussed how to escape, but we knew that it was possible we were on another world. Escaping would only mean we were still trapped.
I managed to break out of the van and disable one of the guards. I took his gun and started firing it at the other guard. The gun was some kind of energy weapon designed to incapacitate rather than kill. It needed constant firing to hold a target. I kept firing at the other guard as Carter and I fled.
We managed to make radio contact with Teal’c and O’Neill who told us that a nearby Stargate to Earth would open soon. Carter had a scanner on her that she could use to locate the Stargate and see when it would dial up. It also showed a ship warp into orbit and descend on our position. Pursued by ground troops and with a ship bombarding us we ran into a forest in search of the gate.
The gate’s position seemed to be moving, but with 14 seconds to spare we found the gate. The event horizon hadn’t formed yet. We considered giving the enemy the runaround for a few more seconds until the gate opened. But what if they decided to stay and guard the gate?
The gate seemed to open early. We weren’t sure if it was open early enough but the enemy was closing in so we took a chance and jumped through.
Meanwhile in space O’Neill and Teal’c seemed pissed at being left behind. “Fine!”, said O’Neill, “We’ll do it ourselves!” The gate was now spinning through space next to them. They opened the gate and floated through.
Note: Since I have a Windows machine this tutorial will focus on that platform.
Java Development Kit
You will need the JDK to develop in Java. You can get the latest JDK at the Oracle website. Make sure you download the Java SE 8u201 / Java SE 8u202 and make sure you download the JDK (not the JRE).
IDE – Eclipse
The IDE (Integrated Development Environment) is where you will write all your code. You will need an IDE for Java development. You can use any IDE you like, but most tutorials use Eclipse, and since I like Eclipse I will follow suit.
If you download the Eclipse Installer and run it you will be given an option on which IDE to install.
We need to choose Eclipse IDE for Java Developers. You can then select a directory to use as your first workspace. If you have many hard drives you should choose the one that has the most free space.
Set Up Forge
You will need to download the Forge MDK to develop Forge Mods. Make sure to download the correct version you wish to develop mods for. Select the MDK on the right for downloading and NOT the Windows Installer:
At the time of writing 1.12.2 was the latest stable version that Forge supports. The following tutorials will focus on that version for modding Minecraft.
After downloading Forge, you can extract it to the folder where you created the workspace :
Open Eclipse and select File -> Open Projects from File System… and select Forge project folder:
Now we need to decompile Minecraft. Navigate to the Forge folder in Explorer. Hold shift + right-click and select Open PowerShell window here. You should now see the following:
From here we need to run three commands. Some of these commands will take a while to run so be patient.
This will setup the project and give you a list of tasks you can run.
This will decompile MineCraft and set up the project ready for modding. This command will take a while, especially if you have a slow internet connection.
This will set up the Eclipse project.
And that’s it – we can now start modding Minecraft! But first we should think about Source Control.
Source Control: Github
Source control helps you track changes to projects over time. It can help you back up and revert changes that may have messed up your code. It’s vital for any development project, even if you work alone.
In my professional life I prefer Perforce, but Github is great for open source and solo projects.
You can create a github account at their website. Once you have done so, click the + in the top right to create a new repository.
Give the project any name you like then note the URL of the project.
Next we need to download and install git. Once we have done so we can open up our PowerShell window on the Forge directory again:
You can then run the following commands to create a git repository:
Here are a couple of tutorials I found useful for this. The Medium article sends you to an old version of Forge but it still contains useful information. Supergerrie2’s site contains many other tutorials for 1.12 modding that I’ve found useful so far.
Learning for the sake of learning is an exercise in futility. You will often end up losing focus and will never have achieved anything. You need to set a clear goal, and then figure out how to meet that goal.
What this means for Minecraft modding is that you shouldn’t set out to learn how to mod. You will learn how to add an item, a new material, a block, and a lot of basic things. But it will be a long time before you take the leap and create an actual mod.
Rather, you should figure out what you want to *create* first. Then figure out how to create that thing. It doesn’t hurt to keep your goals simple at first.
So that’s what this post is about. What do I want to create first?
Doc’s Dagger Mod
The design I’ve come up with is by no means original, but it should help me create something solid while I learn how to mod. I want to create an alternative weapon: a dagger.
The dagger will have 5 subtypes like any other tool: wooden, stone, iron, gold and diamond. Other mods could then extend this if they wanted to.
The dagger will do less damage than a sword but will attack faster. It will also have half the durability of a sword of the same type. It will not have a sweep attack – it will attack only one enemy at a time.
Players should be able to throw daggers. Doing so will cause the same damage as a melee attack. This will cost 1 durability if they hit a creature, or 2 durability if they hit a block. Thrown daggers will be recoverable provided they don’t break.
Until Next Time
So that’s the basic mod I’ve designed. By no means original, but it’s a simple goal that will leave me with a complete mod at the end. I’m confident I can learn how to do all/most of this. It won’t teach me *everything* there is to learn about Minecraft modding, but it will give me a start. And if I enjoy it, I can always design another mod after this one.
The French Municipal Council built Hengshan Park in August 1925. During construction, they took 5000 tonnes of mud from XuJiaHui River. They used the mud to fill out the low-lying channel to the north of the park. Afterwards, they built a pavilion on top and planted many arbour trees. In May 1926 they opened the park to foreign visitors only, like many other parks in Shanghai at the time. It had the name Beidang Park until October 1943 when they renamed it to Hengshan Park.
Hengshan Park Layout
Over the years the landscaping hasn’t changed much. Hengshan Park has a size 10,855 square meters. 3 camphor trees over 150 years old are preserved inside. Two are on the west side of the park with a bench beneath each. The third is on the far eastern corner. Arbor trees, bushes and flowers complete the scenery in this small park. Like many other parks in China, there are exercise machines on the north side.
Shen Jun Ru
In the centre of the park is a statue of Shen Jun Ru. In 1936, the Chiang Kai-shek government arrested Shen and 6 others. This caused a national crisis known as the Seven Gentleman Incident. It wasn’t until after the Japanese invasion in the Summer of 1937 that they were released. Later in 1949 Shen would attend the first Chinese People’s Consultative Conference (CPCC). Here, he would be appointed as the first President of the Supreme People’s Court. He held this position until 1954. Shen would also hold several other important positions in his later life. He died in 1963.
This park lies hidden away on Hengshan road, near Guanyuan road, in Shanghai. It is one of the many small places in Shanghai that you could walk past and never even know it was there.
Last time we were in Dandong we saw an advertisement for the Dandong Beer Festival. We planned to finish our holiday with some excessive beer consumption.
After returning to Dandong we rested up in our hotel for a short while. The we headed over to Peter’s for some food. Over lunch we realised that none of us knew the address to go to the Beer Festival. A frantic search over the wireless internet didn’t turn up anything.
We decided to just go to a taxi driver and tell him “pijiujie” – Beer Festival. The taxi driver smiled when we asked – he knew where to go. We hopped in and he took us to the other side of town. Before we got out he offered to take us back and gave us his number.
Before us lay a glowing neon sign. In both Chinese and English it declared “Dandong New District International Beer Festival”. Several of the locals had set up market stalls selling souvenirs and toys. People were going back and forth to and from the entrance of the festival.
It didn’t take us too long to find tickets and get inside. Once inside we saw a corridor lined with tents. Tents that weren’t selling beer. They were selling property. It turns out this whole thing was a set up to get people to invest in Dandong New District.
We hastily made our way past the property market and made our way to the large beer tent ahead. Buying a beer proved to be rather difficult. They had a system where you had to go to one place and get tokens then come back and fight your way to the front of the crowd at the bar then shout loud enough that the bartenders would pay you attention and finally tell you that they were out of beer.
It was a little annoying.
We moved past the first big tent and on to the next tent. There was a live music performance here. We finally managed to find a bar that would sell us beer. They had cheap wheat lager for sale. We paid up and stood impatiently as they took forever to pour our drinks.
Finally we got a taste of beer at the Dandong Beer Festival. It tasted stale. We stayed for a while watching the music and forcing our beers down us. It was clear that we weren’t going to have a good time here.
We decided to leave after our first beer. We called the taxi driver who had offered to take us back. He was surprised to hear from us – he had expected us to take much longer. He had taken another fare so it took him a while to come back for us.
In the meantime we looked through the wares being sold outside. There were Transformer rip-offs and dolls and other cheap toys.
Our taxi driver arrived and we went back to Dandong Old District. We returned to the bar we went to on our first night and knocked ourselves out with some real beers.
The day after our long detour from Ji’an we set off back to Dandong. We had planned to start driving down the Sino-Korean border from Linjiang. Unfortunately we ended up 90km off course so we would only get to do it from Ji’an.
This is a drive I would recommend anyone. The border is essentially a river going through a mountain range. There are few cities, especially on the Korean side. This means it’s a great route to see the natural side of China.
Along the way you can see North Korean villages and rice farms dotted along the river. Often they’d have mountains behind them. I wondered how much contact they had with the outside world. I saw a lot of bicycles in the countryside in the DPRK. There were some vehicles most of which seemed to be transporting goods or military. I imagine a lot of people riding between villages on bicycles. Perhaps to get to the nearest small town where there might be a school or a market. It would be interesting to see what country life is like in the DPRK. Unfortunately this seems to be one of the things the country wants to keep secret for now.
At one point during our drive we had to drive through a check point. Two soldiers carrying Chinese rifles signalled us to stop. These weren’t policemen; this was a military checkpoint. There wasn’t any trouble – they just checked our passports and let us through.
I guess there must be several checkpoints along this border on both sides. I thought about people who had fled North Korea. Would they avoid civilisation? This area had wide rivers and heavily forested mountains. You could take a boat at night but then you would have to destroy it so patrols wouldn’t find it. Then you would be faced with the prospect of difficult and uncharted terrain. Walking through one of the largest countries in the world and living off the land. It would be an impossible feat.
This is why they would need help from the Chinese side. Fake documents and long distance bus travel seems to be the way they do it. Perhaps this is one of the reasons why travel inside China is made so difficult.
Shortly after the checkpoint we came across one of China’s many “scenic spots”. A small area for parking was provided, allowing people to stop to take pictures. On seeing how impressed we were with the view our driver pulled in to park.
On the way I saw the Great Wall of China for the second time. Dandong has a tourist area where you can see more of the wall. I still haven’t been on the wall – I need to get this off my bucket list before I leave China.
We made it back to Dandong and needed to sort out our hotel. Unfortunately the communist style hotel we stayed at last time was fully booked. We booked into a nice hotel instead. Our driver took us there and left.
The hotel looked nice. Unfortunately appearances were deceiving. The rooms were tiny and the beds felt like rough cardboard. The shower didn’t have hot water. Somehow this fancy hotel was worse than the cheap communist one.
Well we were back in Dandong. And we had a beer festival to go to. At least we’d be able to drink ourselves to sleep.
We were in Linjiang having just rode a boat along the border. A friend’s uncle had offered to take us out to dinner since he lives in the area. Our plan was to join him for dinner and then go on to Ji’an. I hadn’t eaten that day so I was looking forward to trying out some local cuisine.
This is always a small risk as there’s a good chance I may not like the food on offer. But being in a city it’s always easy to find something you can eat: fast food or street noodles.
Our friend’s uncle was waiting for us on the bridge to Huandao Island. He took us to his van and told us to get in. Our driver was nearby so we had to figure out what to with him and his van. We said we could come back but our friend’s uncle said it would be better if we followed him.
So we set off following him along the road. He drove us out-of-town. Huh. Guess he lives in one of the outlying villages. We passed the first village. Guess it’s not that one. Then we passed the next one. When we passed a third we started wondering where he was taking us. We were driving in the opposite direction to Ji’an.
Our driver asked seemed to be getting frustrated. We understood why – we hadn’t paid him to drive us out here. He asked us where we were going. We told him we had no idea. He signalled our friend’s uncle with the lights and stopped the van. Our friend’s uncle stopped his van and the driver called him over. He asked him where he was taking us. The driver seemed to get angry at the response. Our friend’s uncle insisted that it wasn’t that far, and the driver disagreed. They went back and forth shouting at each other while we sat in the van waiting. At one point our friend’s uncle fetched a map. They carried on arguing over the map. I suggested we head back. My friend got out and lit up a cigarette. Eventually our friend’s uncle agreed to pay the driver extra money to take us to his place. He really wanted us to try the local food.
The rest of the drive took 2 hours. It turned out the place he wanted to take us was over 90km away. And in the wrong direction. I was starving by the time we got there.
We got out at Fusongzhen. We invited our driver to join us but he wasn’t interested. I don’t think he liked this guy. Our friend’s uncle took us to show us the local delicacy that we were about to eat. It was river lobster. Which I’m intolerant of . If I ate this I would spend the rest of the road trip running back and forth from the toilet. Or the bushes depending on where we were. I watched as they poured the still-living lobster into a grinder. They would make soup out of the resulting mince. My stomach grumbled.
What followed was an awkward dinner with his family. I had to decline all the food offered to me for fear of having a reaction. We were annoyed at being 90km away from where we were supposed to be. Yet we were totally British about not wanting to insult their hospitality. We had a few small conversations, but we just wanted to get out of there and back on our way. We had been delayed 2 hours already. We were also looking forward to another 2 hour delay to get back where we started.
After dinner we took some group pictures and then headed on our way. Our driver threw away the cigarette he was smoking as we returned. We now had a 4 hour drive to Ji’an which would be our next chance to eat. We said our goodbyes as we drove off then apologised to the driver once again. We then asked if there was anywhere we could stop for food.
We couldn’t, but we did drive past someone selling honey. A lot of people in the Chinese countryside do this. They run small hives and sell the honey to passers-by. We got out to negotiate the price of some honey. When we figured out what we wanted our driver sent us back saying he’s got this one. He bartered a really good price for us. It was an amazing thing for him to do for us completely out of the blue. It put us at ease because we knew now he wasn’t angry at us.
We didn’t get to Ji’an until after dark. We didn’t do much as we didn’t have any time left. We got ourselves booked into a hostel and went looking for food. The KFC round the corner was tempting. But then we found a Korean barbecue place closer to the river.
There was a weird ginseng based spirit for sale here. My friend decided that we were both going to do a shot. By shot he meant a full half-liter glass of it. Being the pushover I am I couldn’t say no. I was instantly drunk after downing that disgusting beverage.
We stopped at an import beer store on the way back to the hostel. It sold several imported beers from places like Belgium and Germany. The store had a little seating area in the back where we could sit and drink. After a few more beers we were done and headed back to the hostel. I fell asleep with a beer in my hand and covered the bed sheets in beer. This was why my girlfriend slept in the other bed. It was also why I had to pay a 1000 RMB fine the next day to cover the cost of cleaning the bed sheets.
The KFC was impossible to resist that morning so we ate breakfast there. Then we set off to do what we had missed out on the previous day. We would drive along the Sino-Korean border.
The next stop on our tour along the Sino-Korean border was Linjiang. This is another city that lights up like Vegas at night. Only the Chinese built this one across from a small North Korean farming community.
The hotel we stayed in Linjiang was right next to the town square. It was a nice hotel, but nothing too special. There is a small island to the south of the city called Huandao. This place is set up for tourists and the thing to do here is to get a boat ride along the border. So we set out to find a boat. Crossing the bridge to the island you first see a statue of Chen Yun. He was an important Communist Party leader who used to live in Linjiang.
We found people selling the boat rides on the farthest side of the island. It turned out our friend knows one of the locals here, so they talked for a while. I listened in, trying to understand what they where saying. I think my Chinese still has a long way to go.
Across the Yalu river we could see North Korea. The only thing of interest was a small village which looked to be a farming community. I asked if they had boats as well. It turns out that North Koreans aren’t allowed boats here, only the Chinese. I wasn’t sure if the restriction came from China or the DPRK. Or both.
It was late afternoon so we decided to explore the island and come back the next day for our boat ride. Further down the river was a larger boat moored on the island. There were several tables set up and a kitchen was preparing food. We decided to see if we could get some beer. Our friend and I sat down and asked for a beer while Yi went off to take pictures.
In Linjiang foreign tourists aren’t common so they were happy to see us. The beers were 5 RMB (around 50 pence). The owner sat next to us and told us “Chinese pay 5 kuai, foreigners pay 6 kuai!”. We could tell he was joking as we had already paid someone else. We laughed and he joined us as we drank, asking us the usual questions tourists get asked. A girl sat at another table jumped up and asked for a picture with me. This sort of thing happens a lot outside of the major cities in China.
We polished off our beers and left to walk along the river bank. Large forested hills prevent you from seeing too far into Korea. I wondered if there was ever any real communication between the villagers and Linjiang. Probably not. Any illicit activities going on between the borders would surely happen somewhere less obvious.
All along the bank several Linjiang locals were washing their clothes in the river. I got the impression that they did this because they preferred river-washed clothes. Much the same way we hang clothes out to dry in the sun in England rather than using a drying machine. The clothes smell nicer and don’t get damaged.
The sun set and darkness rose. Linjiang lit up like Christmas in Vegas. North Korea stayed in the darkness. It occurred to me their village may not have electricity, or at least not a large supply. With nothing more to see, we wandered back into town to get some food.
At night Linjiang has a large street market. There was more street food here than I had seen anywhere in China. I looked for the easy stuff: barbecued meat and/or noodles. My girlfriend went for some of the more local street food. We ate our fill then spent the rest of the night in a small bar we managed to find near our hotel.
The next day we had a solid plan. Yi has a friend whose uncle lives near Linjiang so he had invited us to lunch. So we were to ride the boat then go have lunch with him. We didn’t have much time before we met him so we went straight to the boats.
Our friend was waiting for us. We paid up front and were handed bright orange life jackets to wear. The three of us boarded the boat with our driver and we were off down the river.
The Chinese side was a built up urban area. Grey skyscrapers and factories filled the riverbank.
The North Korean side was definitely more of a rural area. Green hills, woods and forests lie beyond a small countryside road. The only thing connecting the two is a railway bridge. Dotted along the riverbank were several small towers. These towers watch out for people trying to cross the river. They were as hidden as they can be, but it was obvious what they were there for.
The Koreans lived their lives like any other. They were washing their clothes in the river. The kids were playing in the water. They would often wave at us as we went past. At one point we saw two naked men bathing in the river. They smiled at us and waved. Our boat driver told us this was a common occurrence.
Our boat tour was now over and we headed back to Linjiang proper. It was time to meet Yi’s friend’s uncle who had offered to take us to lunch. I hadn’t eaten yet so I was excited by the prospect of food. Unfortunately not everything was to go quite to plan.
Social media links can help a site gain a following. They can allow people to share pages and follow your social media pages. There are several plugins that can add links for you and they can work quite well. The problem is that these plugins hook your page into a third party application. I wouldn’t have too much trouble with this on its own. These applications seemed quite well put together. Then I found that my page load speed was increasing by an average of 3-4 seconds!
Thus I began a quest to figure out how to add social media links without plugins. I decided to have two places for social media links. The first at the end of each post, allowing users to share pages. The second would be links to follow my Twitter, Facebook and Google+ pages. These would appear in the sidebar.
The simplest way to add twitter buttons can be found on their website. It’s as simple as selecting the type of button you want and copy/pasting the code.
I wanted to have a vertical follow button like I was using for the others. There was no option for styling the button on the page. After a brief search I found this page. Here it lists a bunch of options for changing the style of the button.
Twitter code requires a URL. Each page and post in your website has a different URL so it’s not ideal to add one for each by hand. Fortunately you can replace the link with a WordPress function. If you look at the code provided you find it has something like data-url="http://www.your-link-here.com/subpage". We can add a call to get_permalink which provides the link to the current page.
The other thing you need to do is make sure that data-via references your screen name. The final code for my share button looks like this:
After finishing our DPRK tour, we decided to go on a road trip along the border. We decided to go to Huanren, Linjiang, Ji’an and then come back to Dandong for a beer festival.
We had breakfast in Dandong and sorted ourselves out with a driver. Our tour guide friend had contacts here so he was able to get a good deal for us. After breakfast, we grabbed some beers for the road and went to meet our driver. First stop: Huanren.
The drive to Huanren was uneventful. We spent this first leg of the journey on a highway so there wasn’t much to see. Especially after the sun set.
We arrived in Huanren after dark and the town was lit up like Las Vegas. We weren’t here to stay in the town though; our friend knew of a castle-like hotel. It was a little outside of town and we could stay there for a decent price. The only problem was he couldn’t remember where it is.
We made some calls to try to figure out where the place was. As we drove back and forth through Huanren our driver got more and more frustrated. In the end our combined efforts managed to figure out where we needed to drive. We got to the outskirts and spotted a lit up castle atop a dark mountain.
We made our way towards it, having to drive up a thin and twisted road to the castle. This was beginning to feel a little like a Bond movie.
We had arrived late in the evening. The lobby was empty except for the doorman and a woman at reception. Our driver left to find a cheaper hotel while we negotiated a room for the night. We managed to get a decent discount on our room. Sometimes it pays to be friends with a travel agent.
Our rooms were the finest I’ve ever seen. This was a five-star quality hotel. We were staying in luxury. My girlfriend decided to chill out in the room while Gareth and I went to explore.
We went outside for a walk. The hotel was lit up by floodlights which attracted giant moths. They were huge. Big enough to eat your face off. I might have an irrational fear of moths.
There was a fountain here that wasn’t running and an empty car park. I’m pretty sure we were the only ones staying here. Apart from that there was nothing else to see in the dark. We went back inside to find the bar.
It was around 9 in the evening. The staff had been looking at us all night, confused looks on their faces. They told us we should go back to our rooms. We asked about food and drink and they told us we should order room service.
They brought us a wine list and I spotted they had ice wine. I’d had this once before in Moldova, and fell in love with the stuff. We ordered this, a couple more wines and some food.
We headed back to our rooms and theorised on why this place was here and how it managed to fund itself. We were pretty sure it was some kind of front for a money laundering operation. Like I said, James Bond.
The next morning my girlfriend and I decided to get breakfast. We woke Gareth but he wanted to lie in for a bit longer. He warned us that the breakfast here was terrible anyway. At least there would be coffee.
I’ve seen some bad breakfasts in Chinese hotels. It’s usually bad Chinese food. If you’re lucky there’s some bad Western food. You can usually find something edible so it’s never that bad. And there’s always coffee.
This hotel had the worst bad Chinese breakfast I have ever seen. I couldn’t find anything I could stomach. There was no coffee machine so I asked one of the staff. No coffee. Not even that. I watched Yi eat some food while my stomach grumbled.
Yi asked if we could see the wine cellar. One of the staff went to fetch the key and took us to it. The cellar is built into the rock behind the hotel. The layout was perfect for hosting high-class wine tasting events. You go into a cave and see several wine barrels. A larger cave houses a huge table laid out waiting for guests. This must be the bad guy’s lair where he makes all his evil plans. I wondered where James Bond would be held prisoner.
Afterwards we went for a walk outside. We could see more in the daytime and the moths were gone so it was safe now. The fountain was running again. From the hotel’s position on top of a hill we could see the valley below us.
And there lay the truth of this place: a large vineyard and wine factory. I figured this place must be here to sell wine to distributors. Set them up in a nice hotel, give them a tasting and show them around the vineyard. The hotel itself doesn’t need to make money. The real money is made selling wine.
Gareth woke up. Our driver arrived. We checked ourselves out. On to our next stop: Linjiang.