Switch to the Czech version

Tuesday, 8 January 2013

Alecraft domains working

I totally forgot about my old Alecraft hosting, so the domain was dead for a while. But fear not, for it is up and running again!


alecraft.dejvino.com | alecraft.dejvino.cz

Both the original dejvino.cz and the newly created dejvino.com domains work with the Alecraft subdomain. The website has been migrated to my new hosting. Now you can play my good old Alecraft/Minicraft version again. Oh yeah!



Monday, 7 January 2013

Alecraft :: Style change report

After playing around with a few ideas and experiments, this is my current status:

Overview

Free-look

Free-look

As I was aiming for a rogue-like style, the basic overview mode shows the map from above, the way we are used to play tile-based games.
But the view can be freely changed to any angle you want. This way you can examine the surroundings quite naturally. That is why the "tiles" are not just a flat square on the ground, but they use the whole volume of the given tile block to represent a tree, a zombie, ... or even a butterfly!

Wednesday, 2 January 2013

Alecraft ... bugs everywhere!

There are bugs everywhere! Some are even- ... procreating!

Alecraft received another style change

The reason I paused all work on Alecraft (my tile-based RPG game) for quite a while is because it strayed from it's path. It became something I didn't like - clumsy, semi-real-time building game with weird controls.

This had to stop. And so I went ahead and changed a few core concepts of the game engine.
  • It is now a turn-based game. I considered this option in the very beginning of writing the game engine, but decided to make it more active, make it real-time. It was not a good idea. It resulted in a CPU-heavy update loop, because a lot had to be recalculated every single frame. Now the rendering loop works mostly with a static scene. Some games are just meant to be played in turns...
  • Graphics are simpler. Following the footsteps of any great rogue-like game, players should exercise their fantasy and not rely on (not so) fancy graphics. Entities should appear as tiles, simple icons representing something abstract. I will not go as far as using only ASCII characters, but it could be created as a skin in the future.
Let's hope this new direction of development makes this game more fun (to make and to play)!

Thursday, 13 September 2012

Distributed social network - Friendica

In the past week I've discovered that there are actually working examples of distributed social networks. What is a distributed social network, you ask? (If not, skip this part.)
It is something like Facebook or Twitter, only better! But seriously: the problem with the regular Internet social networks is that there is basically just a single company running the network and owning your data. They can do whatever they want with the data you and your friends supplied. Not to mention the influence of other major companies or governments. With Facebook, this is a known issue. As soon as someone reports your account for some misbehaviour, you are done. No questions asked. Mostly because the people running the server have no time or possibilities to really solve the users problems and quarrels. One good example would be different laws dictated by different governments. As all of the larger social network sites are global, they span many geographical borders. They also grew pretty fast in the beginning and have failed to adapt to this change. The result is that the site is ruled by laws of the USA although they also operate in Europe, for example.But even if this issue were fixed, you would still be left with a single company holding personal data of a large percentage of the Internet population. Holding you hostage and helpless.
This sounds horrible, is there something that can be done? Of course! This is where the distributed social network comes to our aid. The concept is pretty simple - you (or someone you trust) can run your own social network server. This way you are the one who owns the data, no one can change anything without your approval. To stay connected with your friends, you just add links to their profiles (be it a personal server or a conventional social network) and the servers do the rest - they exchange all the posts and messages, transfer photos, ... simple as that. And thanks to open standards and protocols, you don't even have to have the same server software.

As I set out to find the ultimate distributed social network suited for me, I came across Friendica. It is a fairly grown and developed community with a fully working server application written in PHP. This is a great thing for two reasons: first, I have years of experience programming in PHP and can therefore write and customise my own installation and second, you can find a really cheap hosting for your application.

My very own Friendica server and profile can be found here: friendica.dejvino.com/profile/dejvino

As this area has become really interesting for me, it is certain that there are more Friendica related posts coming. For example: crossposting is Friendica's killer feature for me - I've connected Facebook, Twitter, Blogger, Tumblr and most recently WordPress. But more on this later.

Thursday, 30 August 2012

Database WTF

My 2 NULL WTF moments for today:

1. MSSQL is a twisted kind of database. It likes making things difficult for us developers. When you have a column with a NULL value, you would expect to get the value as a null of some sort (more specific - programming language null constant). But the result is an empty string...WTF?
How will I know whether it is a NULL or an empty string in that column? ... I have to what? Use some ISNULL functions and stuff? For something simple as that? Well that seems pretty weird.

2. MySQL is only a bit better. It turns out when you insert a single row with a NULL value into a column that is not supposed to be NULL, it fails with an error. This would be expected. But when you try to insert two or more rows in a single INSERT statement, the NULL changes to 0 and no error occurs. WTF?

I hope this is all for today...

Saturday, 4 August 2012

Dusty room - HTML5 example

This week I've given HTML5's canvas a go and created a showcase page featuring a dynamical dust-particles simulation. It can easily be included into any kind of web page to add this special effect to it without changing the way users work with the original page.


Here is a live demo.

As a framework for handling the canvas I chose EaselJS, which seems like a nice graphical library with sufficient documentation. It features most of the expected 2D graphics-engine building blocks and built-in graphical effects. Most techniques and common tasks are explained on examples.

The particle system is based on the following rules:
1. Each particle has: position, velocity.
2. Velocity changes slightly (randomly) every frame - to add some "Brownian motion".
3. Nearby particles's velocities are slightly averaged every frame - creates streams of air.
4. Mouse cursor influences the nearby particles as if it were a particle (a bit "heavier" one).

Notes on viewing the result in various browsers:
Google Chrome 20 and Mozilla Firefox 14 - everything worked right and fast. No problems there.
Just as a side note - because I don't use Firefox that much, I was able to test several versions as it was upgrading only a few versions at a time. FF8 - awfully slow! FF11 - pretty slow, jerky. FF14 - works OK. Nothing apart from the performance change was noticeable. Nothing broken along the way.
Microsoft Internet Explorer 9 - the canvas-part works fine, it is even pretty fast, but the text-shadow style is not working (which is not really an issue for this demo).
Dolphin browser on Android - everything works right! It is dead-slow, but this was to be expected.
Opera? Safari? Who knows, I know I don't...

What next? I think this could be a nice "plugin" to some page I might create in the future. The least I can say is that canvas is a pretty nifty and usable thing now. It is time to get to know it!