Announcement

Collapse
No announcement yet.

Foolproof way of compiling CTP2?

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

  • #31
    The first thing I would do here is to recompile the according source files to vidplay.obj, to do this just delete that file in the folder that contains all the Release subfolder. And then just start the compiler again, it should just compile the according files.

    -Martin
    Civ2 military advisor: "No complaints, Sir!"

    Comment


    • #32
      I am using Visual C++ 6.0 .... could it be because I need the .NET compiler???

      I found something about this error in the DirectMedia SDK Help files, and they say that I must do millions of changes in my project´s settings in order to fix this. I did and it introduced so many errors that I had to simply install the all pack again =(

      I am trying to compile the Release version .... should I be compiling another version?

      Are you all able to compile Source Code download + latest all pack???

      The error persists. I´m thinking seriously about comenting this code out, or downloading other all pack because this one gives some error messages in the install.

      -

      Felipe

      Comment


      • #33
        Originally posted by sekel
        I am using Visual C++ 6.0 .... could it be because I need the .NET compiler???


        It should work with either.

        Can you describe what include and library directories you have set in the msdev options?

        I am trying to compile the Release version .... should I be compiling another version?


        Debug and Final are the ones I usually compile.

        The error persists. I´m thinking seriously about comenting this code out, or downloading other all pack because this one gives some error messages in the install.


        What do you mean by "error messages in the install" - which install?

        Comment


        • #34
          Originally posted by J Bytheway Can you describe what include and library directories you have set in the msdev options?
          C:\JOGOS\CTP2\CTP2_CODE\LIBS\DXMEDIA\LIB
          C:\JOGOS\CTP2\CTP2_CODE\LIBS\DXMEDIA\INCLUDE
          C:\JOGOS\CTP2\CTP2_CODE\LIBS
          C:\ARQUIVOS DE PROGRAMAS\MICROSOFT VISUAL STUDIO\DXMEDIA\CLASSES\BASE
          C:\ARQUIVOS DE PROGRAMAS\MICROSOFT VISUAL STUDIO\DXMEDIA\INCLUDE
          C:\JOGOS\CALL TO POWER\CTP2_CODE\INCLUDE
          C:\JOGOS\CALL TO POWER\CTP2_CODE\LIB
          C:\JOGOS\CTP2\CTP2_CODE\LIBS\DXMEDIA\CLASSES\BASE
          C:\JOGOS\CTP2\CTP2_CODE\LIBS\DIRECTX\LIB
          C:\JOGOS\CTP2\CTP2_CODE\LIBS\DIRECTX\INCLUDE
          C:\Arquivos de programas\Microsoft Visual Studio\VC98\INCLUDE
          C:\Arquivos de programas\Microsoft Visual Studio\VC98\MFC\INCLUDE
          C:\Arquivos de programas\Microsoft Visual Studio\VC98\ATL\INCLUDE

          in this order. Just noted a mistake ... the correct directory is CTP2 not Call to power. I corrected that, but the error persists.

          I copyed all DirectX and DirectMedia files to ...CTP2_CODE\LIBS\... in the apropriate directory

          What do you mean by "error messages in the install" - which install?
          Installing 2004.12.27.CTP2.ALL.zip

          The error is in the unzip process, and the program creates this log:

          .........

          Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\civs tatus.ldl OK
          Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\city status.ldl Erro: Erro na abertura do arquivo
          Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\city status.ldl OK
          Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\dipw izard.ldl OK
          Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\ns_s trings.ldl Erro: Erro na abertura do arquivo
          Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\ns_s trings.ldl OK
          Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\scen arioeditor.ldl OK
          Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\spne wgamepopups.ldl OK
          Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\km_s creen.ldl Erro: Erro na abertura do arquivo
          Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\km_s creen.ldl OK
          .................................

          Comment


          • #35
            Originally posted by sekel
            C:\JOGOS\CTP2\CTP2_CODE\LIBS\DXMEDIA\LIB
            C:\JOGOS\CTP2\CTP2_CODE\LIBS\DXMEDIA\INCLUDE
            C:\JOGOS\CTP2\CTP2_CODE\LIBS
            C:\ARQUIVOS DE PROGRAMAS\MICROSOFT VISUAL STUDIO\DXMEDIA\CLASSES\BASE
            C:\ARQUIVOS DE PROGRAMAS\MICROSOFT VISUAL STUDIO\DXMEDIA\INCLUDE
            C:\JOGOS\CALL TO POWER\CTP2_CODE\INCLUDE
            C:\JOGOS\CALL TO POWER\CTP2_CODE\LIB
            C:\JOGOS\CTP2\CTP2_CODE\LIBS\DXMEDIA\CLASSES\BASE
            C:\JOGOS\CTP2\CTP2_CODE\LIBS\DIRECTX\LIB
            C:\JOGOS\CTP2\CTP2_CODE\LIBS\DIRECTX\INCLUDE
            C:\Arquivos de programas\Microsoft Visual Studio\VC98\INCLUDE
            C:\Arquivos de programas\Microsoft Visual Studio\VC98\MFC\INCLUDE
            C:\Arquivos de programas\Microsoft Visual Studio\VC98\ATL\INCLUDE

            in this order. Just noted a mistake ... the correct directory is CTP2 not Call to power. I corrected that, but the error persists.
            There are seperate lists of include and library directories. Do you have all of these in just one of those lists?

            The error is in the unzip process, and the program creates this log:

            .........

            Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\civs tatus.ldl OK
            Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\city status.ldl Erro: Erro na abertura do arquivo
            Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\city status.ldl OK
            Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\dipw izard.ldl OK
            Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\ns_s trings.ldl Erro: Erro na abertura do arquivo
            Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\ns_s trings.ldl OK
            Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\scen arioeditor.ldl OK
            Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\spne wgamepopups.ldl OK
            Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\km_s creen.ldl Erro: Erro na abertura do arquivo
            Extraindo arquivo: C:\Jogos\ctp2\ctp2_data\french\uidata\layouts\km_s creen.ldl OK
            .................................
            Well, I can't translate this, but it might mean a corrupted download, so it's probably worth downloading again. None of the files mentioned here are important to the compilation, but I guess there may be other problems too.

            Comment


            • #36
              Originally posted by J Bytheway
              Well, I can't translate this, but it might mean a corrupted download, so it's probably worth downloading again. None of the files mentioned here are important to the compilation, but I guess there may be other problems too.
              Robot translation is your friend John, well the outcome might suck but better than nothing.

              OK, http://ets.freetranslation.com/ says it is:

              Error: Error in the opening of the file

              I guess that should be: Error: Cannot open file

              Or something like this.

              Well if there are just problems with these files mentioned here then there shouldn't be any problem if you don't use the French version. If you use the French version then you shouldn't have any problems with compiling.

              The other thing are these many include directories actual you should only need those starting with C:\Arquivos de programas\, the other shouldn't be necessary with ctplinuxfan's update. The other thing I wonder is that the DirectX stuff is found in the program files folder my are on C:\ and I can't remeber that I was asked to install them elsewhere. Maybe a DirectX 9 issure.

              -Martin
              Civ2 military advisor: "No complaints, Sir!"

              Comment


              • #37
                Originally posted by J Bytheway There are seperate lists of include and library directories. Do you have all of these in just one of those lists?
                Well ..... I did not know that! Those were all in the include directory list you just found the problem!!!

                See, in Delphi we don´t have lib files, we have .dcp and .bpl packages ... similar, but not the same.


                Thanks a lot people ^^

                The new build:

                --------------------Configuration: ctp2 - Win32 Debug--------------------
                Linking...

                CivCTP_dbg.exe - 0 error(s), 0 warning(s)

                Comment


                • #38
                  Does anyone what to do to show the AI tasks (NO_PATH, CHOKEPOINT, etc) for each unit? I think that it would be a good to add a button (perhaps on the cheat menu?) for it.

                  Comment


                  • #39
                    Martin should know but yeah thats a good idea about making it a cheat menu option...
                    Formerly known as "E" on Apolyton

                    See me at Civfanatics.com

                    Comment


                    • #40
                      Take a look on this function and you know what I did and can start to add the stuff to the cheat editor. By the way there is a lot more that could be added to the cheat editor.

                      Code:
                      GraphicsOptions::GraphicsOptions()
                      {
                      	m_armyTextOn = false;
                      	m_cellTextOn = false;
                      //	m_armyTextOn = true;
                      //	m_cellTextOn = true;
                      
                      	m_cellAVL = new AvlTree;
                      }
                      -Martin
                      Civ2 military advisor: "No complaints, Sir!"

                      Comment


                      • #41
                        Thanks!

                        Also, how do we work with Windows or Forms in VS 6???

                        I´ve being looking for this simple question in newsgroups, but I don´t seam to find an answer.

                        How can I create / edit forms in VS??? Where are ctp2 forms? Are they coded or designed in a editor??? (god, it will be hell if they are coded).

                        thanks again,

                        Felipe

                        Comment


                        • #42
                          Forms? You mean the stuff that comes with the .NET environment. That has all the easy edit stuff for C# but not for managed C++. And cannot be used for unmanaged C++. There you have to use the less programmer friendly MFC. However CTP2 doesn't use anything of these MS UI components. There is a whole subfolder for the UI components. You may start with the Scenario Editor, there you find examples how the stuff is used, adding a button shouldn't be a big deal. And for the fine adjustment you use the *ldl files.

                          -Martin
                          Civ2 military advisor: "No complaints, Sir!"

                          Comment


                          • #43
                            Originally posted by Martin Gühmann
                            Forms? You mean the stuff that comes with the .NET environment. That has all the easy edit stuff for C# but not for managed C++. And cannot be used for unmanaged C++. There you have to use the less programmer friendly MFC. However CTP2 doesn't use anything of these MS UI components. There is a whole subfolder for the UI components. You may start with the Scenario Editor, there you find examples how the stuff is used, adding a button shouldn't be a big deal. And for the fine adjustment you use the *ldl files.
                            I have never used .NET, but I belieave this is what I was talking about. That is what I was afraid of: a non RAD approach to Windows =( Incredible that MS has just added RAD Windows to c that comes with Delphi since Delphi 1 for Windows 3.11!!! This was also present in ms vb.

                            Just to be sure: Those ldl files are to be edited with notepad, right? Some kind soul may have built an editor...

                            What does MFC stand for?

                            Just found the heart of ctp2:

                            while (PeekMessage(&msg, gHwnd, 0, 0, PM_REMOVE) && !g_letUIProcess) {
                            if (msg.message == WM_QUIT)gDone = TRUE;
                            TranslateMessage(&msg);
                            DispatchMessage(&msg);
                            }

                            is civ3_main.cpp

                            Also, I noticed many files with civ3 in the name .... perhaps something left from the atemp to make ctp1 look like a civ 3.

                            Felipe

                            Comment


                            • #44
                              Originally posted by sekel
                              Just to be sure: Those ldl files are to be edited with notepad, right? Some kind soul may have built an editor...
                              Well, it might be better to use a more sophisticated text editor than notepad, but noone has created a GUI for editing them, if that is what you were asking.

                              What does MFC stand for?
                              Microsoft Foundation Classes.

                              Also, I noticed many files with civ3 in the name .... perhaps something left from the atemp to make ctp1 look like a civ 3.
                              I think it's unsurprising that the programmers chose these names when writing the game, but I'm fairly sure that there was never any plan to actually name the game itself Civ 3.

                              Comment


                              • #45
                                Originally posted by sekel
                                I have never used .NET, but I belieave this is what I was talking about. That is what I was afraid of: a non RAD approach to Windows =( Incredible that MS has just added RAD Windows to c that comes with Delphi since Delphi 1 for Windows 3.11!!! This was also present in ms vb.
                                Well it isn't so bad you have something like this for MFC, but the stuff for managed C++ is limited in comparision to C#, at least they claimed as I read this last time. But for MFC you have to connect this generated UI with your code in a not so simple way, so that it is an advance they have for C#. But actual we don't talk about Microsoft and their windows solutions, we talk rather about Activision's solution for CTP2. Actual I don't know much games that use the windows standart design. And all these games are older ones like Sim City 2000 and Sim Tower. Probably all the game manufacters create their own UI classes. And of course they don't create editors for them. And actually why so afraid of it. All you want to do is to add two tiny buttons to the Scenario Editor, and this just contains editing scenarioeditor.h, scenarioeditor.cpp, scenarioeditor.ldl and ldl_str.txt of course for each language we have a version of that file for. Well at least addding a string in English would be good.

                                Originally posted by sekel
                                Just to be sure: Those ldl files are to be edited with notepad, right? Some kind soul may have built an editor...
                                I use EditPlus2 for them, but in the case of doubt Notepad works as well, but isn't so confortable as EditPlus2. Of course the editor of MS Visual Studio should work as well.

                                -Martin
                                Civ2 military advisor: "No complaints, Sir!"

                                Comment

                                Working...
                                X