@shockpkg/dir-projector
Package for creating Shockwave Director projectors
Last updated 14 days ago by jrmastermodelbuilder .
MPL-2.0 · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @shockpkg/dir-projector 
SYNC missed versions from official npm registry.

dir-projector

Package for creating Shockwave Director projectors

npm node

dependencies size downloads

travis-ci

Overview

Creates Shockwave Director projectors from a projector skeleton.

Takes either a directory containing a skeleton or a shockpkg projector package file.

Can also create bundles that group the projector and resources in a directory beside a single launcher for Windows or within an application bundle for macOS.

Reading DMG projector packages is only supported on MacOS.

Currently only flat projectors are supported, not the kind that Director makes where everything is appended to the main binary in some format, and extracted to a temporary directory when run.

Usage

Projector

Windows

import {ProjectorWindows32} from '@shockpkg/dir-projector';

const projector = new ProjectorWindows('projector-windows32/application.exe');

// Optional custom icon.
projector.iconFile = 'icon.ico';

// Optional custom PE resource strings.
projector.versionStrings = {
	FileVersion: '3.1.4',
	ProductVersion: '3.1.4',
	CompanyName: 'Custom Company Name',
	FileDescription: 'Custom File Description',
	LegalCopyright: 'Custom Legal Copyright',
	ProductName: 'Custom Product Name',
	LegalTrademarks: 'Custom Legal Trademarks',
	OriginalFilename: 'CustomOriginalFilename.exe',
	InternalName: 'CustomInternalName',
	Comments: 'Custom Comments'
};

// Optional Lingo startup script.
projector.lingoFile = 'lingo.ini';

// Optional splash screen image.
projector.splashImageFile = 'splash.bmp';

// Optionally use system installed Shockwave libraries.
// projector.shockwave = true;

// Xtras included (all in this case).
projector.includeXtras = {
	'': null
};

// Optionally nest Xtras in Configuration directory.
projector.nestXtrasConfiguration = true;

// Optionally fix Shockwave 3D Xtra InstalledDisplayDrivers reading.
projector.patchShockwave3dInstalledDisplayDriversSize = true;

await projector.withFile('skeleton.zip', 'config.ini');

Mac App

import {ProjectorMacApp} from '@shockpkg/dir-projector';

const projector = new ProjectorMacApp('projector-macapp/application.app');

// Optional custom icon.
projector.iconFile = 'icon.icns';

// Optionally change main binary name.
projector.binaryName = 'application';

// Optionally base Info.plist file.
projector.infoPlistFile = 'Info.plist';

// Optionally custom PkgInfo file.
projector.pkgInfoFile = 'PkgInfo';

// Optionally update bundle name.
projector.bundleName = 'application';

// Optional Lingo startup script.
projector.lingoFile = 'lingo.ini';

// Optional splash screen image.
projector.splashImageFile = 'splash.pict';

// Optionally use system installed Shockwave libraries.
// projector.shockwave = true;

// Xtras included (all in this case).
projector.includeXtras = {
	'': null
};

// Optionally nest Xtras in Configuration directory.
// projector.nestXtrasConfiguration = true;

// Optionally nest Xtras inside the app Contents directory.
projector.nestXtrasContents = true;

// Optionally use Intel-only skeleton.
// projector.intel = true;

await projector.withFile('skeleton.dmg', 'config.ini');

Bundle

Windows

import {BundleWindows32} from '@shockpkg/dir-projector';

const bundle = new BundleWindows32('bundle-windows32/application.exe');

// Use projector property to set options.
bundle.projector.includeXtras = {
	'': null
};

await bundle.withFile('skeleton.zip', 'config.ini', async b => {
	// Add resources in callback.
	await b.copyResource('movie.dir', 'movie.dir');
});

Mac App

import {BundleMacApp} from '@shockpkg/dir-projector';

const bundle = new BundleMacApp('bundle-macapp/application.app');

// Use projector property to set options.
bundle.projector.includeXtras = {
	'': null
};

await bundle.withFile('skeleton.dmg', 'config.ini', async b => {
	// Add resources in callback.
	await b.copyResource('movie.dir', 'movie.dir');
});

Bugs

If you find a bug or have compatibility issues, please open a ticket under issues section for this repository.

License

Copyright (c) 2019-2020 JrMasterModelBuilder

Licensed under the Mozilla Public License, v. 2.0.

If this license does not work for you, feel free to contact me.

Current Tags

  • 2.1.0                                ...           latest (14 days ago)

16 Versions

  • 2.1.0                                ...           14 days ago
  • 2.0.1                                ...           21 days ago
  • 2.0.0                                ...           21 days ago
  • 1.5.2                                ...           a month ago
  • 1.5.1                                ...           2 months ago
  • 1.5.0                                ...           5 months ago
  • 1.4.2                                ...           6 months ago
  • 1.4.1                                ...           8 months ago
  • 1.4.0                                ...           9 months ago
  • 1.3.1                                ...           10 months ago
  • 1.3.0                                ...           a year ago
  • 1.2.1                                ...           a year ago
  • 1.2.0                                ...           a year ago
  • 1.1.1                                ...           a year ago
  • 1.1.0                                ...           a year ago
  • 1.0.0                                ...           a year ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 41
Last Day 0
Last Week 0
Last Month 11
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |