4 Mar

My Caylus: Magna Carta videogame conversion

Filed under: Boardgames,PC Games 4 comments

I’ve put in more work into the AI of my videogame version of Caylus: Magna Carta. Its play is still far from optimal and any human who takes the time to properly think through all the moves will beat it easily, but at least it can now occasionally beat my wife and me. It also plays rather predictably so someone who’s used to how it thinks can find exploits. The AI uses a bunch of weighted heuristics to make its decisions, so nothing fancy like a general min-max problem-solving strategy or the neural net approach in Keldon’s Race for the Galaxy implementation. That stuff is way beyond my limited programming skills.

There’s not much left that I can improve without drastically overhaul the whole thing. It sorely needs to be aware of the risks of placing workers near the end of the path and the defensive use of passing early. And I could make it a bit smarter about dealing with other players. It should prioritize using the buildings of weaker players instead of stronger ones for example. But these are small incremental improvements that I’ll dip into when I feel like it. For the most part, the project is basically done and I’m pretty happy I’ve gotten this far.

I’ve also been looking into distributing it, though of course I’ll have to switch out the scanned images for placeholders. Unfortunately, it seems that compiling it for Windows-based systems is non-trivial. There are tools for packaging Python programs into Windows executables, like py2exe and pyinstaller. But for Python 3.2, which is what I’m currently using, only cx_freeze supposedly works and try as I might, I couldn’t get it to work right for me. I don’t think cx_freeze works for Pygame at all. This unanswered Stack Overflow question addresses my problem exactly. So unless I expect other people to manually install the correct versions of Python and the Pygame library, distributing it would be pointless.

26 Feb

The Secret of Monkey Island

Filed under: PC Games 1 comment

The remastered Special Edition jazzes up the game with new cartoon-style graphics. Too bad there are still very few animations.

The Golden Age of point-and-click adventure games is long past, but out of a sense of nostalgia for all those Sierra games I dabbled with when I first got involved with PC games, I bought the remastered versions of the first two Monkey Island games. I’ve never played any of these games before and the first one at least is widely considered one of the best things LucasArts ever made. Plus they were cheap and it doesn’t take long to play through them at all, so what the heck.

  • The remastered edition of the game includes not just spiffy new graphics but also full voice acting for every single line in the game. I wouldn’t have been able to play this game without these improvements. An awesome feature in this edition is that you switch between the two editions instantly, so you can see for yourself what the game was like back in the day, old-fashioned interface and all.
  • Old-style adventure games are hard! The puzzles in this game aren’t quite up to Gabriel Knight levels of insanity, but they’re still quite cryptic. In one instance, you get bananas out of a tree by dropping a rock onto a silly-looking makeshift catapult, thus sending the rock flying halfway across the island to hit said tree. Is that intuitive for anyone at all? Thankfully, the game comes with a pretty in-depth hint system or the game would be almost impossible to complete without looking at a walkthrough.

Read the rest of this entry »

23 Feb

Hojo Campaign Diary (Part 6)

Filed under: PC Games No comment

Rather than launch a direct assault on Kyoto, we elect to be patient and besiege it instead as the Ashikaga Shogunate still has a large garrison force in the city. It will take more than a year to starve the defenders out and our besieging army will need to survive the travails of winter. But at the same time, the siege itself will whittle down the defenders’ numbers, so we judge it worthwhile. Our Daimyo leads our besieging force while a small secondary army stands by in the vicinity to provide reinforcements if required. Of course, our Daimyo’s sons continue the war against the other clans and we eventually extinguish the Oda while the siege on Kyoto is being maintained.

Read the rest of this entry »

22 Feb

Hojo Campaign Diary (Part 5)

Filed under: PC Games No comment

In 1561, with no other option left to us if we are to fulfill our ambition to become Shogun, we end our alliance with the Oda and declare war against them. For years the war goes well as the Oda seem unable to organize any serious resistance. We take province after province that are defended only by local garrisons. It appears that our declaration of war took them by surprise and the bulk of their forces were engaged in the far west. Naturally, with the Oda as our enemies, we have no trading partners left and have to rely entirely on our domestic economy for income. We do encounter the Hattori as we conquer more of the Oda’s provinces, but they are allies of the Oda and make war against us as well.

By 1563, we grow so strong, controlling 17 provinces, that the ruling Ashikaga Shogunate rallies all the clans to oppose our expansion. By this time, only a handful of clans are left: Oda, Hattori, Honma, Shoni and Ouchi. Of these, we have met only the Oda and the Hattori and we are not trading with them anyway, so this announcement hardly fazes us. We continue to expand westwards into the lands owned by the Oda and still we see no sign of any serious concentration of troops. However, this expansion leaves our budget severely strained as we must maintain garrison forces in many of the provinces we control to prevent revolt and we do not produce sufficient koku to properly develop the infrastructure in all these new provinces.

