Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Topics - Daniel Eakins

#1
LÖVE Setup for Adventure Game Studio is a setup launcher that I wrote as an alternative to AGS's default winsetup.exe. It is written in Lua, using the LÖVE framework.

This is its default appearance:


This launcher relies primarily on a LÖVE library, Löve Frames, written by Kenny Shields. This library features a skinning system that you can use to easily change the appearance of this default GUI even you have little knowledge of Lua:



If you do know Lua, of course, you can modify everything in the script to further customize your GUI. I tried to keep the code as organized and as easy as possible to understand. Here is an example of a different GUI with non relevant options removed and French text:


Main benefits over the default winsetup:

  • 100% customizable.
  • Many improvements possible: For example, graying out incompatible resolutions instead of letting you selecting them is possible with coding, but I haven't implemented that yet.
  • Potentially cross-platform: Since this script is written using LÖVE (i.e. Lua), it should in theory work on Mac OS X and Linux. That said, I can only test it on Windows.
  • Easy to use for the player: The final launcher is a simple EXE file. The player doesn't need to install an interpreter or anything like that.

Minor drawbacks:

  • May not detect some translation files: There is no way in native Lua to automatically list the full content of a directory to detect the .tra files. However, the existence of specific file names can be checked, so I have pre-defined a list of over one hundred language names for the script to check. As long as the name of your translation file matches the English name of one of those one hundred languages, it will be detected. If it isn't, simply add its name to the script.
  • When actually launching the game, a terminal black window will flash up on the screen for a fraction of a second before disappearing. This is the only way to launch a program from a Lua script in Windows.

How to edit as a developer:

  • Download my LÖVE Setup script and decompress it in an individual folder.
  • Download the official LÖVE 0.9 client and decompress it in another folder.
    • Make sure it's the 32-bit version, even if you have a 64-bit Windows.
  • In a text editor, edit the script files however you want (the LÖVE wiki is helpful).
    • In main.lua, make sure you replace "Demo Game" with the name of your game executable (without the ".exe" part).
    • Also in main.lua, replace the default values in the acsetup_template string with your game's default settings (monkey_05_06's list will help).
    • In conf.lua, you can define an icon for the future launcher.
  • To launch the script for testing purposes, drag the script folder onto love.exe (or a file shortcut of it).

How to turn the script folder into an executable:

  • Compress LoveFrames, conf.lua and main.lua into a zip archive named SomeGame.love (where "SomeGame" is the name of your future launcher).
  • Put SomeGame.love and create_gamesetup_exe.bat in the same folder as the love.exe client.
  • Drag SomeGame.love onto create_gamesetup_exe.bat.
    • You now have a working EXE file, but it still requires all eight DLL files of the LÖVE client to run. You can either distribute all that with your game... or use a wrapper program to merge the setup executable and the DLL files into a single EXE file. Enigma Virtual Box (freeware) will do the job fine.

Download link:

LÖVE Setup v0.1 BETA

Have fun! (I hope := )
#2
This module allows you to have characters follow the player character from behind, walking exactly in the player character's footsteps and changing rooms with them, forming a 'caterpillar' system. It is basically a smoother version of Bernie's FolEx old module (see http://www.adventuregamestudio.co.uk/yabb/index.php?topic=25121.0 ).

It was primarily designed for RPGs using keyboard controls (in particular, the KeyboardMovement module by Rui "Brisby" Pires & strazer). It currently does not work well with mouse controls because the KeyboardMovement is strictly 8-directional whereas mouse movement is, well, 360-directional.

Note that if your player character has MovementLinkedToAnimation = true, the characters who follow him must also have that parameter true and the same AnimationSpeed as him. If he has MovementLinkedToAnimation = false, the characters who follow him can have different AnimationSpeed values. In both cases, the characters's WalkSpeeds will be aligned with that of the player (including if you have implemented a custom "running" feature for your player's movement).

This is my first module ever, so sorry if there are bugs or if the code is awkward. Suggestions/comments are of course welcome.


Functions:

  Disable();
    Disables caterpillar movement.

  Enable();
    Enables caterpillar movement. By default, the module is automatically enabled at game start.

  Status();
    Returns whether caterpillar movement is currently enabled.

  Set(int spot, Character* name);
    Adds a character to the specified spot in the caterpillar (spot 0 is the first character that follows the player's character, spot 1 is the second, etc.). Note that adding a character makes them become non-solid.

    To remove a character from a spot, just set name to null. The character's original solid property will be restored.

  Get(int spot);
    Returns the ID number of the character in the specified spot.


Version history:

  v0.1 (November 21, 2011)  First release by Daniel Eakins


License:

  This module is released into the public domain.


Download
SMF spam blocked by CleanTalk