Serious Trouble


devlkore

^_^
Joined
Jul 15, 2004
Messages
274
Website
www.sparktasty.net
Heyo,
This is a plead of sorts, I've coded the combo system into my game and it works really well in Flamebird, but it crashes my GP32 whenever I try to slash.

I don't know why this could be, the FPG should already be loaded, and I've been through the code loads of times and I'm sure there aren't any problems (any more).

If anyone knows what the hell could be going on or has any code snippets that might help (preloading, debugging, etc) or if anyone would be so kind as to look at the code and chat over IRC, please post.

I'm feeling really desperate because I don't want to remove the main mechanic of the game and it's really fun on PC, I just wish it would work on GP32.

ThanX in advance, BYEEEEE!!
 
Perhaps too big now ? :D
It can also be that there are too much processes going on on the screen (don`t know what the max is, but your pc should be able to handle more ;))
 
Even when I took out the enemies it still crashes.

I think it probably has something to do with either how many variables are getting shifted in a frame, or how I'm referencing my arrays.

Does anyone know how to set process priority?
 
I just wanted to point out, I made a test program yesterday that just shifts through all the graphics in the FPG used by the slash process, and it ran fine, so the FPG is ok.

The variables are being passed ok because the combo system wouldn't work if a single thing was wrong.
 
Even with the enemies cut out, the code is kind of long and it would probably require that I be able to talk somone through it.

I could comment it and e-mail it to anyone willing, but chatting over IRC would be better.
 
A quick question, how do you include other source files?

like: #include <"ship.prg">

And does anything special need to be done with the included files?
 
Does this work? Including other prg files? Thought it isn`t possible.
If it is, is there even a way to run other dcb files?
 
I don't know about launching other dcb files, but I'm pretty sure you can include other source files, because they're treated as if they're written in one big file.
 
It's really easy :D Here is a really good example, originally posted in the DivSite forums.

This is the main program:

Code:
program mijuego;

include "prg1.inc"; //You can use any extension you want

global
  cosa1;
  cosa2;

begin
  //...
end

And this is "prg1.inc":

Code:
global
  cosa3;
  cosa4;
end

process hola();

begin
  //...
end

process ola2();

begin
  //...
end
 
Don`t really understand your example.

Aren`t those included files just for making easy functions and to save space in your main prg?
How do you use them?

For example, I want to calculate a square root.
I`ll include sqrt.inc (a file with the program to calculate the square root).
Now I want the squareroot of the variable "a" written into "b".
Can I call it someway like this in my main prg: sqrt(a,B); ?

I hope, you understand what I mean.


EDIT: This would make my new project alot easier, now as I think of it :D
 
Yeah, you have the main program and the the included ones that only contain global variables and processes (not another main process). From the main program you can call processes that are coded in the secondary files.

These included files usually contain MORE than one process, so you can create a file called "math.inc" and have several processes, like one called "square_root()" with a "return()" sentence, another one for something else, etc.
 
Back
Top