Showing posts with label windows. Show all posts
Showing posts with label windows. Show all posts

Thursday, November 26, 2015

CryptoRL2 - update 0.8

0 commenti
A quick update for my roguelike, CryptoRL2 !






In this version:
  • added fullscreen option (F2)
  • add logo in main page, add images for buttons
  • add random blood pool around level (1%, from 1 to 10)
  • add monster rat, random wander around, weak
  • add monster snake, random wander around, weak
  • improved interface
  • improved instructions
  • added basic sound effects
  • added music by jonhillman

Play now


Saturday, November 7, 2015

CryptoRl 2

0 commenti
CryptoRL2 is a graphical roguelike, sequel for my CryptoRL!


As you can see now with improved graphics all made by me and following features:

  • fight for life in randomly generated dungeons,
  • permadeath
  • health potions, invisibility scrolls, torchs and traps
  • 3 type of monsters: spiders, stygian birds, aberration

Are you able to find a way back to your home?

Play it now (run on windows/linux/mac, require Java )




Made using


Monday, November 2, 2015

Wargame - a simple AI experiment

0 commenti
My focus in this experiment was to find a proper way to define a simple (very simple!) AI (without a better term, I refer on this limited example as AI) with goal to find and destroy opposing (player or AI) warriors.In order to do so, I've defined AI as a player that each turn:

  • for every units, build a list of possible moves,
  • rank moves using an utility funtion,
  • select first move for every unit and make it 




Build a list of possible moves

This could be a big problem and my quick solution was to analyze every cell around a single unit, check if is possible to move into it or attack another unit and define move according to these options.
In this limited case I choosed to have only two possible moves: MOVE or ATTACK. This of course simplify a lot number of moves and because AI is centralized and decide for every unit in a cycle, it's a simple algorithm. Simple but effective!


Rank moves using utility function

The key point of ranking is decide which factors impact on every unit. Because goal for AI is hard-coded and decided by me, it's simply: move near enemy and attack. So like you can realize, it's only a matter to rank better (think values between 0 and 1) attack moves and then moves, like:

  • if my unit can attack, utility = 0.6
  • if my unit can move and attack next turn, utility = 0.4
  • if my unit can move, utility = 0.2

About second point, it's possible because there is another analisis under the hood that try to see if after move there is a possible attack move.
Many factors could be added, like attack first hurted enemy units or rank enemy units by danger (in this example I have only warriors for both sides).. but hey, I want to make it simple!

Another key point is to use influence map to guide "blind moves" for AI units. Influence map is again a simple concept: for every enemy unit, just compute a map of influence of these units, starting from a max value of 100 from unit position and downgrade this value to 0, like in this image:




After assign utility value, ranking move is really simple!


Select first move

After ranking AI pick first move for unit and execute it and this is really surprising.. it's working! And in following small gif animation you can see two opposing AI fighting each other






See open source code on github




Play it now


Friday, April 16, 2010

How to map usb drive (winXp)

0 commenti

(Shenzhen Toptai Techonogy Co., Ltd)

A strange error today: using a bat file from the boss, I've a new drive mapped H: , all right for now. Problem is that my usb key was mapped with H: and windows go crazy: no usb?
No!
With this old (2005) tutorial, I've found a simple workaround:

* right click My Computer,
* Select Manage,
* Select Disk Management,
* Right click on the USB drive,
* Select the new drive letter,

Thanks to Rupert Russel!