Skip to content
This repository has been archived by the owner on Dec 11, 2021. It is now read-only.
/ RSDE Public archive

Commit

Permalink
Add MusicDistortEntity support
Browse files Browse the repository at this point in the history
  • Loading branch information
chrislo27 committed Apr 10, 2019
1 parent 7e5f63a commit 610e0e7
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class RSDE : Application() {
mkdirs()
}
@Suppress("MayBeConstant")
val SFX_DB_BRANCH = "master"
val SFX_DB_BRANCH = "prototype"
const val GITHUB = "https://github.com/chrislo27/RSDE"
const val RHRE_GITHUB = "https://github.com/chrislo27/RhythmHeavenRemixEditor"
val rhreSfxRoot: File = rhreRoot.resolve("sfx/$SFX_DB_BRANCH/")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package io.github.chrislo27.rhre3.sfxdb.gui.editor

import io.github.chrislo27.rhre3.sfxdb.Parser
import io.github.chrislo27.rhre3.sfxdb.adt.*
import io.github.chrislo27.rhre3.sfxdb.gui.RSDE
import io.github.chrislo27.rhre3.sfxdb.gui.editor.panes.*
import io.github.chrislo27.rhre3.sfxdb.gui.registry.GameRegistry
import io.github.chrislo27.rhre3.sfxdb.gui.scene.EditorPane
Expand Down Expand Up @@ -98,8 +99,11 @@ class Editor(val folder: File, val editorPane: EditorPane) {
is Equidistant -> EquidistantObjPane(this, struct)
is RandomCue -> RandomCueObjPane(this, struct)
is CuePointer -> null
is SubtitleEntity, is ShakeEntity, is EndRemixEntity, is TextureEntity -> null
else -> throw IllegalStateException("JsonStruct ${struct::class.java.name} is not supported for editing. Please tell the developer!")
is SubtitleEntity, is ShakeEntity, is EndRemixEntity, is TextureEntity, is PlayalongEntity, is TapeMeasure, is MusicDistortEntity -> null
else -> {
RSDE.LOGGER.warn("JsonStruct ${struct::class.java.name} is not supported for editing, implicitly returning null")
null
}
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,10 @@ object Transformers {
Parser.buildStruct(this, node, printProperties)
this to getNonSuccess(this)
}
"musicDistortEntity" -> MusicDistortEntityObject().run {
Parser.buildStruct(this, node, printProperties)
this to getNonSuccess(this)
}
else -> return@transformer Result.Failure(node, type, "Type of datamodel is not valid or not implemented")
}
if (datamodel.second.isNotEmpty())
Expand Down

0 comments on commit 610e0e7

Please sign in to comment.