Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length

 
Advanced search

879748 Posts in 33002 Topics- by 24376 Members - Latest Member: xnothegame1

May 24, 2013, 08:28:23 PM
TIGSource ForumsDeveloperFeedbackDevLogsSaturated Dreamers
Pages: 1 [2] 3 4 ... 31
Print
Author Topic: Saturated Dreamers  (Read 38890 times)
Paul Eres
Level 10
*****


Also known as RinkuHero.

RinkuHero
View Profile WWW Email
« Reply #15 on: April 27, 2009, 06:15:46 AM »

That might work, though I'm not sure it'd be any faster. I already do use some particles for the trail (those little white dots and those ripple effects). I do get slowdown to around when there are around 600 particles or more though, and on most screens the particles already are approaching that number even without the trails.
Logged

TeeGee
Level 10
*****


Huh?

tomek_grochowiak@op.pl
View Profile WWW Email
« Reply #16 on: April 27, 2009, 06:41:00 AM »

Ouch. Then again, the game's 640x480. Even with lots of stuff drawing on the screen, the fillrate shouldn't be too high. Have you checked what's the bottle neck - the graphics or the CPU?
Logged

Tom Grochowiak
MoaCubeBlog | Twitter | Facebook
Fuzz
Guest
« Reply #17 on: April 27, 2009, 04:31:58 PM »

Fuzz: There's exploration, but not exactly "shooting" -- although you certainly do shoot things at creatures, you don't do so with the intent to kill them. You have different 'functions', and each of them have different effects: a line that attaches to them to pull them around, a web that slows them down, and other various effects. It's in the design doc. And Walter Eres is my father, he's been a music composer for around 40 years so knows how to do it well by now. He also composed much of the Immortal Defense soundtrack. However, most of the music for this game is by Long Dao, who arranged and composed some of the music of Immortal Defense as well. Most of the game's music has been completed, it has about two hours of music right now, which is about four times more than Immortal Defense did.
Well, I understood that there wouldn't be shooting, but it seems like a shooter without shooting from what you've described. Or something. Also, it's really cool that you're getting your father on board with your games.
Logged
Paul Eres
Level 10
*****


Also known as RinkuHero.

RinkuHero
View Profile WWW Email
« Reply #18 on: April 27, 2009, 05:40:50 PM »

Ouch. Then again, the game's 640x480. Even with lots of stuff drawing on the screen, the fillrate shouldn't be too high. Have you checked what's the bottle neck - the graphics or the CPU?

