Skip to main content


Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - scojin

Projects / Re: OFF: Puppetmaster
The project is a great idea and sounds like it's off to a great start. It'll be nice to see more games released using the new engine! Personally, to be able to view the code showing off all of the new capabilities would be very interesting. Best of luck!
Libraries / Re: MapEngine for Sphere v2
So, I got the MapEngine to work with the simple template method; I was even able to change walking speeds and utilize the zoom aspect. But when I use the code for the more 'dynamic' version, I'm running into a few problems. There are no errors called and the game loads up fines, but the map isn't drawn correctly and none of the input works.
I created a new project, copy-pasted the code, adjusted for custom map and sprite, and still got the same result. I'll post some pics and a link to the smaller project I made.

Spoiler (click to show/hide)
Spoiler (click to show/hide)
Libraries / Re: MapEngine for Sphere v2
That was absolutely it. I didn't have my map's file extension as .mem. I guess I overlooked the fact of having to change it. Same with my sprites, also; had to change them to .ses. I figured it was something simple.
Bleh. Thanks for the quick response!
Libraries / Re: MapEngine for Sphere v2
I'm trying to use the map engine, but I keep getting an error:

uncaught JavaScript exception

RangeError: Invalid read size '-929892776'
   at TileBuffer (@/src/MapEngine/PixelBuffer.mjs:171:9)
   at MEngine.prototype.setMap (@/src/MapEngine/MEngine.mjs:380:9)
   at (native code)
   at MapEngine.prototype.start (@/src/MapEngine/map-engine.mjs:168:9)
   at (native code)
   at Anonymous function (@/src/main.mjs:199:1)
   at module (@/src/main.mjs:2:1)

I followed the template for cellscript and the mainscript and made the file path adjustments where necessary.
I'm using .rmp maps. I tried making a new map, and I also tried making a map with only a single layer, but still get the error. My tile sizes are 16x16, but that isn't what comes back in the debugger. Is there something I'm missing? Probably something simple...   :-\
Thanks in advance!
Engine Development / Re: miniSphere 5.0.1
Okay, thanks for the help.
Issues were file extensions(.js to .mjs) and getting rid of the tutorial changes.
I'll start a new thread if I have anymore questions.
"A stegosaurus, escaped from the stegosaurusfindrobot game. It finds you."
Engine Development / Re: miniSphere 5.0.1
I recently updated from 4.5 to 5.0.1 so I already know I'm going to run into a heap of issues with the project I'm working on. I got the cellscript working and have a successful build, but I'm getting errors in my main script when importing my own modules.
I'm sure there is a lot of nuance and order that is over my head, so is there an example demo that I could view? I've looked at the getting started tutorial and it helped a little bit, but I've got a small rat's nest that's gotta be sorted through.

Any tips on updating projects from the older version of minisphere? Any recommended reading would be great, too!
Script Support / Re: Surface Questions
Game Development / Re: The Screenshot Thread
Props Ma3vis!
The only thing that catches my eye is the brick wall, but that was really only because you mentioned it.
It all looks really good!
Script Support / Re: Surface Questions
Thanks, Cerberus! Major kudos!
Works like a charm.
Script Support / Re: Surface Questions
Yeah, that's correct. I'm basically piecing together an image from a few smaller images. I am preprocessing it when the menu is first called so it doesn't have to run the code to build the image on each menu update.
I was just puzzled on why the text would appear correctly but not the images.

I was able to test around and recreate the situation. If I create the surface as an image, it displays whatever image was loaded, however if I 'add' an image afterwards, it doesn't. I'm able to have text appear and I can get graphic primitives to display(line,circle,fill,etc.), but images do not.

If it helps, my menu is basically a loop that 'refreshes' after a key is pressed.
Let me know if you need anymore info.
Script Support / Re: Surface Questions
Yep, that was just a typo. Fix'd
My actual code has a bit more to it, so I made a brief example. :P
Script Support / Surface Questions
Okay, so I'm making a quest-log type menu that is semi-dynamic, meaning they have a set order and are organized by location, but don't appear until activated.
Like so:

So basically I have a function that checks, orders, and creates the selections for the menu and then returns the selection order and the selection display in an object. The display is created basically like so:
Code: [Select]

object.image = new Surface(w,h);
//draw header
//draw quests
font.drawText(object.image,x,y,whateverquest.title); //draw title
prim.blit(object.image,x,y,whateverquest.status);         //draw icon


object.selection = selection_array;
object.display = object.image.toImage();

return object

The problem is when I call the menu to be displayed, it only displays the title(from drawText) and not the header or icon(from prim.blit). This is my first go with surfaces, so maybe I'm just not using them right, or maybe I'm missing something?
Thanks in advance.
Site Comments / Re: New front page in development
Looks clean; I likes
Engine Development / Re: minisphere 4.4.2
Okay, makes sense. I've been been using v2.
I've got my globals marked with global., so guess I'll have to study up on using modules.
Basically, I've got my scripts organized by the objects they are i.e. character.js has a character object and functions that go along with it(stat updates,etc), items.js has item objects, creates items, uses, etc., menu.js the menu and all of its functions, blah, blah

Since I know they're loaded as modules I can start trying to figure out how to properly structure everything.
I want to continue with the v2 to take advantage of all the capabilities, even though it's over my head right now.
Thanks for the quick reply.