Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - Kweepa

#2161
Hmm, that's kind of confusing.
Do they have the same functionality?
#2162
Quote from: GarageGothic on Mon 12/09/2005 22:42:19
I do think that it would be a wise decision to cut that scene from PQ2.
Quote
Actually it was more dramatic than the final showdown!
Well that seals it for me. I say don't cut it.
I'd like to play PQ2, not some watered down remix.
#2163
Quote from: That Guy on Mon 12/09/2005 19:28:20
Code: ags

if ((StrComp(verb, vGive) != 0) || ((StrComp(verb, vUse) == 0) && (item.IsInteractionAvailable(eModeInteract) == 1)))
{
   item.runInteraction(mode);
}

The first StrComp will return non-zero if verb != vGive, so the if statement will be true.
I think you probably meant
Code: ags

if ((StrComp(verb, vGive) == 0) || ((StrComp(verb, vUse) == 0) && (item.IsInteractionAvailable(eModeInteract) == 1)))
{
   item.runInteraction(mode);
}


God knows how many bugs strcmp has been the cause of. Starting a new C (or AGS v2.62) project, always write a StrEqual() function which returns true when two char[] strings are equal.
#2164
No, just what you see... (I did edit my post up above there).
#2165
This is a module to create and manage three dimensional rooms.
A picture is worth a thousand words:





The module includes a player movement controller (keyboard and mouse, collisions).
Full interaction with objects and characters is possible.
The zip file includes the module, plugin, and documentation.
Rooms can consist of sprites, cuboids, cylinders, spheres, pyramids and tetrahedra.

Download v1.20 (Requires AGS v2.71 or higher.)
(Now also uses a plugin for speedup!)
Mirror v1.20 (Thanks Neole & Rui)

Thanks to Jan Simon for the basis version, "AGS3D".
#2166
Advanced Technical Forum / Re: AGS 3D
Sun 11/09/2005 19:22:09
Quote from: Rui "Brisby" Pires (a Furry) on Sat 10/09/2005 22:35:01
EDIT - Funny thing, but PgDown as "move down" no longer works. Sure, I can get around to it by pressing F6 to start falling and pressing it again to stop, but I thought you might like to know.

Oops. Lost a minus sign somehow.
It's working again.
Version 1.12.

Should I move this to a new topic to "announce" it, or just leave it here?
#2167
Very interesting game!
It works on the mac too - just choose the Linux version. For english edit acsetup.cfg and add translation=english on the line after [language]. It needs a carriage return.
#2168
Awesome!
This looks like a good solution to sound management!
#2169
Advanced Technical Forum / Re: AGS 3D
Sat 10/09/2005 20:56:49
I think at this point the module is ready for release...
Gilbot, your suggestion of flat polygonal primitives attached to the faces of other primitives is interesting, but it would require a significant rework of the engine and I don't have the motivation to do it. I don't think it would massively improve the framerate - much of the slowdown (in the town square) is due to
(a) sorting the main objects (the buildings)
(b) overdraw

