Showing posts with label python. Show all posts
Showing posts with label python. Show all posts

Saturday, November 29, 2014

Parsing Creatures 1 .spr files (Extracting/Manipulating any of the game's graphics)

In a previous article I showed how to read Creatures 2 .s16 files to extract any of the game image data.
In this obvious follow up I will show you how to read out Creatures 1.spr files for the same result.

The Creatures 1 .spr file format is only marginally harder to parse than the .s16 format.
This is because the .spr files do not directly contain color information for each pixel, but rather an index number, to be used as a lookup index inside an external palette file to get the actual color data.
 
Thankfully, Python magic can once again save us most of the hard work and makes extracting an manipulating C1 images files a breeze.



Saturday, February 15, 2014

Connecting to the Creatures DDE interface from python

We've recently seen how easy it is to connect to the C1 and C2 DDE interfaces using VB.

This time we will show how easy it is to connect to those interfaces using python, which will prove useful in upcoming articles.



Connecting to a DDE server from inside python is can be a quick and easy process.
The hardest part is in acquiring the correct modules to do so, (which can be a real pain if you take it from the wrong side), there are also a couple specifics that make debugging the first DDE connections unreliable.
Fortunately I've sorted those perks out for you,and will show you the single quickest and easy way to connect to the Creatures 1 and 2 DDE interface from python.


Sunday, January 26, 2014

Finally, a Creatures 2 Norn autopsy tool


So, we've just learnt how to extract various information from C2 History files, among which a list of concentrations for a Norn's bloodstream chemicals at time of death.

We've also learnt how to map a chemical's number to a readable chemical name.

We can finally get to perform autopsies of dead C2 Norns!

Friday, January 24, 2014

Reversing and Parsing C2 allchemicals.str file format


Aright, we already covered how to obtain an up to date list of Chemical numbers and names inside our programs by extracting it from C1 game files.

Obviously this is an ability of much practical value for C2 too, so let's see how we could do that now.
I haven't found the allchemicals.str file format described anywhere so far, but the format is simple enough so reversing it should be Norn's play for us at this point :)

Thursday, January 23, 2014

Back to more traditionnal automated Norn genealogy using python and graphviz ( Intro )



We've already had a glimpse at using advanced tools for experiments in Albian genealogy.
Gephi is a nice tool for interactively browsing decently sized datasets on the macro scale, but what about more conventional genealogy tools ?

In this post I will show you basic use of graphviz in python to make some more traditional but far more detailed family trees automatically.This will once again be only a short glimpse at graphviz possibilities so we can use it as an useful tool further down the road.
Hopefully it will make you want to add this to your Albian explorer toolbox.

Wednesday, January 22, 2014

Parsing C2 histfiles

Once again, a quick filler post about parsing a random creatures file format.

This time we will be investigating the Creatures 2 "History file" format.

 This one is also already documented online, but being able to parse it can allow us to extract some interesting data.


I guess this post needed at least one picture

Sunday, January 12, 2014

Parsing C2 GameLog files with python.

In this post we will see how to precisely parse a C2 Gamelog file.
This file is an ordered collection of all main events happening in Albia : Birth, Ageing, Dieing, getting a Name, Exports or Imports.
Parsing it can be useful to redraw a full timeline of stuff happening in your world, or to see which Norns are still alive or were ever used, if you need to perform some cleanup in the game folder ( by default, genomes and sprites files accumulate in the game folder for each Norn and are never removed )

Whatever your needs are, I hope yo will find this quick reference useful.

Wednesday, January 8, 2014

Generating Creatures 2 Egg files with Python

The Creatures 2 .egg file format is one of the few well documented aspects of the game series.

Why bother writing about it on a blog about investigating undocumented game aspects then ?
Well, the ability to generate .eeg files is a pretty simple skill that might prove an interesting addition for anybody writing Creatures tools.

The aim here is just to show how quick and easy it is

Saturday, January 4, 2014

Introduction to advanced Norn genealogy using Social Network Analysis (SNA)




This post will be a quick taste of things to come.

I will show you where to look for Norn genealogy information in the game files, how to extract it using python, and then use it with more powerful tools than the built-in "family tree" of the original games to fully map out all of your Norn population.

We will only be scratching the surface of all those vast topics here, and each aspect of it will be the topic for a dedicated article further down the road. For now,I'm trying to get as much new and varied information out as I can. I hope this will bring some new topics, tools and knowledge to the Creatures community.