Giter VIP home page Giter VIP logo

playdate-fishing's Introduction

Playdate Fishing

FFXIV fishing controlled by a Playdate.

What?

The Playdate is a handheld game console with a crank. A friend gave me the idea to connect the crank to FFXIV fishing. Here it is.

How?

The Playdate exposes a serial connection over USB. There are two features on the serial connection we can (ab)use:

  • Anything you print in a game gets logged to the serial port
  • You can evaluate Lua bytecode with the eval command

Note the bytecode in that sentence. We can evaluate custom Lua on the fly, but compiling a new program for each command sounds miserable. However, I have too much experience with Lua bytecode, and I found this excellent GitHub gist that details splicing data into Lua bytecode to pass JSON to the game. I reimplemented that gist in C#, allowing me to have two way communication with everyone's favorite cheese slice.

Installation

This guide assumes you are a developer that is probably in the Playdate developer ecosystem but is probably not in the FFXIV developer ecosystem. You will have to build this from source - I'm not providing binaries for a project this dumb.

Requirements:

First, build and install the Playdate game (making sure you have the Playdate SDK in your path, and your Playdate is connected via USB and is unlocked):

pdc ./playdate ./com.notnite.playdatefishing.pdx
pdutil install ./com.notnite.playdatefishing.pdx

Then, build the Dalamud plugin:

dotnet build ./dalamud/PlaydateFishing

Now, open FFXIV. Go into the Experimental tab of the Dalamud settings (/xlsettings), and add the path to the built DLL to the "Dev Plugin Locations" section. Then, do the following:

  • Plug in your Playdate to your computer
  • Ensure your Playdate is unlocked on the home screen
  • Enable the Dalamud plugin, then start the Playdate game, in that exact order

Congrats - you can now rethink your life choices. It is suggested to disable the plugin before closing the game.

Controls

  • Undock the crank to use Cast
  • Dock the crank to use Quit
  • Crank to use Hook
    • If you use Patience, the speed you crank at determines whether to use Precision Hookset or Powerful Hookset

Contributing

First, don't.

Second, I work on the Playdate part in Visual Studio Code and the FFXIV part in JetBrains Rider. If you're contributing to the Lua part, consider making a .vscode/settings.json like the following, to silence some annoying errors:

{
  "Lua.workspace.library": [
    "<path to your playdate SDK>/CoreLibs",
    "playdate/annotations.lua"
  ],
  "Lua.diagnostics.globals": [
    "playdate",
    "fishing",
    "input",
    "log",
    "json"
  ],
  "Lua.runtime.special": {
    "import": "require"
  }
}

playdate-fishing's People

Contributors

notnite avatar

Stargazers

fangs avatar netop://ウエハ avatar ave avatar Víctor Baena avatar  avatar

Watchers

Wanja Sipinski avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.