Switch Kotlin version to 1.0.0

This commit is contained in:
octarine-noise
2016-02-21 10:37:37 +01:00
parent 41b080646a
commit 7393fed5fd
9 changed files with 10 additions and 10 deletions

View File

@@ -91,7 +91,7 @@ data class Quad(val v1: Vertex, val v2: Vertex, val v3: Vertex, val v4: Vertex)
*/
class Model() {
constructor(other: List<Quad>) : this() { quads.addAll(other) }
val quads = linkedListOf<Quad>()
val quads = mutableListOf<Quad>()
fun Quad.add() = quads.add(this)
fun Iterable<Quad>.addAll() = forEach { quads.add(it) }

View File

@@ -53,7 +53,7 @@ abstract class ModelDataInspector {
abstract class BlockTextureInspector<T> : ModelDataInspector() {
val state2Names = hashMapOf<IBlockState, Iterable<String>>()
val modelMappings = linkedListOf<Pair<(IBlockState, IModel)->Boolean, Iterable<String>>>()
val modelMappings = mutableListOf<Pair<(IBlockState, IModel)->Boolean, Iterable<String>>>()
val stateMap = hashMapOf<IBlockState, T>()
fun match(textureNames: Iterable<String>, predicate: (IBlockState, IModel)->Boolean) =

View File

@@ -34,7 +34,7 @@ interface IWorldLoadListener { fun onWorldLoad(world: World) }
*/
open class ResourceHandler(val modId: String) {
val resources = linkedListOf<Any>()
val resources = mutableListOf<Any>()
open fun afterStitch() {}
// ============================

View File

@@ -79,7 +79,7 @@ abstract class TextureGenerator(domain: String) : ParameterBasedGenerator(domain
*/
fun getMultisizeTexture(maxSize: Int, maskPath: (Int)->ResourceLocation): IResource? {
var size = maxSize
val sizes = linkedListOf<Int>()
val sizes = mutableListOf<Int>()
while(size > 2) { sizes.add(size); size /= 2 }
return sizes.map { resourceManager[maskPath(it)] }.filterNotNull().firstOrNull()
}