1.4 KiB
1.4 KiB
Onboarding for WallCraft AI Contributors
Overview
- This document helps new contributors get up to speed on the WallCraft AI MVP project.
Getting started
- Prerequisites: FoundryVTT v13.0.351, node environment for building modules, access to cloud AI endpoint
- Repository layout: modules/wallcraft-ai/ with module.json and src/
- Key files to know:
- module.json: module manifest
- src/AIPrep.js: main module entry
- src/AIEndpoint.js: HTTP client for cloud AI
- src/PreviewLayer.js: canvas overlay logic
- src/SettingsPanel.js: UI to configure endpoint/token/provider
- src/UIFlow.js: dialog and adjustment UI
Development workflow
- Plan first: use agents.md to outline tasks
- Implement in small, testable increments
- Use non-destructive previews first; require explicit apply
- Write minimal tests or manual checks for payload shaping and wall conversion
Conventions
- Naming: consistent with FoundryVTT APIs (Wall, Door, Window, Scene)
- Data models: grid-aligned coordinates, tokens as bounding boxes
- Logging: messages go to chat or a dedicated journal entry
Testing and validation
- Manual test plan: create a sample scene, run AI Prep, verify preview, adjust, apply, verify persistence
- Edge cases: empty AI response, missing fields, invalid coordinates
Deployment and updates
- Document how to deploy updates to cloud endpoint if users host their own
- Provide migration notes for API changes (backward compatibility guidance)