PDA

View Full Version : SitS


skyhawk
2003.05.13, 01:21 PM
arrrr, someone deleted my last thread, I planned on reusing that. Oh well. Anyways, my game doesn't feel smooth to me (seems to jerk and the controls are unresponsive) but I need other people's opinion before I start hacking out more code. Also I need to know if there are any peculiarities(out of bound error from walking off screen (THIS SHOULDN'T HAPPEN ANY MORE! :mad: ))

anyways, give it a try at:
http://www.hkasoftware.com/skyhawk/SitS/SitS004.app.sit

natael
2003.05.13, 01:42 PM
The controls are indeed unresponsive. Also noticed that the background flickers when the screen is scrolling. It's most noticeable in the water.

Are there any controls besides WASD?

skyhawk
2003.05.13, 02:04 PM
Originally posted by natael

Are there any controls besides WASD?
not yet

jamie
2003.05.13, 02:10 PM
I'm not sure if unresponsive is the right term... for me once I start moving the character he goes about the size of one sprite then does a quick pause, then continues normal until I stop. Once I stop he seems to glide along the ground for the distance of one sprite before he stops.

I didn't have any problem with flickering.

skyhawk
2003.05.13, 02:25 PM
Originally posted by jamie
I'm not sure if unresponsive is the right term... for me once I start moving the character he goes about the size of one sprite then does a quick pause, then continues normal until I stop. Once I stop he seems to glide along the ground for the distance of one sprite before he stops.

I didn't have any problem with flickering.

yes, this is the problem I am having. Apparently I screwed up my keyhandling badly. The other problem I get is... well.... let me upload a version and show you.
http://www.hkasoftware.com/skyhawk/SitS/SitSbad.app.sit

Ian Kerr
2003.05.13, 04:51 PM
Hi,
I downloaded it, tried it out and I also had a problem with the input. If I'm holding down a key (key 1) and then I press and hold down another key (key 2) at the same time and then release key 1 the character keeps moving in the direction of key 1 rather than key 2. As for the scrolling, have you considered doing it like the Legend of Zelda: A Link to the Past? I think in that game it just does one big scroll when you get near the edge of the screen. Anyways, other than that it looks nice!

-- Ian

natael
2003.05.13, 05:02 PM
Originally posted by jamie
I'm not sure if unresponsive is the right term... for me once I start moving the character he goes about the size of one sprite then does a quick pause, then continues normal until I stop. Once I stop he seems to glide along the ground for the distance of one sprite before he stops.

I didn't have any problem with flickering.

I also get a pause when changing direction. I tried the game on my iBook, so maybe the flickering is an LCD issue?

macboy
2003.05.13, 05:02 PM
Originally posted by Ian Kerr
As for the scrolling, have you considered doing it like the Legend of Zelda: A Link to the Past? I think in that game it just does one big scroll when you get near the edge of the screen.I think that was mostly because each screen was a separate "location", while with scrolling like this, you can support bigger levels more easily :wacko:

skyhawk
2003.05.13, 06:24 PM
Originally posted by Ian Kerr
Hi,
I downloaded it, tried it out and I also had a problem with the input. If I'm holding down a key (key 1) and then I press and hold down another key (key 2) at the same time and then release key 1 the character keeps moving in the direction of key 1 rather than key 2. As for the scrolling, have you considered doing it like the Legend of Zelda: A Link to the Past? I think in that game it just does one big scroll when you get near the edge of the screen. Anyways, other than that it looks nice!

-- Ian

I find the scrolling I'm using is more fluid. Link's scrolling was too jerky. Anyways, I'm trying to tackle the key problem. It is really more annoying than you think :D

AJ Infinity
2003.05.13, 07:56 PM
Use SDL for arrow key downs. I hate AWSD. It's annoying. Heck, you're in Cocoa! Use Cocoa's arrow key handling. Anyway, I'm having a similar problem in H2O (I changed the view to isometric and redid the art, I made it look better, etc.).

OneSadCookie
2003.05.13, 07:59 PM
Originally posted by AJ Infinity
Use SDL for arrow key downs. I hate AWSD. It's annoying. Heck, you're in Cocoa! Use Cocoa's arrow key handling. Anyway, I'm having a similar problem in H2O (I changed the view to isometric and redid the art, I made it look better, etc.).

:shock:

Josh
2003.05.13, 08:12 PM
How do you get and respond to the keys?

skyhawk
2003.05.13, 08:29 PM
Originally posted by OneSadCookie
:shock:
I mimic that response :shock:

anyways, you will be able to change keys later.

As for getting keys, this is what I use

-(void)charPressed: (unsigned short)bob
{
//int a;
if(bob==controls.keymove[UP])
{
jeany.changedir(UP);
controls.move[UP]=1;
}
else if(bob==controls.keymove[DOWN])
{
jeany.changedir(DOWN);
controls.move[DOWN]=1;
}
else if(bob==controls.keymove[LEFT])
{
jeany.changedir(LEFT);
controls.move[LEFT]=1;
}
else if(bob==controls.keymove[RIGHT])
{
jeany.changedir(RIGHT);
controls.move[RIGHT]=1;
}
}
-(void)charUnPressed: (unsigned short)bob
{
if(bob==controls.keymove[UP])
controls.move[UP]=0;
if(bob==controls.keymove[DOWN])
controls.move[DOWN]=0;
if(bob==controls.keymove[LEFT])
controls.move[LEFT]=0;
if(bob==controls.keymove[RIGHT])
controls.move[RIGHT]=0;

}

and then in my main loop (draw rect) I have:
a=jeany.inc();
//if(a!=-1)
// controls.move[a]=0; // this causes the what appears to be stopping every tile, but this is caused by key repeat rate.
if(a==UP && dd>0 && jeany.y<townmapbg.numy()-8)
dd--;
if(a==DOWN && dd+15<townmapbg.numy() && jeany.y>7)
dd++;
if(a==LEFT && cc>0 && jeany.x<townmapbg.numx()-10)
cc--;
if(a==RIGHT && cc+20<townmapbg.numx() && jeany.x>10)
cc++;
if(controls.move[UP])
{
if(checkcollision(jeany.x,jeany.y,UP))
jeany.walk();
else
controls.move[UP]=0;
}
if(controls.move[DOWN])
{
if(checkcollision(jeany.x,jeany.y,DOWN))
jeany.walk();
controls.move[DOWN]=0;
}
if(controls.move[LEFT])
{
if(checkcollision(jeany.x,jeany.y,LEFT))
jeany.walk();
controls.move[LEFT]=0;
}
if(controls.move[RIGHT])
{
if(checkcollision(jeany.x,jeany.y,RIGHT))
jeany.walk();
controls.move[RIGHT]=0;
}

skyhawk
2003.05.13, 08:38 PM
jeany.changedir(direction) changes the way you are facing, unless you are walking (so you don't slide)

void wpeep::changedir(int bob)
{
if(wdir==-1)
dir=bob;
}

jeany.walk() forces the character to walk the direction they are facing
void wpeep::walk()
{
if(wdir==-1)
wdir=dir;
}

so you see, by pressing the keys I am changing the motion(if not currently walking), and then in my main loop if you are pressing the appropriate move key... and wdir != -1, then he walks in the "dir" direction.

maybe this means somethig to somebody somewhere and they see a light and can shine it in my eye

AJ Infinity
2003.05.13, 08:53 PM
Is that ObjC++? LOL, I'm just a spoiled Flash developer. I get key handling easy. :D


if(Key.isDown(Key.UP)){
mySprite._y -= accel;
}


Never tried arrow key support in Cocoa. I'm still learning OBjC++ (I know C++ though).

Mazilurik
2003.05.13, 10:28 PM
Originally posted by AJ Infinity
Use SDL for arrow key downs. I hate AWSD. It's annoying. Heck, you're in Cocoa! Use Cocoa's arrow key handling. Anyway, I'm having a similar problem in H2O (I changed the view to isometric and redid the art, I made it look better, etc.).

:blink:

I think another "Make Fun of AJ Day" is in order... (http://dictionary.reference.com/search?q=non%20sequitur)

AJ Infinity
2003.05.13, 10:56 PM
Dunno why I said "I hate AWSD".

OneSadCookie
2003.05.13, 11:00 PM
That was the least of our problems...

skyhawk
2003.05.13, 11:14 PM
conclusion: AJ has many problems.

Anyways, I believe I have fixed the problem. If enough people say it works, I can get to work on important stuff.... like exiting maps, triggers, and more tiles.

http://www.hkasoftware.com/skyhawk/SitS/SitS005.app.sit

AJ Infinity
2003.05.14, 07:47 AM
One of those problems is not getting enough sleep. :wacko: :zzz:

Reread's AJ's first post in thread

Never mind what I said.

>anyways, you will be able to change keys later.
Good.

skyhawk
2003.05.16, 01:33 AM
Latest update:
integrated early work with new work
search by pressing 4 (numpad or other 4) (and no you can't find anything yet... but if you do.... ummmm please let me know? :shock: )

aware of the only bug I can see (walking with dialog box)

http://hkasoftware.com/skyhawk/SitS/SitS006.app.sit

AJ Infinity
2003.05.16, 08:20 PM
Wow, you've gotten pretty far with this version. Good work. And you got collision detection too. Rect based, correct?

skyhawk
2003.05.16, 11:21 PM
Originally posted by AJ Infinity
Wow, you've gotten pretty far with this version. Good work. And you got collision detection too. Rect based, correct?

tile based and people based. Eventually the people will move on their own free will, and when they do, no 2 people will be able to move to occupy the same spot at one time. I have a lot of stuff already in the engine, just other features need to be done to bring them out.

skyhawk
2003.05.17, 11:21 PM
alright new version:
keys - WASD + 4,5,6 (6 is the "search" key)

there are 2 items on the map (non visible) for yall to find. In the game it won't be this hard (you will most likely look in a barrel, I just haven't drawn any barrels out yet).

First person to find both items gets... ummm... a hug! :D

http://hkasoftware.com/skyhawk/SitS/SitS007.app.sit

hint: first item is in bottom left area

as always, anything you feel like is a bug please report, also suggestions are welcomed too.

P.S the dummy item isn't one of the 2 legendary items ;)

codemattic
2003.05.18, 02:23 PM
Originally posted by skyhawk
there are 2 items on the map (non visible) for yall to find. In the game it won't be this hard (you will most likely look in a barrel, I just haven't drawn any barrels out yet).

First person to find both items gets... ummm... a hug! :D


well - I tried cheating - I opened "town1.map". In the last block of data there is a 011 in the bottom left corner and a 012 in the top right. I went to those locations thinking they were the legendary items - but I couldnt find anything. This is with version 7. No hug for Codemattic.

However, I would like the box and text to animate much quicker!!

This is going to be a cool little adventure/rpg - I can feel it.

Bachus
2003.05.18, 03:12 PM
Eventually the people will move on their own free will, and when they do, no 2 people will be able to move to occupy the same spot at one time.

Ick. I always hated the way old RPGs like Final Fantasy and Dragon Warrior could trap you with the wandering NPCs. You'd walk down a dead end and an NPC would follow you. Then you have to wait for that NPC to randomly walk back out before you could escape. Later RPGs let you push the NPCs, or just walk over them.

skyhawk
2003.05.18, 03:47 PM
well - I tried cheating - I opened "town1.map". In the last block of data there is a 011 in the bottom left corner and a 012 in the top right. I went to those locations thinking they were the legendary items - but I couldnt find anything. This is with version 7. No hug for Codemattic.

You have to face the square where it is at. Think of it like a treasure chest. You face the chest then search.

However, I would like the box and text to animate much quicker!!
Yes I was thinking this too. I will make the box popup faster, but the text speed will be in the preferences (not there yet :D )

Ick. I always hated the way old RPGs like Final Fantasy and Dragon Warrior could trap you with the wandering NPCs. You'd walk down a dead end and an NPC would follow you. Then you have to wait for that NPC to randomly walk back out before you could escape. Later RPGs let you push the NPCs, or just walk over them.

I will do my best so my very fat NPCs won't block you. They should be rather non intrusive and the houses will be big enough (and the doors will never be blocked on accident ;) ) to allow rather free movement.

Due to uDG2k3 coming up, work has been suspended specifically on this. However, the tile engine is continuing to be updated and sprites will slowly be made over time. Work will resume after the contest. I apologise for the inconvenience.

codemattic
2003.05.19, 02:10 AM
Originally posted by skyhawk
You have to face the square where it is at. Think of it like a treasure chest. You face the chest then search.

funny!