A tool to convert scw files from Supercell games to Collada (dae) format

Overview

SCW Tools

This module is intended to convert .scw files from Supercell games to Collada (.dae) format.

For a better understanding of SCW file structures, look at the files in the lib/schemas directory.

Quick Start

const path = require('path');
const { SCW2DAE } = require('@ultrapowa/scw-tools');

const ROOT_DIR = 'path/to/apk/assets';
const MASTER_HASH = 'e30a1e4a93c76bea755877299ebebf535e1b3d73';
const DATA_DIR = path.join(ROOT_DIR, MASTER_HASH);
const RAW_ASSETS_DIR = path.join(DATA_DIR, 'sc3d');
const MODELS_DIR = 'path/to/collada'
const files = ['teleport_effect.scw', 'grass_town.scw', 'shelly_idle.scw', 'bo_mecha_geo.scw', 'bone_pile.scw', 'barrel1.scw', 'shelly_geo.scw', 'ruffs_geo.scw', 'character_materials.scw'];

// models only
files.forEach((filename) => {
  const name = `${path.basename(filename, '.scw')}.dae`;
  const filePath = path.join(RAW_ASSETS_DIR, 'sc3d', filename);
  const outputDir = path.join(MODELS_DIR, 'collada', name);
  SCW2DAE.convert(filePath, outputDir);
});

// shelly with texture
SCW2DAE.convert(
  path.join(RAW_ASSETS_DIR, 'sc3d/shelly_geo.scw'),
  path.join(MODELS_DIR, 'collada/shelly_geo.dae'),
  {
    diffuseTex: 'sc3d/shelly_v2_01.ktx',
    debug: true,
  },
);
You might also like...

JavaScript library for parsing Dirtywave M8 files, complete with a CLI for interacting with M8 files.

m8-js This repository contains a JavaScript library for parsing Dirtywave M8 files, as well as a CLI for interacting with M8 files. The hopes are not

Dec 17, 2022

Download all Moodle files with one click. This is a Chrome extension built to save time and effort from downloading files manually one by one!

Download all Moodle files with one click. This is a Chrome extension built to save time and effort from downloading files manually one by one!

Moodle Downloader Extension Moodle downloader extension for Chrome. The extension is tested with both the TUM moodle and the official moodle demo. Not

Nov 15, 2022

Vaultacks lets users store files off-chain on Gaia. Files are encrypted by default but also can be made public and shared

Vaultacks lets users store files off-chain on Gaia. Files are encrypted by default but also can be made public and shared

Vaultacks Vaultacks is built on the Stacks Chain. It lets users upload files to Gaia, a off-chain data storage system. Vaultacks currently uses the de

Sep 14, 2022

Obsidian plugin that allows user to create a glossary of files, an index of files or both.

Obsidian Auto Glossary Auto Glossary is an Obsidian plugin to create a glossary, an index or a glossary with an index from the files you want. Feature

Dec 30, 2022

Small (fragile) script for migrating comments from dev.to posts to Wordpress format (WXR/XML)

dev-to-wxr Small (fragile) script for migrating comments from dev.to posts to Wordpress format (WXR/XML). Useful for importing in tools like disqus. U

Jan 29, 2022

Babel-plugin-amd-checker - Module format checking plugin for Babel usable in both Node.js the web browser environments.

babel-plugin-amd-checker A Babel plugin to check the format of your modules when compiling your code using Babel. This plugin allows you to abort the

Jan 6, 2022

Simple format that serves it's one and only purpose and that's creating simple task list everywhere where you can write plain text

Simple format that serves it's one and only purpose and that's creating simple task list everywhere where you can write plain text

SWTF (Simple Worklog Task Format) Simple format that serves it's one and only purpose and that's creating simple task list everywhere where you can wr

Apr 4, 2022

TypeScript playground plugin to save on format

TypeScript Playground Plugin TypeScript Playground plugin to save on format Running this plugin Click this link to install or Open up the TypeScript P

Apr 11, 2022

A fixed-width file format toolset with streaming support and flexible options.

fixed-width A fixed-width file format toolset with streaming support and flexible options. Features Flexible: lot of options Zero dependencies: small

Jul 14, 2022
Owner
Jean-Baptiste Martin
Founder at Ava
Jean-Baptiste Martin
A command-line tool to convert Project Zomboid map data into Deep Zoom format

pzmap2dzi pzmap2dzi is a command-line tool running on Windows to convert Project Zomboid map data into Deep Zoom format. Features Supports both python

Min Xiang 14 Dec 31, 2022
An npm package for demonstration purposes using TypeScript to build for both the ECMAScript Module format (i.e. ESM or ES Module) and CommonJS Module format. It can be used in Node.js and browser applications.

An npm package for demonstration purposes using TypeScript to build for both the ECMAScript Module format (i.e. ESM or ES Module) and CommonJS Module format. It can be used in Node.js and browser applications.

Snyk Labs 57 Dec 28, 2022
javascript library to convert a list of objects to a nested json output format, depending on the names in the list

formToNestedJson javascript "library" to convert a list of objects to a nested json output format, depending on the names in the list Basic usage Give

null 2 Aug 2, 2021
Convert your Postman documentation in a github´s readme.md ready format

Postman 2 Markdown Converter For that only time you need to convert your Postman documentation in a github´s readme ready format! Features & Problems

Andres Bastias 0 Sep 18, 2022
Convert olymp.sty based TeX problem files to BOJ Stack descriptions

boj-description-converter solved-ac.github.io/boj-description-converter Convert UCPC-flavored olymp.sty based TeX problem statements to HTML, complyin

solved.ac 10 Oct 2, 2022
This CLI tool allows you to convert the encrypted Akamai 2.0 sensor data payload back to its plaintext form.

Akamai 2.0 Sensor Data Decryption Tool This CLI tool allows you to convert the encrypted Akamai 2.0 sensor data payload back to its plaintext form. Us

null 41 Jan 1, 2023
Just a tool for convert antd-react to antd-solid

Ant Design Antd for Solid-js Just a tool for convert antd-react to antd-solid todo Icon Button Typography Divider Grid Layout Space Affix Breadcrumb D

null 10 Oct 22, 2022
Piplup: decompile Playdate Pulp .pdx files back to .json project files

Piplup: decompile Playdate Pulp .pdx files back to .json project files This doesn't work yet: I still need to: convert the graphics (.pdt files) back

null 6 Mar 25, 2022
🌸 A cli can automatically generate files from Excel files.

unxlsx A cli can automatically generate files from Excel files. Why We often need to export some information from XLSX to generate our files, such as

Frozen FIsh 24 Aug 22, 2022