Das Forum

[Script] Driftmoon

Autor Antworten
hmdai Sunday 25 November 2012 at 8:39

Driftmoon is an indie RPG written by Instant Kingdom. It use an interesting "completely" top-down camera. Check the screenshot you will know what I mean :)

The script will download or install the demo into your system. If you are satisfied with the game, you could purchase through the game or their website. They will send a license code to your email and you can use it to unlock the game. The current game version is 0.903 and it will automatically install the update once it is available (Internet is required for this feature).

EDIT: 2012-11-25 Add link to icon and left image
EDIT: Thank you for the opinion of petch. I have updated the script a bit.

I have uploaded the icon and left image here:
icon: http://www.mediafire.com/view/?ydep9n6mlknmcy6
left image: http://www.mediafire.com/view/?bkx57xhxihgxzaf

# Date : (2012-11-24 21:30)
# Last revision : (2012-11-24 21:30)
# Wine version used : 1.5.5
# Distribution used to test : OpenSuSE 12.2 64-bit
# Author : hmdai (Based on Deponia DC script by Kweepeer and PDF-XChange Viewer by Fredo)
# Script licence : GPL v.2
# Program licence : Retail
# Depend :

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



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

#POL_SetupWindow_SetID 12345 ##TODO

POL_SetupWindow_presentation "$TITLE" "Instant Kingdom" "http://www.instantkingdom.com/driftmoon/" "hmdai" "$PREFIX"

POL_Wine_SelectPrefix "$PREFIX"

Set_OS winxp

POL_SetupWindow_VMS "128"
POL_SetupWindow_InstallMethod "LOCAL,DOWNLOAD"

   POL_System_TmpCreate "$TITLE"
   cd "$POL_System_TmpDir"
   POL_Download "http://www.instantkingdom.com/download/driftmoon.exe"
    POL_SetupWindow_browse "$(eval_gettext "Please select the setup file to run.")" "$TITLE"

# Installation in progress
POL_SetupWindow_WaitBefore "$TITLE"
POL_Debug_Message "Installing $TITLE from $INSTALLER."

# Doesn't hurt ;)

POL_Shortcut "Driftmoon.exe" "$SHORTCUT_NAME" "" ""

# Clean up



Editiert von: hmdai

petch Sunday 25 November 2012 at 9:05

- Bash uses = not == for string equality test. It's usually harmless to consider the right string as a pattern (makes no difference if it doesn't contain any pattern like ? or * characters, etc.), but just to let you know
- start /unix is probably useless and should be dropped (it's major side-effect: if the install script is aborted, say the user clicks on abort button or closes the install window, with start /unix it won't also stop the installation program)
- The POL_Wine_WaitExit should be redundant. Or maybe you found it required in your script because of another bad side-effect of start /unix: it can make the installation program continue in background. If you remove start /unix you'll probably notice that POL_Wine "$INSTALLER" is blocking (script will only continue when the installer is done), and the POL_SetupWindow_WaitExit unnecessary. Not always the case, but good default guess :)
hmdai Sunday 25 November 2012 at 9:47

I used to right script for sh which requires == for string validation. Old habit never dies :-P

Thank you for your opinion. I have updated the script.
petch Sunday 25 November 2012 at 10:42

Plain sh uses ==? Didn't know that, interesting.

The left gfx is a bit too short this time (326 pixels instead of 356).
Other than that your script looks good to go :)

Editiert von: petch

hmdai Sunday 25 November 2012 at 10:48

Ah, my bad. I have mixed up the resolution of the image and create a wrong size. I have uploaded a correct one and updated the link.