My own action adventure engine
- TechnoCat
- Inner party member
- Posts: 1611
- Joined: Thu Jul 30, 2009 12:31 am
- Location: Milwaukee, WI
- Contact:
Re: Action adventure game map test
When you draw at non-integer pixels it is openGL that is blurring the edges I believe. I also believe pixel are represented by (0.5+n,0.5+m), m and n being integers starting from the top left of the screen. Everyone correct me if I'm wrong.
- Jasoco
- Inner party member
- Posts: 3727
- Joined: Mon Jun 22, 2009 9:35 am
- Location: Pennsylvania, USA
- Contact:
Re: Action adventure game map test
If you draw an image at a whole number it will not blur. If you draw at a decimal you will get blurring. So you can floor the X and Y values before drawing to get it to not blur.
If you draw a shape with a line width that is an odd number, you will get blurring unless you add .5 to the X and Y. So 1, 3, 5, 7, etc would need .5 added to the X and Y while 2, 4, 6, 8, etc will not blur. Since it draws the lines at the halfway point of the thickness. 2 divided by 2 = 1. 1 divided by 2 = .5. 7 divided by 2 is 3.5. You'll add .5 to compensate.
If you draw a shape with a line width that is an odd number, you will get blurring unless you add .5 to the X and Y. So 1, 3, 5, 7, etc would need .5 added to the X and Y while 2, 4, 6, 8, etc will not blur. Since it draws the lines at the halfway point of the thickness. 2 divided by 2 = 1. 1 divided by 2 = .5. 7 divided by 2 is 3.5. You'll add .5 to compensate.
Re: Action adventure game map test
OK gentlemen. It's 2 AM, and after lurking some random forum for an hour I've hacked in code to allow travel between maps.
- Attachments
-
- SpaceNinja.love
- Now with *two* levels
- (42.88 KiB) Downloaded 100 times
Re: My own action adventure engine
It's my thread and I can necropost in it if I want to.
The cats are gone, but I finally have walk animations.
The cats are gone, but I finally have walk animations.
- Attachments
-
- SpaceNinja.love
- No more cats
- (147.81 KiB) Downloaded 111 times
- arquivista
- No longer with us
- Posts: 266
- Joined: Tue Jul 06, 2010 8:39 am
- Location: Insert Geolocation tag here
- Contact:
Re: My own action adventure engine
DON'T MESS WITH KITTIES! I WANT THEM BACK!
well, people anims seem nice also, but aren't kitties
There isn't any new funcionality right? Don't care, things still good. Keep us posted with good stuff!
... you killed the kitties, sniff, sniff...
well, people anims seem nice also, but aren't kitties
There isn't any new funcionality right? Don't care, things still good. Keep us posted with good stuff!
... you killed the kitties, sniff, sniff...
--------------------------------------------------------
To Do: Insert Signature Here
--------------------------------------------------------
To Do: Insert Signature Here
--------------------------------------------------------
- TechnoCat
- Inner party member
- Posts: 1611
- Joined: Thu Jul 30, 2009 12:31 am
- Location: Milwaukee, WI
- Contact:
Re: My own action adventure engine
Walk animations go superfast on my computer. Are they being updated with DT?
- arquivista
- No longer with us
- Posts: 266
- Joined: Tue Jul 06, 2010 8:39 am
- Location: Insert Geolocation tag here
- Contact:
Re: My own action adventure engine
lol, I had the feeling that movement was faster than before but didn't want to check old versions to compare...TechnoCat wrote:Walk animations go superfast on my computer. Are they being updated with DT?
--------------------------------------------------------
To Do: Insert Signature Here
--------------------------------------------------------
To Do: Insert Signature Here
--------------------------------------------------------
Re: My own action adventure engine
Do you mean the speed of the animations themselves or movement speed?TechnoCat wrote:Walk animations go superfast on my computer. Are they being updated with DT?
I don't use DT directly. I regulate DT to get a set number of frames per second (http://gafferongames.com/game-physics/f ... -timestep/) where each frame is treated as a "tick". The player and NPCs move a certain number of pixels per tick, and the animations advance their frames after a set number of ticks.
I didn't know you guys were so attached to the kitties. They were only meant as placeholders, but if you insist I can in the future add them back as an easter egg.arquivista wrote:DON'T MESS WITH KITTIES! I WANT THEM BACK!
well, people anims seem nice also, but aren't kitties
There isn't any new funcionality right? Don't care, things still good. Keep us posted with good stuff!
... you killed the kitties, sniff, sniff...
As for functionality, it's just the animations and a bug fix or two that's new.
I still need to finalize how hit detection for damage will work, which will affect how I draw the attack animations. The collision circles of each actor, which is visible in the demo, is sized so that a set amount of overlap occurs between each actor (no more than a third of the actor's height). This results in empty gaps in the collision circle, so I'm going to have to use a second set of hit detection shapes that better fit each sprite. I'm also going to have to make sure that any attack animations can reach far enough to touch an actor's hit detection shape, given that the hit detection shapes will be inside an actor's collision circle. This probably also means that I'm not going to have enemies that do damage by (visible) touch. I've already spammed the TIGSource forums about this issue, actually.
- arquivista
- No longer with us
- Posts: 266
- Joined: Tue Jul 06, 2010 8:39 am
- Location: Insert Geolocation tag here
- Contact:
Re: My own action adventure engine
I have a cat. Small excerpt of a pick-up conversation:I didn't know you guys were so attached to the kitties. They were only meant as placeholders, but if you insist I can in the future add them back as an easter egg.
...
- Hi! Nice to meet you!
- So, talk me about you.
- Well, I have a cat...
- REALLY? That's super-cute! When you can show it to me?
...
Thanxs for the easter egg. So after showing my cat I will also display this game.
--------------------------------------------------------
To Do: Insert Signature Here
--------------------------------------------------------
To Do: Insert Signature Here
--------------------------------------------------------
- nevon
- Commander of the Circuloids
- Posts: 938
- Joined: Thu Feb 14, 2008 8:25 pm
- Location: Stockholm, Sweden
- Contact:
Re: My own action adventure engine
I knew getting a cat was a good idea!arquivista wrote:Small excerpt of a pick-up conversation:
...
- Hi! Nice to meet you!
- So, talk me about you.
- Well, I have a cat...
- REALLY? That's super-cute! When you can show it to me?
Who is online
Users browsing this forum: No registered users and 7 guests