Announcement

Collapse
No announcement yet.

the wait for civiliza d4

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #31
    i thought going from 400 mhz to about 2000 would help make the unit animations in Civ 3 more smooth... oh well, at least now on a huge map it takes 5-10 min between turns instead of 20+

    Civ 3 gave me a couple good ideas, but now i am learning many lessons of what NOT to do. for example, having every AI move every unit every single turn with pathfinding is NOT a good idea. also, i never played CTP much, but the idea of a tile-improvement system that doesn't involve hundreds of worker units running around the map sounds like a good idea.

    in Civ 3, the computer has to re-evaluate trade paths from every city to every city every turn (and sometimes multiple times per turn, when trade routes are disrupted due to roads being pillaged etc). also it has to re-evaluate whether or not each and every city is connected to the capitol. this is in addition to all the other calculations each city has to make each turn (production, science, curruption, growth, etc etc etc). needless to say, this can become overwhelming when lots and lots of cities are on the map. i am and will be facing similar problems, and i will do my best to come up with constructive ways of countering them.
    Project Leader of Civiliza, an Alternative Civilization game based on Civ 2.

    Comment


    • #32
      .

      Hi Dexter. I downloaded one of your demos, and I am much impressed. I'm both envious and hopeful at what can be done in just a few months.

      The graphics don't display quite right on my computer, but I probably don't have the latest DirectX... Is that easy to learn to program, by the way? Seeing Civiliza take control of the entire screen, rather than just maximizing, is nearly enough to make me give up on Java.

      I know you've just said that it'll be awhile before you return to coding, but I'd like to suggest anyway... It's a little hard for me to recognize at a glance what nationality a given unit is.

      I'm going to try to attach part of a screenshot from what I was working on. I was inspired by Colonization's way of marking nationality. The shot's a bit ugly, especially as a JPG. The graphics are all stolen, and the tile "blunting" looks awful to mine eye. Just look at the "shields."

      Depicted are an Imperialism fleet, Imperialism prospecter, female prospecter, the same female in swimsuit, a Japanese schoolgirl (unconventional warfare), and I think a knight or something.

      Miznia
      Attached Files
      I hate oral!!

      Comment


      • #33
        ????


        Just my 2p.
        Which is more than a 2 cents, about one cent more.
        Which shows you learn something every day.
        formerlyanon@hotmail.com

        Comment


        • #34
          Re: .

          Originally posted by Miznia
          The graphics don't display quite right on my computer, but I probably don't have the latest DirectX... Is that easy to learn to program, by the way? Seeing Civiliza take control of the entire screen, rather than just maximizing, is nearly enough to make me give up on Java.
          From what I've heard it's not too different from Java. Wasn't Java modelled after C++ afterall? I never got into Java myself though, so I can't tell you for sure. Right now I'm just working with DirectDraw, the easiest component of DirectX. When you start using Direct3D is when it gets REALLY cool, with stuff like reflections, bump mapping, and translucencies.

          I know you've just said that it'll be awhile before you return to coding, but I'd like to suggest anyway... It's a little hard for me to recognize at a glance what nationality a given unit is.

          I'm going to try to attach part of a screenshot from what I was working on. I was inspired by Colonization's way of marking nationality. The shot's a bit ugly, especially as a JPG. The graphics are all stolen, and the tile "blunting" looks awful to mine eye. Just look at the "shields."
          point taken. i agree with you, and i've begun working on an idea i have to perform a double-blit so the civ's nationality color can be used on the unit itself instead of using a "flag" or a "shield". if it doesn't work, i'll probably adapt something more similar to what you have shown. any ideas for displaying the hit points in a better way?
          Project Leader of Civiliza, an Alternative Civilization game based on Civ 2.

          Comment


          • #35
            From what I've heard it's not too different from Java. Wasn't Java modelled after C++ afterall? I never got into Java myself though, so I can't tell you for sure. Right now I'm just working with DirectDraw, the easiest component of DirectX.
            Well, I think Java is supposed to be a lot slower than C++. Not that I know first-hand, but my programs seem pretty slow. Java can't, or generally doesn't, use stuff like DirectX, I believe. What that means to me is that I can't make the monitor go *click* and draw on the entire screen.

            I was thinking, though... If I just get a later version of Java, transparency is built-in. Your program uses transparency, doesn't it? The way I have it now, it's quite slow to have to "manually" analyze what a square should look like, given the terrain type, blunting effects, unit type, and nationality. With transparency I wouldn't need to, and I wouldn't have to "blunt" anymore, either. (I realize I was a bit stupid in using blunting at all, at least for the coasts. Using separate ocean tiles to get beaches, like you do, is pretty easy, particularly if the computer decides which one is appropriate when you save the map. In your map program, don't you have to place each beach tile by hand?)

            point taken. i agree with you, and i've begun working on an idea i have to perform a double-blit so the civ's nationality color can be used on the unit itself instead of using a "flag" or a "shield". if it doesn't work, i'll probably adapt something more similar to what you have shown. any ideas for displaying the hit points in a better way?
            That would work, but I find "shields" to be pretty and straight-forward. Then again, I also prefer Civ1-style colored blocks to represent cities. As far as hit points, I'm not sure there's an elegant way to do them. The way you and Civ2 do it is as elegant as it gets, I think. I think if it were up to me (and I'm not sure I would use hit points at all, being a minimalist), I would just make the hit point indicator a small block of green, yellow, or red. You could get more specifics by clicking or something. I'm just thinking, the fewer pixels colored "healthy green," the better the display will look.

            Heh. What I would do, if I had your code, is just *swap* the nationality block and the hit point meter.

            ...I plan to get back into my programming as soon as winter break starts... I want to recreate the feel of Civ 1, but put my own stink on it.

            Miznia
            I hate oral!!

            Comment


            • #36
              Originally posted by Miznia
              transparency is built-in. Your program uses transparency, doesn't it? The way I have it now, it's quite slow to have
              there are a few different ways of handling transparency in DirectX, the easiest being a color you pick that won't be copied by the blit process. you can set colors that you don't want to copy over in the destination too (although i never use that). also, you can set a range of colors for the blit not to copy (i never use this either, it's for video editing, like when someone is in front of a blue screen and you need to cut all the blue out and replace it with a background, obviously all the blue won't be exactly one color but they will be very similar shades of blue, which is what the range is for)

              all, at least for the coasts. Using separate ocean tiles to get beaches, like you do, is pretty easy, particularly if the computer decides which one is appropriate when you save the map. In your map program, don't you have to place each beach tile by hand?)
              in the current version, you do. but having the computer place the appropriate one in like you said will be in a later release, probably when i get the map generator done, since it will NEED the ability to put in the coasts correctly.

              That would work, but I find "shields" to be pretty and straight-forward. Then again, I also prefer Civ1-style colored blocks to represent cities.
              yes, i like the easy to make out Civ1 city look, however i think it would look silly with an isometric view. the colored unit idea seems to be working out, although i haven't gotten near testing all the units yet. this demo is a pretty big stretch from the last one. the last one had like 4 units or so, and this one will have nearly all of them. anyways, i'll post a little image of a tank so you can see what it looks like

              As far as hit points, I'm not sure there's an
              elegant way to do them. The way you and Civ2 do it is as elegant as it gets, I think. I think if it were up to me (and I'm not sure I would use hit points at all, being a minimalist), I would just make the hit point indicator a small block of green, yellow, or red.
              great idea! i'll have to work with it and see what i can do, but i like what you're getting at

              You could get more specifics by clicking or something. I'm just thinking, the fewer pixels colored "healthy green," the better the display will look.
              i totally agree with you. i think the big huge green bars look ugly

              ...I plan to get back into my programming as soon as winter break starts... I want to recreate the feel of Civ 1, but put my own stink on it.
              cool. i haven't seen you around in awhile, so keep in touch here in the alt-civ forums and hopefully we can help each other out more.

              -dex
              Project Leader of Civiliza, an Alternative Civilization game based on Civ 2.

              Comment


              • #37
                almost forgot, here's the tank example:
                Attached Files
                Project Leader of Civiliza, an Alternative Civilization game based on Civ 2.

                Comment


                • #38
                  like civ3 or ctp(i think) or age of empires
                  Just my 2p.
                  Which is more than a 2 cents, about one cent more.
                  Which shows you learn something every day.
                  formerlyanon@hotmail.com

                  Comment


                  • #39
                    The tank looks pretty good, particularly if the location of the red spots is realistic. I mean, if tanks generally lack markings (I have no idea) then it might look silly.

                    I just placed an order to get my $25 student discounted copy of Microsoft Studio. Surely that will have a newer version of Java, and permit me to switch to C++ if I want at some point.

                    I've been thinking about resources. I'm trying to be simple, as always. My plan is for "production shields" to be stockpiled for all cities, like money. Military units would take shields (not sure what to call them) to be created, but rely on money to be maintained. A question is how, or whether, a city's production of a military unit is to be delayed. I'm thinking there should just be something called "labor" that has to be racked up in the city, and you'd get as much labor per turn as you have residents. Or so.

                    Have you said how you're dealing with it? If I remember right, in the demo of yours that I played, coins are racked up to build a unit. Am I right about that?

                    Miznia
                    I hate oral!!

                    Comment


                    • #40
                      there are a few different ways of handling transparency in DirectX, the easiest being a color you pick that won't be copied by the blit process. you can set colors that you don't want to copy over in the destination too (although i never use that). also, you can set a range of colors for the blit not to copy (i never use this either, it's for video editing, like when someone is in front of a blue screen and you need to cut all the blue out and replace it with a background, obviously all the blue won't be exactly one color but they will be very similar shades of blue, which is what the range is for)
                      I actually use a different method for blitting. I use two blit statements to create the image I want. I find it's a little faster to draw to the backbuffer than the transparency colour method.

                      For the first blit statement at the end use the parameter SRCPAINT, and blit a "white mask" of the image onto the back buffer.

                      For the second blit statement at the end use the parameter SRCAND, and blit the actual "image" onto the back buffer.

                      EG:
                      BitBlt(back_dc, x_pos, y_pos, Tile_wid, Tile_hgt, bmp_dc, x_mask, y_mask, SRCPAINT);
                      BitBlt(back_dc, x_pos, y_pos, Tile_wid, Tile_hgt, bmp_dc, x_bmp, y_bmp, SRCAND);

                      Use an image such as the following:
                      Attached Files

                      Comment


                      • #41
                        Originally posted by Miznia
                        The tank looks pretty good, particularly if the location of the red spots is realistic. I mean, if tanks generally lack markings (I have no idea) then it might look silly.
                        i just went through the units pretty fast updating them with the color code. i'm sure some of them will look stupid, and some will look unrealistic, but that's not what i'm going for anyways.

                        Have you said how you're dealing with it? If I remember right, in the demo of yours that I played, coins are racked up to build a unit. Am I right about that?
                        yes, that's exactly how it worked in the last demo. this next demo coming out will have a system where 10 different resources are collected, mostly from land around your city. those resources are used to build the units and the city improvements. there is also production, however, which is entirely based on the total number of people in your city minus the amount of people working on the surrounding land. all this info is clearly displayed in the city window.
                        Project Leader of Civiliza, an Alternative Civilization game based on Civ 2.

                        Comment


                        • #42
                          Originally posted by Dale
                          I actually use a different method for blitting. I use two blit statements to create the image I want. I find it's a little faster to draw to the backbuffer than the transparency colour method.
                          For the first blit statement at the end use the parameter SRCPAINT, and blit a "white mask" of the image onto the back buffer.
                          For the second blit statement at the end use the parameter SRCAND, and blit the actual "image" onto the back buffer.
                          very interesting. i never thought of doing it that way
                          Project Leader of Civiliza, an Alternative Civilization game based on Civ 2.

                          Comment


                          • #43
                            Dex:
                            I read somewhere on gamedev.net that using the transparency method actually has a tiny memory leak causing potential crashes after long times of transparency blitting. So I researched another way to do it and came across this one single paragraph in a mates DirectX book that described my method.

                            BTW, I've posted my tech tree in my game's thread. Let me know what you think.

                            Comment


                            • #44
                              Interesting

                              I actually use a different method for blitting. I use two blit statements to create the image I want. I find it's a little faster to draw to the backbuffer than the transparency colour method.
                              Interesting. I don't quite understand this, but I wonder if something like it is possible in Java, and if it would be faster.

                              this next demo coming out will have a system where 10 different resources are collected, mostly from land around your city. those resources are used to build the units and the city improvements. there is also production, however, which is entirely based on the total number of people in your city minus the amount of people working on the surrounding land. all this info is clearly displayed in the city window.
                              So, pretty similar, if I understand (you wouldn't need to transport iron to an ironless city to build something there, right?). I would like to have something like that, where laborers are pulled from the land to work on building things (reminds me of Colonization), but my plan is that most cities won't be building anything at a given point. Especially "improvements." Small, new cities won't be able to produce anything at all (defense has to be imported), and subjugated foreign cities won't be able to produce military units.

                              I was thinking, after I last posted... Resources/shields might be an unnecessary complication if I have labor (to build) and gold (to support). Hmmmmm. No resources at all?!

                              I was also thinking about the link between food production and population growth. Does Civ's method make any sense? I was thinking, that perhaps "trade" (roads, rivers, ocean) should control speed of city growth (i.e. from immigration), provided that enough food can be produced.

                              A lot of thought yet to do.
                              I hate oral!!

                              Comment


                              • #45
                                Re: Interesting

                                if your city is linked to your capitol, it can contribute resources to the stockpiles, but yes stockpiles can be used wherever. as for population, i do have some kind of population sharing system planned, so that cities will change each others populations if they are linked together by roads, harbor or airport.


                                i just got a geforce3, and so recently i've been playing games more than i've been making games. today i finally got c++ and the directx sdk installed so i can continue working on civiliza. i finished up on getting all the units into the game (still needs lots of adjusting though) and i implemented the double-blit i was talking about earlier. it looks pretty good, although i don't know what i'm going to do about the health bar thing. i took it off for now just because the game looks so much better without it. perhaps i can have the program draw it when you hold the mouse over a unit? or just a toggle for all of them?

                                oh yeah, now that fighters and bombers are in the game, i want to say how i will be handling them. it will be very similar to civ2, you move them like normal units, and they have a limited range before they run out of fuel. the only difference is that fighters now get 2 turns and will have to wait a turn after they attack or after they move. this allows you to have fighter-to-fighter combat outside the cities. this will also allow you to escort your bombers.
                                Project Leader of Civiliza, an Alternative Civilization game based on Civ 2.

                                Comment

                                Working...
                                X