El Foro

[Script] Wizard 101

Autor Respuestas
jhersey Wednesday 29 January 2014 at 23:26

Description (From MMORPG.com): Wizard101 is a free-to-play fantasy MMORPG from KingsIsle Entertainment that allows players to take the role of students at a school for wizards. Players create a character and then enter one of seven magical schools, learning the ropes and some new skills, then plunging into the magical, sometimes humorous storyline.

Anything done outside of wine: When downloading the file from the internet, I used the mv command to rename it to an .exe file. Sometimes it will get a feature transfer error if you do not do this.

Extra Notes: See anything done outside of Wine above.

[code language=playonlinux]
# Date : (2014-01-29 17-22)
# Wine version used : 1.7.11 x86
# Distribution used to test : Ubuntu 13.10 x86_64
# PlayOnLinux : 4.2.1
# Author : Joseph Hersey

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

TITLE="Wizard 101"
EDITOR="KingsIsle Entertainment, Inc."
AUTHOR="Joseph Hersey"
# Initialization
POL_GetSetupImages "http://files.playonlinux.com/resources/setups/$PREFIX/top.jpg" "http://files.playonlinux.com/resources/setups/$PREFIX/left.jpg" "$TITLE"
# Presentation
POL_SetupWindow_presentation "$TITLE" "$EDITOR" "$GAME_URL" "$AUTHOR" "$PREFIX"
# Create Prefix
POL_System_SetArch "x86" # Game crashes if installed with x86_64
POL_Wine_SelectPrefix "$PREFIX"
POL_Wine_WaitBefore "$TITLE"

# Installation - Determine if user wants to download or use a local copy.

POL_SetupWindow_InstallMethod "LOCAL,DOWNLOAD" # Choose method of installation
     POL_SetupWindow_browse "$(eval_gettext 'Please select the setup file to run')" "$TITLE" # Browse for File
     POL_Wine_WaitBefore "$TITLE"
     POL_Wine start /unix "$APP_ANSWER" # Install Application
     POL_Wine_WaitExit "$TITLE"
     POL_System_TmpCreate "$PREFIX" # Create temp folder
     cd "$POL_System_TmpDir"
     POL_Download "https://www.wizard101.com/downloadGame/OtherDownload" # Download the installer
     mv OtherDownload InstallWizard101.exe # Sometimes you get a feature transfer error if you do not rename this file to an .exe

     POL_Wine_WaitBefore "$TITLE"
     POL_Wine start /unix "InstallWizard101.exe" # Install Application
     POL_Wine_WaitExit "$TITLE"
     POL_System_TmpDelete # Delete Temp Directory
# Create Shortcuts
POL_Shortcut "Wizard101.exe" "$TITLE" "" "" "Game;RolePlaying;"
exit 0


Left Image



Editado por: jhersey

petch Sunday 2 February 2014 at 15:30

Your script looks nice, no problem with renaming the installer after download, it's actually done by several scripts already.

POL_System_SetArch "x86" # Game crashes if installed with x86_64

That's the default so you can omit it. Doesn't hurt though.

POL_Wine_SelectPrefix "$PREFIX"
POL_Wine_WaitBefore "$TITLE"

I don't understand why you used WaitBefore here, shouldn't be necessary

     POL_Wine_WaitBefore "$TITLE"
     POL_Wine start /unix "$APP_ANSWER" # Install Application
     POL_Wine_WaitExit "$TITLE"

"start /unix" is usually not necessary, and it has side effects (cancelling the installation does not immediately kill the windows installer), so it's better to remove it if possible.
POL_Wine_WaitBefore and POL_Wine_WaitExit should never be necessary simultaneously. If you remove start /unix, the WaitBefore statement should be sufficient.

About the images:

Images for the installer should be 150x356 px (for left) and 64x64 (for top).
Image for list is 22x22 px indeed, image for shortcut can be anything from 32x32 to 256x256 (48x48 is the most common, but PoL should be able to use anything square). The latter is mainly for future uses (creating larger list icons in the future?) as POL_Shortcut, as you used it, will take the icon directly from the executable.
Screenshots should be full size, the web server will take care of creating thumbnail versions

So, beside maybe this strange WaitBefore between SelectPrefix and PrefixCreate, your script looks ok for validation.

petch Thursday 6 February 2014 at 19:39

Script validated, but without the gfx resources that do not have the required dimensions.

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 dmca-notice@playonlinux.com