New to Fenix, need advice.


WarmFluffyUK

The Big Wad Bolf.
Joined
Sep 4, 2004
Messages
3,384
Location
UK
Website
www.retrotech.one
Hi guys,

I'm starting to play with fenix and thought I would port across one of the games I was in the middle of developing on the PC. I'm impressed with Fenix so far, it's a kewl language.

My question is, what resolution should I be setting the game to run on the GP2X, is it 1920x1024? I don't actually own a GP2X yet so I'm sort of working blind.

By the way, if you're interested in what I am going to port across, here's the unfinished PC version:

Myriad

I have only been mucking about with Fenix for a day or so but I have already got the target physics running. Basically the original game was based on the mouse so I had to sort of create mouse like movements with the cursors.

Clare.
 
The gp2x uses 320x240 resolution, like the gp32.

If you have any other questions regarding Fenix, feel free to pm or add me in one of the usual instant messengers (I tend to use only ICQ and MSN, look at my profile for contacts, my status is always away, but I`m often at my laptop since I`ve got dsl :D)
 
Thanks Quiest, you were a big help yesterday, I now have two other problems, one involves some maths which I am totally useless at, and the other is about collision.

Okay the maths one first:

I have one object, say the UFO, and I want it to fire at another object, how do I calculate the direction? I know it involves something like SIN or CO SINE or something, but like I said, Maths is very much a low point for me.

And now the collision problem:

I have multiple missile Processes, and multiple building Processes, In the building process I can detect when a missile has hit it, then I kill the individual building process by doing a return; . How can I detect which missile process has hit the building so I can remove that as well? Quiest mentioned an ID or something, but what's the syntax?

If anyone can help I will be a very happy bunny indeed!.
 
WarmFluffyUK posted on Aug 22 2006 at 01:52 PM said:
Thanks Quiest, you were a big help yesterday, I now have two other problems, one involves some maths which I am totally useless at, and the other is about collision.

Okay the maths one first:

I have one object, say the UFO, and I want it to fire at another object, how do I calculate the direction? I know it involves something like SIN or CO SINE or something, but like I said, Maths is very much a low point for me.

And now the collision problem:

I have multiple missile Processes, and multiple building Processes, In the building process I can detect when a missile has hit it, then I kill the individual building process by doing a return; . How can I detect which missile process has hit the building so I can remove that as well? Quiest mentioned an ID or something, but what's the syntax?

If anyone can help I will be a very happy bunny indeed!.
missile: the collision method returns the id of the process you collide with.
you now probably do something like
if(collision (type missile)) then
return;
end if
you can also do
collider = collision (type missile)
if collider
signal(collider,s_kill)
return
end if



about the second problem:
the simplest might be make the things fly with a seperate x and y velocity.
then all you've got to do is
xvelocity = xdistance/(sqrt(xdistance²+ydistance²)) * pixels per frame it should move
yvelocity = ydistance/(sqrt(xdistance²+ydistance²)) * pixels per frame it should move
with xdistance and y distance the difference in x/y coordinates
and then it should move directly to the target at the intended speed.
(if this acts funny, try to do in between calculations with floats instead of integers, xdistance/(sqrt(xdistance²+ydistance²)) will give values between 0 and 1, and an integer is a whole number ^^ (you can ofcourse multiply by the intended speed first to prevent problems)
 
Last edited by a moderator:
WarmFluffyUK posted on Aug 24 2006 at 08:41 PM said:
Thanks Racemaniac for replying, I have however sorted out both problems with help on MSN from Quiest.

Thank you again :wub:
np ^^
 
Last edited by a moderator:
Back
Top