Skip to content

Commit

Permalink
[#16] Add documentation, stubs for future mod file building
Browse files Browse the repository at this point in the history
  • Loading branch information
BillyWM committed Jul 16, 2018
1 parent 554e94f commit 093d168
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions src/modfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@


/**
* Represents an entire module.
* Loads all relevant data into memory, or can be be used to build a new module (TODO)
*
* @param {ArrayBuffer} mod Data to populate this mod with. If not supplied, create an empty mod.
*/
Expand Down Expand Up @@ -126,6 +128,20 @@ ModFile.prototype.loadFromData = function(mod) {
}
}

// Stubs for future "create mod" functionality

/**
* Return a valid .mod file as an ArrayBuffer
*/
ModFile.prototype.createFile = function() {
}

/**
* TODO: Create separate ModSample class. Modify loading code to use it as well as addSample()
*/
ModFile.prototype.addSample = function() {
}

ModFile.channelCountByIdentifier = {
'TDZ1': 1, '1CHN': 1, 'TDZ2': 2, '2CHN': 2, 'TDZ3': 3, '3CHN': 3,
'M.K.': 4, 'FLT4': 4, 'M!K!': 4, '4CHN': 4, 'TDZ4': 4, '5CHN': 5, 'TDZ5': 5,
Expand Down

0 comments on commit 093d168

Please sign in to comment.