Jump to content

  • Log In with Google      Sign In   
  • Create Account


Member Since 20 May 2008
Offline Last Active Jul 18 2013 09:29 AM

Topics I've Started

C-Lesh and the Super Mario World Game Engine

08 November 2012 - 11:17 AM

Long time, no posting. Anyways, this is what I have been working on:


Click on the "C-Lesh" and "SMW Engine" tabs.

I mentioned the Super Mario World engine a long time ago. (~4 years ago) At the time it was written in C++ and some of you took a liking to it. Now I have rewritten this thing in C-Lesh and it is totally cross platform. Using it and C-Lesh you can download a spritesheet and write some code and have a game. C-Lesh can currently compile to JavaScript, Python, or Android Java. The scripts produced are ready to use and can be incorporated into a web page or executed strait away. This is very exciting!

The engine itself (Super Mario World Engine) is event based and follows an event model that is targeted toward 2D platform games like Super Mario World. Collision detection is built into both the engine and C-Lesh, the language.

As I have seen some platform games creaping up on Android I am exciting myself about writing one. Right now there is no level editor so level will have to be built in ascii with the "def-map" construct. Look for this in the C-Lesh documentation. Those whom are interested please check this out!

P.S. C-Lesh is not for the faint of heart and is a cross between assembly and basic but with constructs like enumerations and objects. Also memory is completely static meaning no need for allocation, garbage collection, and all levels are loaded from memory which makes things fast.

Have any of you seen the Super Mario World game engine? I know its been 4 years. Look for it in the search.

New Topic Form Display Bug on Mac Lion

18 July 2012 - 09:11 AM

For asthetic reasons this should be fixed. The "Topic Title" extends way over to the right. This was also a problem on my own site but I fixed it be giving it a pixel width. Actually, this is a problem because I cannot even access the poll on the right side. It says "Poll" but the input field is covering whatever is underneathe it.

C-Lesh Game Programming Language/Console - Android Mobile

18 July 2012 - 09:08 AM

First off I created this as a hobby project in order to test the limits of JavaScript although the project has its roots in another one I did a while ago to emulate the TI-82 Basic language. However, C-Lesh, seems to be of great use for mobile, and potentially, online game development.

C-Lesh is an interpreter/compiler/console to allow for the creation of 2D games ranging from snake to, potentially, Mario. With C-Lesh you can simply download a sprite sheet from the internet and begin game creation. The language is similar to Basic with fixed memory divided into object-oriented lists and static variables. Constants are used to declare which memory locations would be used. C-Lesh also implements the Super Mario World Game Engine (please look up that thread to see what I'm talking about) to its full extent with features like built-in camera handling and collision detection. Text maps are also included in C-Lesh. A typical project would consist of two files: the code module (.clsh extension) and the sprite sheet (scaled up by a factor of 2 for quick drawing).

As mentioned before C-Lesh is written in JavaScript. This goes for the compile and interpreter. I decided to write C-Lesh in JavaScript for portablility and to avoid programming in Java and to create decent online games without the use of plugins. However, as JavaScript got fast and the fact that I saw NES/GameBoy emulators written in JavaScript I decided C-Lesh could be written in it as well. Currently, C-Lesh will run on Android mobile devices with decent performance given that the device is supporting Android 2.2 (Froyo) and up as JavaScript engines in earlier version are slow. Really slow.

Some links to satisfy your enthusiasm. (If it exists.)

C-Lesh Console: http://www.c-lesh.net => C-Lesh Console (open source)

* Currently can't show any games running as I am secretly working on those. I could post some screenshots, though... maybe later.

JavaScript Games on Android Phones

18 July 2012 - 08:52 AM

Recently I've been workin on a project called C-Lesh which is an interpreter written in JavaScript to develop games on mobile devices. (as of now) I have tested it on Android 2.2 (Froyo) and up and things seem to run at top speed. I bring this up because I am wondering if anyone has attempted games in JavaScript and put them on Android phones. From my own experience mobile phones can run JavaScript very fast, like C# or Python because of the native code compilation. Now here's my other question: If I were to convert the bytecode of my language, C-Lesh, to javascript and place it in an eval() statement would this also compile to native code? I'm thinking about generating JavaScript from bytecode for a speed boost. For anyone who wants to see how C-Lesh work please check out my site. But seriously, answering the latter of the two questions would be of great help to me.

C-Lesh Game Interpreter in JavaScript

28 April 2012 - 08:18 PM

This is a project that I've been tackling for the past few years. This is currently version 3 of C-Lesh. So what is C-Lesh? It's a programming language much like basic that is geared towards creating 2D games for www.c-lesh.net and publishing them on the site. Now for a little bit of history.

I started this project way back... probably like in 2005. Originally, I wanted to create an interpreter for the Calc Basic language. For those of you who don't know what that is it's basically the language of the TI-82 calculator. Anyways, this is relevent to me because I started programming on the TI-82. So I created this thing in C++. It was crude but could run text games on the terminal window. For those of you who remember Worm-Lang many many years ago (Does anyone remember?) you'll know what I'm talking about. However, the first version of C-Lesh could not output pixels - just text. I then proceeded to work on another version of C-Lesh and released the old one on SourceForge sometimes in 2008.

The first version of C-Lesh was crude. All variable were predefined as letters like in Calc Basic and there were no lists so programming was a challenge. This sucked so I began working on C-Lesh 2. The newer version included lists which could be configured to a specified size. It could also output graphics. I did manage to write a game in this language but it was sloppy. Like the first version the language has no subroutines, jumps, or memory allocation. All memory is fixed and defined by the programmer. This may seem to suck but on the bright side there is no need for garbage collection or freeing of memory.

So now there is this version of C-Lesh written entirely in JavaScript. I originally wrote version 3 in Java using an applet to implement the interpreter but that caused problems with porting. So I decided to do the thing in JavaScript and challenge myself. The compiler and interpreter are all written in JavaScript. JavaScript has gotten fast and there is even an NES emulator written in it that runs at a decent speed. This is one of the things that inspired me to do this.

C-Lesh 3 is much like basic but with fixed memory. As mentioned before there are no subroutines, jumps, or dynamic memory allocations. Basic control structures like if...else...end-if and while...end-while exist. All statements are in command format as so: output [STR_HELLO] at 0 0 C-Lesh does not do string processing just numbers so strings must be loaded at initialization time. There are also commands to deal with lists which are called segments in this language. C-Lesh outputs to the HTML 5 canvas which is embedded in the page - much better than using Java applets. They suck! You can also create text maps for levels like this:

x p x
x x

x = wall
p = player

These can then be loaded into the game.

You can write your games online test them. You can pull the code from the site because it's saved. Just download <your program>.clsh. If you have any questions, comments, or want tutorials just send a message to me. As a side note I haven't fully tested the language and it is still a work in progress so let me know.

The interpreter resides on my website. You can get there via the link in my signature. You do not need to register an account or anything. Have fun!