Sine Wave Scroller in Monkey2

Today’s little code, sine scroller in Monkey2. In the previous post you can download the code and data files for plain scroller. In this project same data files are used. Let’s take a look at the video: The scrolling isn’t very smooth in the video, but try the code: Namespace myapp #Import “<std>” #Import “<mojo>”Continue reading “Sine Wave Scroller in Monkey2”

Simple text scrollers in Monkey X and Monkey2

I coded today simple text scrollers in Monkey X and Monkey2. When the old school bug had bitten me I coded among other things the following: This night it’s time to just simple text scrollers code. Let’s take a look at the result of the Monkey X code: The source code: Import mojo2 Import brl.databufferContinue reading “Simple text scrollers in Monkey X and Monkey2”

Tile Scrolling with Maps Made with my Map Editor

Little tutorial on scrolling a map/world made with my Map Editor. First, the source code in full: Quite straight forward, but some words about the code. In the Map Editor dat-file, the first 4 byte integer declares the width of the map, the second the height of the map in tiles. The size of the mapContinue reading “Tile Scrolling with Maps Made with my Map Editor”

Embedding HTML5 output of Cerberus X to WordPress pages

The first thing you need is Code Embed plugin. If your HTML5 output code loads files, something must be changed in the JavaScript-code. Find the following piece of code: BBHtml5Game.prototype.PathToUrl=function( path ){ if( path.indexOf( “cerberus:” )!=0 ){ return path; }else if( path.indexOf( “cerberus://data/” )==0 ) { return “data/”+path.slice( 16 ); } return “”; } TheContinue reading “Embedding HTML5 output of Cerberus X to WordPress pages”

Unique Random Integers part II

Last year I wrote about my clumsy implementation of unique random integers system, I’ve used in my Memorable Ladies games. In those the speed isn’t a critical factor. It’s sufficient that the idea works. 🙂 In this post the idea behind unique random integers is the same, but implemented in a faster way. In the implementation IContinue reading “Unique Random Integers part II”

Example of Own Font Class in Monkey X

I seem to live in the past… Monkey X programming language has evolved into Monkey2, but I’m still sometimes using Monkey X. I made an example class to use in Monkey X with bitmap fonts converted with my Font 2 PNG. The example uses old Mojo-module, but old examples on scaling bitmap font made withContinue reading “Example of Own Font Class in Monkey X”