Read the rest of this entry »

18 Feb

Hojo Campaign Diary (Part 4)

Filed under: PC Games No comment

We do not need to make a decision concerning the Oda immediately. The Uesugi have only one province left for us to take as the remaining two are cut off behind provinces already conquered by the Oda. Unfortunately for us, the Uesugi seem to have concentrated most of their remaining strength in this one province. We do not discover this until our Daimyo’s army is nearly upon them as we have moved our Ninja to our border with the Oda. By this time, it is winter and we must attack or face losses from the freezing weather.

Read the rest of this entry »

17 Feb

Hojo Campaign Diary (Part 3)

Filed under: PC Games No comment

The Satomi army enters Shimosa province with a sizeable force, but when they see the size of our defending army in the castle, they decline to lay siege. Instead, their Daimyo opts for guerilla warfare, putting the port facilities to the torch. This turns out to be a blessing in disguise for we gain better intelligence about their force composition as they approach. It turns out that they have bow samurai while our own archers are only ashigaru. A prolonged archery duel, such as would be likely in a siege battle, would only favor the enemy. So we sally forth from our castle to meet them on the field.

Our tactics for this battle are straightforward. The enemy has four generals and their associated cavalry bodyguards while our Daimyo is the only one of our generals present. We have equal numbers of archers, but theirs are all samurai. However, we have substantially more yari ashigaru than they do. So we have our ashigaru form up in a long line and have them charge straight towards the enemy archers and hopefully past them and into their own yari ashigaru. We keep a unit of yari ashigaru in reserve to intervene wherever the enemy cavalry seems ready to charge.

Read the rest of this entry »

15 Feb

Hojo Campaign Diary (Part 2)

Filed under: PC Games No comment

With the Ogigayatsu no more, we must now contemplate our next course of action. To the west lie the Imagawa. With their mere two provinces, and with Suruga being a particularly rich province that is renowned for its learned scholars, they are a tempting target. Unfortunately, they are allied with the powerful Takeda whose thundering cavalry are feared throughout all of Japan. To the north are the Yamanouchi, the erstwhile allies of the Ogigayatsu. They are weak and crushing them would be child’s play. However, reaching their home province of Kozuke would involve a long trek across the length of Musashi province and holding onto it once it is ours will prove troublesome. Furthermore, they seem to have lost the heart to fight and are unlikely to be a threat anytime soon. Perhaps it would be better to leave them as a bulwark against the more powerful clans farther north.

To our east are the Satomi. They control three provinces but have no allies. Promisingly, they are already engaged in a war with the Satake clan. Their two southernmost provinces Shimosa and Kazusa will be easily defended once they are ours. We decide to make them our next conquest. To that end, we send diplomats to the Imagawa and the Yamanouchi to sign trade agreements with them. This should send them a signal that we have no aggressive motives towards them. We already possess a trade agreement with the Takeda. Not only will these agreements improve our relationship with these clans over time, they will also generate a modest income. To the Satomi, we maintain our silence and let them read what they will into it.

Read the rest of this entry »

15 Feb

Hojo Campaign Diary (Part 1)

Filed under: PC Games 1 comment

(Most images in this series can be clicked to expand them to full size.)

In 1545, the Hojo clan is led by Hojo Ujiyatsu. Like many other clans in the Sengoku Jidai period, the Hojo is actually a young clan that assumed the name of a more ancient but long dead clan to gain prestige. Ujiyatsu’s father Ujitsuna grew up in Izu province where the original Hojo had once ruled. Ujitsuna not only took on this ancient and respected name, he posthumously gave a Hojo name to his own father. When Ujiyatsu inherited control of the clan at the age of 26, the Hojo owned two rich provinces, Izu, which contains valuable gold mines, and Sagami, which is famous for its blacksmiths. Both provinces are located on the southern coast of the Honshu mainland.

This means that when our campaign begins Ujiyatsu is a mere 30 years old and yet owns one of the strongest power bases in all of Japan. Astonishingly, by modern standards at least, he already has three sons. Ujimasa, the oldest, is only 7 years old so it will be some time before his children will be able to help their father realize his ambition of becoming Shogun, but it is certain that one day they will prove to be powerful assets. Ominously for the current Shogun, the original Hojo were destroyed more than 200 years old when their then vassals betrayed them. The traitors then went on to found the Ashikaga Shogunate. That such a powerful new clan has revived this ancient name must certainly strike fear into the hearts of the Ashikaga.

Read the rest of this entry »

Designed by Gabfire