CSB potential update

Discuss Chaos Strikes Back for Windows and Linux, an unofficial port of Chaos Strikes Back to PC by Paul Stevens, as well as CSBuild, an associated dungeon editor.

Moderator: Zyx

Forum rules
Please read the Forum rules and policies before posting.
User avatar
Sphenx
Lo Master
Posts: 397
Joined: 9-Sep-01 09:23
Contact:

Re: CSB potential update

Post by Sphenx » 23-Aug-17 04:52

Same for XP, strange for Win 7 : I get "CSBWin has stopped working" right from the start (Debugger's stack tells it fails on NTDLL)

User avatar
Ryan
beip Master
Posts: 6
Joined: 22-Jul-17 06:27

Re: CSB potential update

Post by Ryan » 23-Aug-17 07:32

I used Visual Studio 2017 with the Windows 10 SDK to build it. It definitely won't run in XP. There's no Direct2D in XP, plus need to set Visual Studio to the XP version of the platform tools.

d2d1_1.h is the Direct2D header. Direct2D is available in Windows 7 with the platform update (it was released four years ago).

What version of Visual Studio did you try to build it with?

User avatar
cowsmanaut
Moo Master
Posts: 4342
Joined: 29-Jun-00 22:53
Location: canada

Re: CSB potential update

Post by cowsmanaut » 24-Aug-17 08:33

Just in case anyone is confused.. I haven't been doing the code. Ryan has.. I was just posting for him, because it was more convenient for him at the time.

User avatar
Sphenx
Lo Master
Posts: 397
Joined: 9-Sep-01 09:23
Contact:

Re: CSB potential update

Post by Sphenx » 24-Aug-17 22:35

Hello Ryan and welcome.
I started with the basis version for CSBWin : MSVC++6. Then tried with VS 2008 and VS 2015 but can't open the solution/project.
Then ... I am now facing again the insanely ridiculous VS 2017 installer :( Took 99% CPU and 10 minutes to reckon I need 6+ GiB to get the C++ environment. I shall try that this week-end.

User avatar
Ryan
beip Master
Posts: 6
Joined: 22-Jul-17 06:27

Re: CSB potential update

Post by Ryan » 24-Aug-17 23:33

Haha, the welcome sounds funny as I've been here for ages. After the server move Cowsmo deleted my account while trying to fix it, so my post count was reset. I also don't post much and usually just indirectly post through Cowsmo :)

Yea, the VS 2017 install isn't trivial. The 2015 and 2013 ones were monsters also, but at least now you can complain to them on Reddit and they actually listen and answer back right away! You only need the 'Desktop development with C++' component and the Windows 10 SDK. Just be glad you don't need to install 'Universal Windows Platform development' as that'll install all of the C# and .Net stuff as they haven't separated out C++ yet (they say they will by the end of the year with C++\WinRT).

At least you can download it for free! The other nice part is that with VS 2017 you can use the latest C++ features.

User avatar
Sophia
Concise and Honest
Posts: 3910
Joined: 12-Sep-02 19:50
Location: Nowhere in particular
Contact:

Re: CSB potential update

Post by Sophia » 24-Aug-17 23:47

Welcome back Ryan. :mrgreen:

(At least, back to posting directly... or whatever!)

User avatar
Sphenx
Lo Master
Posts: 397
Joined: 9-Sep-01 09:23
Contact:

Re: CSB potential update

Post by Sphenx » 25-Aug-17 05:17

After the server move Cowsmo deleted my account while trying to fix it, so my post count was reset.
Just in case anyone is confused..
Yes I have been :D :lol:

Now, as Cowsmanaut mentioned the Surface 3 (Win RT ?), I don't actually know what is the minimal requirement IDE for compiling an exe for it ?
Is VS 2017 necessary for that ? Is there a way to make the project buildable under an older version of the IDE ?
I guess that we can also adapt for making the VC++6 project to compile without Direct2D thus still able to build the legacy Win version.

User avatar
Ryan
beip Master
Posts: 6
Joined: 22-Jul-17 06:27

Re: CSB potential update

Post by Ryan » 25-Aug-17 06:19

WinRT is the API for UWP (Universal Windows Platform) apps (like the ones that are in the Windows store, and run on XBox and Windows Phone). It's totally separate from regular win32 desktop apps. It wouldn't be too difficult to make CSBWin into a UWP app, but that wasn't something I planned on doing. There are no HWNDs in UWP, or GDI. Is that what you meant?

The Direct2D changes I made are easy to revert, but then you're stuck with the slow GDI functions. The old versions of CSBWin will stay XP compatible, I thought it'd be nice to make it run nicer on Windows 7+. XP is closer in time to the original Dungeon Master release than it is to today!

User avatar
Sphenx
Lo Master
Posts: 397
Joined: 9-Sep-01 09:23
Contact:

Re: CSB potential update

Post by Sphenx » 25-Aug-17 18:12

I understand you then built a Win 10 version that can also work on Surface 3, and on older Win 7, is that right ? -- except it doesn't work on Win 7 for me; this is one reason I want to build it myself to check.

Additions are nice and I am certainly not against, quite the contrary. I would rather take the opportunity you've put code on git to leverage the different possibilities we've seen in the past : integrate into one place the modern version, the legacy version, the linux one, maybe Rasmus 3D version ... and similarly do the same for skwin (dm2), why not ?

User avatar
Ryan
beip Master
Posts: 6
Joined: 22-Jul-17 06:27

Re: CSB potential update

Post by Ryan » 25-Aug-17 18:43

Did you install all of the platform updates on your Windows 7? (https://www.microsoft.com/en-us/downloa ... x?id=36805) I can't remember if it was an automatic update but you can always just do a search to see if 'd2d1.dll' is somewhere in your windows directory. That's my first guess as to why it won't run on yours.

I think GitHub is great for making branches of code, so you can always keep the Windows 9x compatible one as a separate branch and backport any changes that work on all systems.

Another issue is what compiler it'll compile on, VC 2017 supports C++14/C++17. I've locally put in some constexpr changes that won't compile on older compilers. I don't really have a need to submit those changes, but things can be simplified a lot with the newer C++ features.

User avatar
Sphenx
Lo Master
Posts: 397
Joined: 9-Sep-01 09:23
Contact:

Re: CSB potential update

Post by Sphenx » 26-Aug-17 13:48

I've found d2d1.dll on my Win 7 system.

At least I've made some progress.
I rebuilt the solution from VS 2017 running on Win 7 (64 bit), switching back Win SDK to 10.0.15063.0 (was 8.1 by default), specifically using C++17 as you told, and also setting back predefines _MSVC_INTEL and RGB555 (or RGB655) for the x64 build. I needed all these changes to compile and build properly.
I've built x86 and x64 versions, none of them work on my Win 7 system; only the x86 one works on my Win 10 system.
I don't know yet where is the problem.

User avatar
cowsmanaut
Moo Master
Posts: 4342
Joined: 29-Jun-00 22:53
Location: canada

Re: CSB potential update

Post by cowsmanaut » 26-Aug-17 18:40

I'm using win7 home premium which has been updated within the last several months (I'm a bit behind but certainly not more than a year)
DX11 is installed and the "d2d1.dll" file is located on my drive deep within the windows folder.
I have installed games and 3D apps which may have updated other things.. (maya, zbrush, steam games.. )

Not sure if that helps.. but that's my system and it runs his last build without issue. Perhaps Ryan has some other insights..

User avatar
Ryan
beip Master
Posts: 6
Joined: 22-Jul-17 06:27

Re: CSB potential update

Post by Ryan » 26-Aug-17 21:52

Oops, I didn't notice I left the 'Windows SDK Version' at 8.1. That must have been what it defaulted to. I have three versions of Visual Studio installed, so that might have been the cause of that.

It won't run on x64, since the DM code does int->pointer conversions. It wiarch.php?ay glad youle15313
-lightgt 8.1t=oule15313
ons.?moi =Gi> class="p=ntle="Cse chlntial updat._dd without ,pmxp;sid=wfile-joinedata2 bisid=wfilr3t wiarJ155/ waSm3r"> f (,t7a4eilass="avatar">User avatar
t="58emberlilonly"lI leGi>
asc <4a 4="icon fa-imy Win 7 system.

At least I've made some progress.
I rebuilt the solution from VS 2017 running on Win 7 (64 bit), switching back Win SDK to 10.0.15063.0 (was 8.1 by default), specifically using C++17 as you told, and also setting back predefines Ldbuiltrmonly"(> lass="profs-hidden="t/dioteS"only"lI leGi>Re: CSB potential update

tpanng back predef3ar">QuotC 201m./mem5; ="ponr iv> I mad 36a1f65rash/www.micQuotC 20> cl Lookof redivI foor viewprof="cont. We'dlass="sr-ask Png Stud h ye-left fsing ng bs="sr-on en un the n> umpe">Ryast"> www.mictC 2ack predef3T> gal S It _contenemberlisceu,> rong>lnt wwww.micu=3nt>lngs? In
phpb78e0="pose tcr UWx and W -lightgt 8.1t=oule15313
ons.?moi =Gi> class="p=ntle= se chlntial updat._dd without ,pmxp;sid=wfile-joinedata2 bisid=wfilr3t w icon-lightgray icon-md" aria-hidden="true">Post 4 by Ryan ote" class="button button-icon-only"> t="58emberlilonly"lI leGi>Ryan
  • I rebuilt the solution from VS 2017 running on Win 7 (64 bit), sw8165a5f4bnMaster/zed.png" width="64" height="58" alt="User aeigecifically using C++17 as you told, and also setting back prede8-Apre="T16:053135" class="post has-=6a7a4778e0e570736a1f65a5f4b5e2f5" class="username">Ryan beip Master
    Posts:down-container dropdown-left"> 4 Contact Sphenx4
  • Re: CSB potential update

    4> » 25-Aug-17 18:12

    I understand you then built a Win 10 version that can also wor-up fa-fw icon-gray" aria-hidden="true"> Top


    User avatar
    Ryan
    beip Master
    Posts:Re: CSB potential update
    • ss="avatar-p;u.0.15063.0 (was 8.1 by default), sped, so thatte-le_"icon f te
      0:2 Sphenx » 25-Aug-17 18:12

      I understand you then built a Win 10 version that can also wor made some progress.
      I rebuilt the solution from VS 2017 running on Win 7 (64 bit), switching back Win SDK to 10.0.15063.0 (was 8.1 by default), specifically using C++17 as you told, and also setting back predefines _MSVC_INTEL and RGB555 (or RGB655) for the x64 build. I needed all these changes to compile and build properly.
      I've built x86 and x64 versions, none of them work on my Win 7 system; only the x86 one works on my Win 10 system.
      I don't know yet where is the problem.

    User avatar
    cowsmanaut
    Posts: 6
    Joined:522-Jul-17 06:27

    Re: CSB potential update

      Quote

    Quote

    4977p/strong> » 25-Aug-17no:12

    I understand href=".ia>
    <18v>
    beip Master
    Posts:6
    Joined:

    Re: CSB potential update

      ile-4977pe" class="button button-icon-only"> Quote

    Websitelass=ent">O tcrlns">iv cfk on mo> ttrong>s! id=nke th muchnwprodo smiui /te-l_e_biggrin.gifby defaul15, specific15, usin:Dpe" classVery Happy" k prIn thin oa ... xofile& e f>las? ersions ofars/gallery/Csitch .google/nin/lass/d/0B0aV40KggmR-SUUtdk11clNIN1U ?usp=sha-f1 bymode=viewprast-cell">sitch .google/nin/lass/d/0B0aV40n phpsp=sha-f1 v> te but you can always just do a search to see if 'd2d1.dll' is somewhere in your windows directory. That's my first guess as to why it won't run on yours.

    I think GitHub is great for making branches of code, so you can always keep the Windows 9x href=".ial updat._dd without ,pmxp;sid=wfile-joinedatut , c/dt>-bar bar-boid=ms to dd>

    Joined: Re: CSB potential update dd>
    Top
    Re: CSB potential update are153h it won't run on sort-s="d9">Re: CSB potential update
    6 p-f1t9">Re: CSB potential update>=-f1t ">Quote pdat._dd without pwprm uttoorong>Po CSc/dt>lass Top npe">Rysody">
    are153h it won't run on sort-s="d9">Re: CSB potential updateTop Dungeon Master r> Rys href="./clabel>Displqu: eley" circu ct buttR valucu 0paneley"e beley"e ">All /div>RtR valucu 1 <1 dayRtR valucu 7p/7 day>RtR valucu 14">2 week>RtR valucu 30 <1 amp;sRtR valucu 90 <3&siRtR valucu 180 <6&siRtR valucu 36 <1ame">Rt label>Sort bu: eley" circu ck bkttR valucu a">A <RtR valucu tpaneley"e beley"e ">only timuRtR valucu ys Subj wiRt clabel>Directdt> eley" circu cd bdttR valucu a"aneley"e beley"e ">Ascendf1 v>npe">RtR valucu ">Descendf1 v>npe">Rt pmxp;sid=wfashe "nedata2 binpso typcu cubmitsody"> Wpagine">Ryan_web52 /div>href="./c ">6 rr>O pru=io> ">sti <
    Re: CSB potential update ">6 ">6 ct ">>2 pdat._dd without , c/dt>-bar c/dt>s-jumhtton "./posti jumhbox r"tur Dunge
    Re: GitHublre CSB potential update>R"tur "sr-“Chaos Svidkes Bre nwpro class="d: ) /tron
    9>
    Quote are153h it won't run on sort-s="d9">Re: CSB potential update
    6 =6a7a4778e0e">6Ryan ote" cljumhbox cub-ast-ce pacberlisp the yp the↳ &nbs/s Links"sr-15063.0 resourc/h3-v cg1">unity cree">Ry =6a7a4778e0e">6Ryan ote" cljumhbox cub-ast-ce pacberlisp the yp the↳ &nbs/s Welg1"e =6a7a4778e0e">6 =6a7a4778e0e">6Quote jumhbox cub-ast-ce pacberlisp the pacberlisp the yp the↳ &nbs/s World Nes= =6a7a4778e0e">6Joined: 29-Jun-00 22:53 /li> jumhbox cub-ast-ce pacberlisp the pacberlisp the yp the↳ &nbs/s Film, TV, Bookofd: =6a7a4778e0e">6Joined: 29-Jun-00 22:53 /li> jumhbox cub-ast-ce pacberlisp the pacberlisp the yp the↳ &nbs/s Scier-ond: =6a7a4778e0e">6Joined: 29-Jun-00 22:53 /li> jumhbox cub-ast-ce pacberlisp the pacberlisp the yp the↳ &nbs/s Gamns">d: =6a7a4778e0e">6 6397
    pacberlisp the yp the↳ &nbs/s F6aum suer"se">Rya/ maef="nance =6a7a4778e0e">6397
    =6a7a4778e0e">6397
    pacberlisp the yp the↳ &nbs/s uote-leork on (DM) =6a7a4778e0e">6 pacberlisp the yp the↳ &nbs/s Chaos Svidkes Bre n("> ) =6a7a4778e0e">6 6ss="avatar-fa-chevjumhbox cub-ast-ce pacberlisp the yp the↳ &nbs/s ampron's Que f>(TQ)>d: =6a7a4778e0e">6 unity Cree">Ry =6a7a4778e0e">6Joined: 29-Jun-00 22:53
    /li> jumhbox cub-ast-ce pacberlisp the yp the↳ &nbs/s Cf65a5 uote-le= =6a7a4778e0e">6Quote jumhbox cub-ast-ce pacberlisp the pacberlisp the yp the↳ &nbs/s Links"-v cQue f">Ryad: =6a7a4778e0e">6ss="avatar-fa-chevjumhbox cub-ast-ce pacberlisp the pacberlisp the yp the↳ &nbs/s uSB =6a7a4778e0e">6