The forum

[Script] S.T.A.L.K.E.R.: Call of Pripyat

Author Replies
Xenos5 Wednesday 25 March 2015 at 20:21
Xenos5

S.T.A.L.K.E.R.: Call of Pripyat is the third instalment in the highly-acclaimed S.T.A.L.K.E.R. franchise. Following on from the events of the first game, you take he role of Major Alexander Degtyarev, whose mission is to infiltrate the zone as a stalker, in order to find out why "Operation Fairway", the large scale helicopter reconnaissance mission the military launched at the end of the first game, went so horribly wrong.

The script is fairly straightforward, and the game more-or-less just works. A DX11 dll has to be explicitly disabled to avoid a crash on start, but otherwise a default wine works. The CSMT patches give a decent 10-20% increase in fps, but on some systems exhibit what seems to be a deadlock issue, causing the game to CTD every time you save. For this reason, CSMT is not used in the script, but to anybody reading this, feel free to give it a shot; tell me how it goes.
 

#!/bin/bash
# Date : (2015-03-25T21:00Z)
# Last revision : (2015-03-25T21:00Z)
# Distribution used to test : Arch Linux
# Author : Alexander Borysov (Xenos5)
# Script licence : GPLv3
# Program licence: Proprietary

[ "$PLAYONLINUX" = "" ] && exit 0
source "$PLAYONLINUX/lib/sources"

TITLE="S.T.A.L.K.E.R.: Call of Pripyat"
PREFIX="STALKERCallOfPripyat"
WINEVERSION="1.7.39"
STEAM_APP_ID=41700

POL_GetSetupImages "http://files.playonlinux.com/resources/setups/$PREFIX/top.jpg" "http://files.playonlinux.com/resources/setups/$PREFIX/left.jpg" "$TITLE"

POL_SetupWindow_Init
POL_Debug_Init

POL_SetupWindow_presentation "$TITLE" "BitComposer Games" "http://stalker-game.com" "Alexander Borysov" "$PREFIX"

POL_Wine_SelectPrefix "$PREFIX"
POL_Wine_PrefixCreate "$WINEVERSION"

POL_SetupWindow_InstallMethod "DVD,STEAM,LOCAL"

if [ "$INSTALL_METHOD" = "DVD" ]; then
    POL_SetupWindow_cdrom
    POL_SetupWindow_check_cdrom "setup-1.bin"
    POL_Wine_WaitBefore "$TITLE"
    POL_Wine "$CDROM/setup.exe"
elif [ "$INSTALL_METHOD" = "STEAM" ]; then
   POL_Call POL_Install_steam
   cd "$WINEPREFIX/drive_c/$PROGRAMFILES/Steam"
   POL_Wine "steam.exe" "steam://install/$STEAM_APP_ID"
   POL_Wine_WaitExit "$TITLE"
elif [ "$INSTALL_METHOD" = "LOCAL" ]; then
    POL_SetupWindow_browse "$(eval_gettext "Please select the setup file to run.")" "$TITLE"
    POL_Wine_WaitBefore "$TITLE"
    POL_Wine "$APP_ANSWER"
fi

POL_SetupWindow_VMS "128"
POL_Wine_OverrideDLL "" "d3dx11_42" # avoids a crash on start

if [ "$INSTALL_METHOD" = "STEAM" ]; then
   POL_Shortcut "steam.exe" "$TITLE" "${TITLE}.png" "steam://rungameid/$STEAM_APP_ID -no-dwrite"
else
    POL_Shortcut "Stalker-COP.exe" "$TITLE" "S.T.A.L.K.E.R.: Call of Pripyat.png"
fi

POL_SetupWindow_Close
exit

Screenshots:

22x22:

48x48:

top:

left:

 

Edited by Xenos5

Ronin DUSETTE Wednesday 25 March 2015 at 20:42
Ronin DUSETTE

Fantastic images and screenshots. Seriously. :)


Please:
Post debug logs & full computer specs in first post
No private messages for general help, use the forums
Read the wiki, Report broken scripts
Xenos5 Wednesday 25 March 2015 at 21:07
Xenos5

Yeah, I hope you appreciate them. Almost died to a bloodsucker and some pseudodogs while getting those. ;)

Ronin DUSETTE Wednesday 25 March 2015 at 22:05
Ronin DUSETTE

Ha. Nice. :D


Please:
Post debug logs & full computer specs in first post
No private messages for general help, use the forums
Read the wiki, Report broken scripts
Ronin DUSETTE Wednesday 25 March 2015 at 22:09
Ronin DUSETTE

As for the script, the only thing that I can see right at a glance is you should probably declare a WINEVERSION variable at the beginning of the script, that way, the version used can easily be changed without hunting through a script. Other than that, it looks fine to me. 

Edited by RoninDusette


Please:
Post debug logs & full computer specs in first post
No private messages for general help, use the forums
Read the wiki, Report broken scripts
Xenos5 Wednesday 25 March 2015 at 22:25
Xenos5

Post edited, and script submitted. The New Installer form didn't seem to give me options for adding the screenshots or the actual script code, so I inadvertently submitted an empty app. I added the script contents as a contribution, but can't seem to add the screenshots. It would be appreciated if you could. :)

Edited by Xenos5

Xenos5 Wednesday 25 March 2015 at 22:32
Xenos5

You work fast. :)
Also, there are accepted scripts for Clear Sky and Shadow of Chernobyl, but they're old, don't follow modern PlayOnLinux scripting standards, and use ancient wine versions. Can I create updated scripts? And if so, should I submit contributions, or just do it from scratch?

Ronin DUSETTE Thursday 26 March 2015 at 0:28
Ronin DUSETTE

 

I added the script contents as a contribution, but can't seem to add the screenshots.

Yeah. That is how the scripts are added, but only admins can upload photos like that (imagine what a troll could do with that power. lol.).

 

Also, there are accepted scripts for Clear Sky and Shadow of Chernobyl, but they're old, don't follow modern PlayOnLinux scripting standards, and use ancient wine versions. Can I create updated scripts? And if so, should I submit contributions, or just do it from scratch?

Always, if an application already has a script, contribute to the actual script page (do not create a new one). Simply fix the script (even if it requires a complete rewrite), and submit it to the original script, so that we can keep track of the commits to the code. 


Please:
Post debug logs & full computer specs in first post
No private messages for general help, use the forums
Read the wiki, Report broken scripts
Xenos5 Thursday 26 March 2015 at 4:54
Xenos5

Yeah. That is how the scripts are added, but only admins can upload photos like that (imagine what a troll could do with that power. lol.).

Hah, good point. Didn't think of that.

Always, if an application already has a script, contribute to the actual script page (do not create a new one). Simply fix the script (even if it requires a complete rewrite), and submit it to the original script, so that we can keep track of the commits to the code. 

Right, okay. In that case, are the script names changeable? It's not a huge deal, but the actual titles say "S.T.A.L.K.E.R.:", not "S.T.A.L.K.E.R. -". The latter is done only for Windows shortcuts and directories, presumably because they can't take colons.
I'll get cracking on the scripts in the meanwhile.

Ronin DUSETTE Thursday 26 March 2015 at 6:16
Ronin DUSETTE

Yes, they can be changed. Just depends on why they would need to be changed. I would just address it in the thread when you post your corrected script, and if it should be done, it can be changed. 

Edited by RoninDusette


Please:
Post debug logs & full computer specs in first post
No private messages for general help, use the forums
Read the wiki, Report broken scripts

This site allows content generated by members, and we promptly remove any content that infringes copyright according to our Terms of Service. To report copyright infringement, please send a notice to dmcayonlinux.com