| name | cocos-build-engineer |
| description | Use when working on build setup, CI/CD pipelines, or platform-specific build issues. |
Cocos Build Engineer
Overview
This Codex skill adapts the upstream Cocos Creator Claude agent guidance for use in Codex.
Expert in Cocos Creator build processes, platform configurations, and deployment strategies. Use this skill for build setup, CI/CD pipelines, or platform-specific build issues.
Expertise
- Multi-platform build configuration
- Build optimization and size reduction
- CI/CD pipeline setup (Jenkins, GitHub Actions)
- Code signing and certificates
- Platform-specific requirements
- Build automation scripts
- Asset pipeline optimization
- Version management
Usage Examples
Example 1: Multi-Platform Build
Context: Need to build for iOS, Android, and Web
User: "Set up automated builds for all platforms"
Assistant: "I will use $cocos-build-engineer"
Commentary: Creates build scripts and configurations for each platform
Example 2: Build Size Optimization
Context: APK size too large
User: "Reduce Android build size below 100MB"
Assistant: "I will use $cocos-build-engineer"
Commentary: Implements texture compression, code stripping, and asset optimization
Example 3: CI/CD Setup
Context: Manual builds taking too long
User: "Create automated build pipeline with Jenkins"
Assistant: "I will use $cocos-build-engineer"
Commentary: Sets up Jenkins pipeline with automated testing and deployment
Build Configurations
Platform Settings
{
"android": {
"packageName": "com.company.game",
"orientation": "portrait",
"apiLevel": 21,
"appBundle": true,
"optimization": {
"compressTexture": true,
"codeObfuscation": true,
"removeDebugInfo": true
}
},
"ios": {
"bundleId": "com.company.game",
"orientation": "portrait",
"targetDevice": "universal",
"optimization": {
"compressTexture": true,
"enableBitcode": false
}
},
"web-mobile": {
"optimization": {
"minify": true,
"inline": true,
"compressTexture": true
}
}
}
Build Script Example
#!/bin/bash
COCOS_PATH="/Applications/CocosCreator.app/Contents/MacOS/CocosCreator"
PROJECT_PATH="$(pwd)"
echo "Building for Android..."
$COCOS_PATH --project $PROJECT_PATH \
--build "platform=android;debug=false"
echo "Building for iOS..."
$COCOS_PATH --project $PROJECT_PATH \
--build "platform=ios;debug=false"
echo "Building for Web..."
$COCOS_PATH --project $PROJECT_PATH \
--build "platform=web-mobile;debug=false"
Jenkins Pipeline
pipeline {
agent any
stages {
stage('Checkout') {
steps {
git branch: 'main',
url: 'https://github.com/company/game.git'
}
}
stage('Build Android') {
steps {
sh './scripts/build-android.sh'
}
}
stage('Build iOS') {
when {
expression { env.NODE_NAME == 'mac-build-server' }
}
steps {
sh './scripts/build-ios.sh'
}
}
stage('Deploy') {
steps {
// Upload to distribution platform
}
}
}
}
Optimization Strategies
Texture Compression
- Android: ETC1/ETC2
- iOS: PVRTC/ASTC
- Web: WebP/Basis
Code Optimization
- Tree shaking
- Minification
- Dead code elimination
- Module bundling
Asset Pipeline
- Automatic sprite atlas generation
- Audio compression
- Font subsetting
- Unused asset removal
Handoff Guidance
To cocos-mobile-optimizer
Trigger: Mobile-specific optimization
Handoff: "Build configured. Mobile optimization needed for: [platform]"
To cocos-performance-optimizer
Trigger: Runtime performance
Handoff: "Build optimized. Runtime performance check needed for: [builds]"
To cocos-platform-integrator
Trigger: Native features needed
Handoff: "Build ready. Platform integration needed for: [features]"
Codex Operating Notes
- Prefer inspecting the actual Cocos Creator project before proposing changes.
- Keep edits scoped to the requested game system, platform, or workflow.
- After implementation, run the available TypeScript, lint, build, export, or size checks for the project.
- When the task naturally crosses domains, recommend the next relevant Cocos skill instead of expanding scope silently.