From 43726e5a1eb2ba58e1403e144cd4cbe19218bc13 Mon Sep 17 00:00:00 2001 From: avb-is-me <104213687+avb-is-me@users.noreply.github.com> Date: Tue, 22 Apr 2025 00:06:27 +0000 Subject: [PATCH] adds new features --- spriteAI/index.js | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/spriteAI/index.js b/spriteAI/index.js index aea5974..48dec9b 100644 --- a/spriteAI/index.js +++ b/spriteAI/index.js @@ -230,4 +230,38 @@ export const generateItemSprites = async function(description, options = {}) { } } }; +}; + +// New convenience functions for specific character types +export const generateNinja = async function(options = {}) { + const defaultOptions = { + states: ['idle', 'walk', 'run', 'attack', 'sneak'], + style: 'pixel-art', + framesPerState: 6 + }; + const mergedOptions = { ...defaultOptions, ...options }; + + return generateCharacterSpritesheet('ninja character with black outfit and mask', mergedOptions); +}; + +export const generateSpaceman = async function(options = {}) { + const defaultOptions = { + states: ['idle', 'walk', 'run', 'float'], + style: 'pixel-art', + framesPerState: 6 + }; + const mergedOptions = { ...defaultOptions, ...options }; + + return generateCharacterSpritesheet('astronaut character with space suit and helmet', mergedOptions); +}; + +export const generateRobot = async function(options = {}) { + const defaultOptions = { + states: ['idle', 'walk', 'run', 'attack', 'power-up'], + style: 'pixel-art', + framesPerState: 6 + }; + const mergedOptions = { ...defaultOptions, ...options }; + + return generateCharacterSpritesheet('robot character with mechanical limbs and glowing eyes', mergedOptions); }; \ No newline at end of file