Pretty sure it's the fill rate. But I've a fairly mediocre (not bad, just average) videocard (NVIDIA 8500 GT), and a fairly good CPU (Intel Core 2 Duo 3.0 ghz, it's even one of the newer 45nm things). On other computers it may have different bottlenecks. But it depends on the specifics of the area, they vary a lot. Sometimes it's just the large number of objects, which is more a CPU problem.

re Fuzz: It's similar to shooters in that you control a ship, and may give that shooter feeling just for that reason; I think that's the biggest similarity. It's a bit risky going for a ship as a main character in a story-based game: will people actually care about characters that they won't actually see except in the form of text box portraits? We'll see.
Logged

Paul Eres
Level 10
*****


Also known as RinkuHero.

RinkuHero
View Profile WWW Email
« Reply #19 on: April 27, 2009, 07:07:11 PM »

I tried haowan's suggestion about the triangles. Here's the result:

new triangle method:


old method:


I'm not actually sure which looks better. I think the first method is faster, but I haven't tested it enough yet, so I'm not sure. I think they both look okay/acceptable, but not spectacular. The first method has too much overlap, and the second method has too many breaks/fragmentation. Getting it to fill perfectly is something I'm not sure how to approach. I'll try TeeGee's particle method tomorrow probably.
Logged

nihilocrat
Level 10
*****


Full of stars.


View Profile WWW Email
« Reply #20 on: April 28, 2009, 11:32:23 AM »

Sounds pretty interesting, and the visuals are superb. Keeping my eye on this.
Logged

narasu
Level 10
*****


wehed milie hier, wehed milie daar


View Profile WWW Email
« Reply #21 on: April 28, 2009, 12:12:40 PM »

Looks very charming, and I like the idea of an exploration shooter. Keeping my eye on this.
Logged

Ronin Narasu - Musician, philosopher, petty thief

Website: http://www.ronin-narasu.co.nf
Soundcloud: http://soundcloud.com/ronin-narasu
Paul Eres
Level 10
*****


Also known as RinkuHero.

RinkuHero
View Profile WWW Email
« Reply #22 on: April 30, 2009, 07:21:24 PM »

Okay, I tried TeeGee's suggestion of doing these trails through GM's particle system. The particles were actually much slower than either of these two methods for equal trail lengths. That isn't too surprising because creating 100 new particles for the player and for the creatures seems like it'd be drawn slower than a strip of 100 triangles or 100 lines in a loop. I did get some interesting effects which I may adapt or use for other things, but I probably will keep using the methods mentioned instead of particles due to the speed difference.
Logged

Xion
Pixelhead
Level 10
******


xionight@live.com Chimera+Gryphon
View Profile WWW Email
« Reply #23 on: May 01, 2009, 12:27:18 AM »

you said you wanted rainbow trails...couldn't you draw each point on the triangle strip with a different hue for that effect? I don't see why rainbow trails would be too hard...?
Logged

Paul Eres
Level 10
*****


Also known as RinkuHero.

RinkuHero
View Profile WWW Email
« Reply #24 on: May 01, 2009, 03:41:25 AM »

I could try gradually shifting the hue, yes. But what I meant by rainbow was this:

red red red red red
orange orange orange
yellow yellow yellow
green green green
blue blue blue blue

rather than

red orange yellow green blue
red orange yellow green blue
red orange yellow green blue
red orange yellow green blue

i.e. *stripes* rather than just a hue shift over time.

the second would be perfectly easy. the first, not so much. i will try the second to see how it looks though.
Logged

Alex May
...is probably drunk right now.
Level 10
*


hen hao wan


View Profile WWW Email
« Reply #25 on: May 01, 2009, 03:46:20 AM »

If you can draw texture-mapped triangles, or texture-mapped rectangles in your original system, then you should be able to put a rainbow texture over the trail without too much trouble.

It's a shame about the overlap - there are probably some neat ways around it but it might slow the game down even more to implement them.
Logged

Eclipse
Level 10
*****


0xDEADC0DE


View Profile WWW Email
« Reply #26 on: May 01, 2009, 03:53:33 AM »

40 fps is the crap if the game is fast paced, aim always for 50-60 if you can D:

about that triangles overlap, maybe you can fix it using the stencil buffer
Logged

<Powergloved_Andy> I once fapped to Dora the Explorer
Paul Eres
Level 10
*****


Also known as RinkuHero.

RinkuHero
View Profile WWW Email
« Reply #27 on: May 01, 2009, 03:55:46 AM »

GM can do texture-mapped primitives, but I haven't actually used it that often. I used it a little bit in Immortal Defense for the shield effect around the first boss, but that was mainly randomly stabbing at the air and inserting random variables in the GM functions until I got a desired effect. I'll post the textured primitive description here:

Quote
Finally, it is possible to draw primitives using sprites or backgrounds as textures. When using a texture the image is placed on the primitive, reshaping it to fit the primitive. Textures are used to add detail to primitives, e.g. a brick wall. To use textures you first must obtain the id of the texture you want to use. For this the following functions exist:

sprite_get_texture(spr,subimg) Returns the id of the texture corresponding to subimage subimg of the indicated sprite.
background_get_texture(back) Returns the id of the texture corresponding to the indicated background.

A selected texture might not yet be in video memory. The system will put it there once you need it but sometimes you want to decide this yourself. For this the following two functions exist:

texture_preload(texid) Puts the texture immediately into video memory.
texture_set_priority(texid,prio) When there is too little video memory some will be removed temporarily to make room for others that are needed. The ones with lowest priority are removed first. Default, all have priority 0 but you can change the priority here. (Use positive values!)

To add textures to primitives you must specify which parts of the textures must be put where on the primitive. Positions in the texture are indicated with values between 0 and 1 but there is a problem here. Sizes of textures must be powers of 2 (so e.g. 32x32 or 64x64). If you want to use sprites or background as textures you better make sure they have such a size. If not, the test will be blank. To find out which part of the texture is actually used you can use the following two functions. They return a value between 0 and 1 that indicates the width or height of the actual part of the texture being used. Specifying this value as texture coordinate will indicate the right or bottom side of the texture.

texture_get_width(texid) Returns the width of the texture with the given id. The width lies in the range 0-1.
texture_get_height(texid) Returns the height of the texture with the given id. The height lies in the range 0-1.

To draw textured primitives you use the following functions:

draw_primitive_begin_texture(kind,texid) Start a primitive of the indicated kind with the given texture.
draw_vertex_texture(x,y,xtex,ytex) Add vertex (x,y) to the primitive with position (xtex,ytex) in the texture, blending with the color and alpha value set before. xtex and ytex should normally lie between 0 and 1 but also larger values can be used, leading to a repetition of the texture (see below).
draw_vertex_texture_color(x,y,xtex,ytex,col,alpha) Add vertex (x,y) to the primitive with position (xtex,ytex) in the texture, blending with its own color and alpha value.
draw_primitive_end() End the description of the primitive. This function actually draws it.

There are three functions that influence how textures are drawn:

texture_set_interpolation(linear) Indicates whether to use linear interpolation (true) or pick the nearest pixel (false). Linear interpolation gives smoother textures but can also be a bit blurry and sometimes costs extra time. This setting also influence the drawing of sprites and background. Default is false. (This can also be changed in the global game settings.)
texture_set_blending(blend) Indicates whether to use blending with colors and alpha values. Switching this off might be faster on old hardware. This setting also influence the drawing of sprites and background. Default is true.
texture_set_repeat(repeat) Indicates whether to use repeat the texture. This works as follows. As indicated above texture coordinates lie in the range 0-1. If you specify a value larger than 1, default the rest is not drawn. By setting repeat to true the texture is repeated. Note that sprites and backgrounds are always drawn without repeating. So once you draw a sprite of background this value is reset to false. Default is false.

So as you can see, it has some capability for it, but I'm just not sure how to use all that. I doubt it's as simple as making a rainbow texture and telling it to use it, since I don't know whether to set repeat on or off, or what xtex and ytex values to use, and all that.
Logged

Paul Eres
Level 10
*****


Also known as RinkuHero.

RinkuHero
View Profile WWW Email
« Reply #28 on: May 01, 2009, 03:56:18 AM »

40 fps is the crap if the game is fast paced, aim always for 50-60 if you can D:

about that triangles overlap, maybe you can fix it using the stencil buffer

Yes, I'm aiming for 60 fps, the reason I'm not using really long trails is that it reduces it to 40 fps. I don't know what a stencil buffer is.
Logged

Paul Eres
Level 10
*****


Also known as RinkuHero.

RinkuHero
View Profile WWW Email
« Reply #29 on: May 01, 2009, 05:15:34 PM »



crazy performance test

i had the idea: since there are about 30 creatures in the game, i'll dedicate one day each this month to each of them (programming their behavior), and try to get them in the game. today was the unicorn. if i don't get a creature done during their dedicated day, i will not be able to work on them again for several months, and have to just keep what i get done on that day. that should be motivation to do a lot for each creature this month.
Logged

Pages: 1 [2] 3 4 ... 31
Print
Jump to:  

Theme orange-lt created by panic