sendamaphp / console
A simple CLI for creating and managing sendama-engine projects.
Requires
- php: ^8.4
- amasiye/figlet: ^1.2
- atatusoft-ltd/termutil: ^1.1
- symfony/console: ^7.0
- vlucas/phpdotenv: ^5.6
Requires (Dev)
- pestphp/pest: ^4.4
README
Sendama CLI — Console Application for the Sendama 2D Game Engine
What is it?
Sendama CLI is a console application that provides a command line interface for the Sendama 2D Game Engine. It is used to create, build, run and manage Sendama projects.
Editor Guide
For the current editor manual, see Editor.md.
For the modular guide set, see docs/guides/README.md.
Requirements
- PHP 8.3 or newer
- WSL (For Windows)
- Composer 2.7.1 or later
- Sendama 2D Game Engine
Installation
For Linux, BSD etc
To install Sendama CLI, run the following command in your terminal:
composer global require sendamaphp/console
If you haven't already, add Composer's system-wide vendor bin directory to your $PATH. This directory is at ~/.composer/vendor/bin or ~/.config/composer/vendor/bin.
export PATH="$PATH:$HOME/.composer/vendor/bin"
Alternatively, you can link the sendama executable to a directory that is already in your $PATH. For example, you can link it to /usr/local/bin:
sudo ln -s ~/.composer/vendor/bin/sendama /usr/local/bin/sendama
or
sudo ln -s ~/.config/composer/vendor/bin/sendama /usr/local/bin/sendama
Then, you can run the sendama command in your terminal.
sendama --help
For Windows
From the WSL terminal follow Linux instructions
OSX
From the OSX terminal follow Linux instructions
Usage
sendama [command] [options] [arguments]
Options
--helpor-hdisplays help for the command--quietor-qsuppresses output--verboseor-v|vv|vvvincreases output verbosity--versionor-Vdisplays the application version--ansior-aforces ANSI output--no-ansior-Adisables ANSI output--no-interactionor-ndisables interaction
Available Commands
Completion
Dump shell completion code for the specified shell (bash, fish, zsh, or PowerShell).
sendama completion
Help
Displays help for a command
sendama help
List
Lists commands
sendama list
Create a new project
Create a new Sendama project
sendama new:game mygame
or
sendama new mygame
Arguments
nameis the name of the projectdirectoryis the path to the project directory
Generate a new scene
sendama generate:scene myscene
Generate a new prefab
sendama generate:prefab enemy
Generate a UI prefab
sendama generate:prefab score-label --kind=label
Generate a new texture
sendama generate:texture mytexture
Generate a new texture with a specific size
sendama generate:texture mytexture --width=32 --height=32