I'm not quite sure what to do about HoN's texture mapping additions. To use the texture mapping you need to switch off the free look up and down, and importing a texture is a painful process (cutting it up, making sure it's sequential sprites). The backdrop is an interesting addition but can mostly be replicated with draw first primitives and sprites placed out at the horizon, as shown in the latest version of the Reality Town Square.

I also increased the primitive limit to 100 (from 60), mostly to accommodate the 20 clouds.

Version 1.11 is here:
http://www.steporg.com/step/ags/games/ags3d.zip
#2170
Quote from: Pumaman on Sat 10/09/2005 13:28:13
That'd be because this was compiled with 2.71 beta 5 and the Mac runtime is currently beta 3.

It didn't work with the mac runtime anyway. RawDrawImage doesn't draw sprites that aren't the same resolution as the screen, and the mac version promotes the screen from 16 bit to 32 bit. :'(
#2171
Oh, so you don't need my edit then :=
#2172
Looks terrific!
Really looking forward to it.

(The "sidewalk" looks like it's floating a few inches above the road. And the road is a little featureless. But otherwise, perfect!)
#2173
Yes. Yes it is.

The sky texture really adds to the scene I must say.

As for your texture mapper, that's nice work. It just needs to be perspective correct. You can linearly interpolate 1/z across the wall, then to get the appropriate column, calculate z from 1/z and interpolate the column values at left and right.
In other words, start with z_left, c_left, z_right, c_right, x_left (pixels), x_right (pixels).
Then:
ooZ_left = 1.0/z_left;
ooZ_right = 1.0/z_right;
ooZ_inc = (ooZ_right - ooZ_left)/(x_right - x_left);

ooZ = ooZ_left;
loop over x (pixels)
  ooZ += ooZ_inc;
  z = 1.0/ooZ;
  c = c_left + (c_right-c_left)*((z - z_left)/(z_right - z_left));

You need to be careful when z_right == z_left.
In that case, just go linearly.

[EDIT]
Just before the main render loop
Code: ags

  if (renderWidth == 0) return;
  
  float z_left = clippedZ[0].z;
  float z_right = clippedZ[1].z;
  float ooZ_left = 1.0/z_left;
  float ooZ_right = 1.0/z_right;
  float ooZ_inc = (ooZ_right - ooZ_left)/IntToFloat(renderWidth);
  // bring in the tex coords by half a pixel
  float c_left = 0.0 + 1.0/256.0;
  float c_right = 1.0 - 1.0/256.0;
  
  float ooZ = ooZ_left;
  
  //the main rendering loop
  i = 0;
  while (i < renderWidth)
  {
    float z = 1.0/ooZ;
    ooZ += ooZ_inc;


Just before the "colToRend" calculation
Code: ags

    if (z_right != z_left)
    {
      texFraction = c_left + (c_right - c_left)*(z - z_left)/(z_right - z_left);
    }


You might need to flip left and right when behind the texture, and tweak c_left and c_right to get the right hand column of the texture map to show up all the time.
#2174
Advanced Technical Forum / Re: AGS 3D
Fri 09/09/2005 05:46:33
Well, just in case, I've limited sprite scaling to 640x480. I should probably make it a function of the original size but for now that'll probably do.
I also moved the DynamicSprite pointer outside the function.
And I fixed a couple of sorting bugs found by debugging the plugin (hurrah for debugging!) - including the one you got a screenshot of, Rui.
Version 1.10
#2175
Advanced Technical Forum / Re: AGS 3D
Thu 08/09/2005 21:10:35
Aah, I see what you mean.
I haven't investigated the cause of that second (unwanted) sorting problem.
So I can't say for sure whether it's just a bug, or whether it's inevitable given my sorting algorithm. Painter's algorithm can have circular dependencies which have to be arbitrarily broken.
Cheers!
#2176
Advanced Technical Forum / Re: AGS 3D
Thu 08/09/2005 14:46:37
Quote from: Gilbot V7000a on Thu 08/09/2005 09:43:03
Hey, I think I'm almost certain of the causes of the pauses under hi-res I mentioned earlier.

Wow, thanks for the research!
It doesn't make any noticeable difference on my machine - so I'll use your changes if it helps for low memory cases (I've got 512Mb). If you put a Display() command inside the "if (bank != 0)" test I had you'll see none of the sprites in room1 are banked, so dynamic sprites are never used. I'm surprised that just creating a pointer to a dynamic sprite is so slow.

Yeowch, I've noticed that occasionally the game can allocate 70Mb when the sprite is drawn scaled up! Turning off the sprite compression doesn't seem to make any difference.
That's nasty. I'll have to limit the sprite size.

Rui, I see that happens without changing rooms too. So I'm not quite sure what the question means.
#2177
Advanced Technical Forum / Re: AGS 3D
Thu 08/09/2005 07:31:41
Well, I cracked and wrote a plugin:
http://www.steporg.com/step/ags/games/ags3dp.zip
It doesn't draw sprites yet as I haven't worked out how to scale (or scale and rotate) them.
Nor does the text rendering seem to work, unfortunately (I think I'm calling the function wrong).
And keypresses are off too - AGSE_KEYPRESS doesn't send the keycode in 'data'?
Still, it's a little faster than the module...
#2178
Advanced Technical Forum / Re: AGS 3D
Thu 08/09/2005 00:52:33
Quote from: Rui "Brisby" Pires (a Furry) on Wed 07/09/2005 22:40:48
Little tip - I'm sure you'd get better results for the "Scid's" and "Yahtzeebrand" signs if you used a single sprite with all the letters instead of the solitary letters. 1 - there're less sprites, and 2 - currently each letter has it's own "rotation", so to speak, which lends itself to very weird effects.

No, if I use a single sprite for the sign, it would be even worse - the base and top have to be horizontal on the screen, so if the area the sign is placed on is off-level due to the viewing angle, it would look ridiculous.
#2179
Advanced Technical Forum / Re: AGS 3D
Wed 07/09/2005 06:34:22
The sorting is wrong there because I deliberately draw the graveyard wall before any of the other buildings, as an optimisation. In a game, the player will never get to that position.
Can you check the compiled folder for a log file or a txt file? Because the game shouldn't ever freeze for 2 seconds.
There's very little I can now do to speed up the sorting I'm afraid, aside from putting it all in a plugin. You could try dropping the resolution to the recommended 320x240... that should gain you back a few FPS. What framerate do you get when you switch the sorting off (F7)?
If I could decouple update and render it wouldn't matter so much that the framerate dropped to 15 or 20. That's why I started that thread about accurate timing. Doesn't look like I'll be able to do that.
#2180
Advanced Technical Forum / Re: AGS 3D
Wed 07/09/2005 04:55:56
I removed invert mouse from the hotkeys.
If you want it you have to call
Code: ags

Ags3d.SetMouseLookInvert(true);

in, for example, game_start.

Oh yes, you can walk through Scids just as you leave it. I'll have to fix that.
Of course you won't be able to walk back behind the buildings. But the slowdown when looking at the wall in the alley (along the row of buildings) needs to be addressed.

[EDIT] Slight speedup with v1.09, which allows primitives to be parented to other primitives for rendering/sorting purposes. In the demo, the doors and signs are all parented to the buildings.

[EDIT] Also, pressing F7 toggles draw sorting so you (ok, I) can see how much sorting affects the performance.
SMF spam blocked by CleanTalk