This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| CREATE TABLE `stats` ( | |
| `namespace_id` int(11) NOT NULL, | |
| `stat_id` int(11) NOT NULL, | |
| `player_id` int(11) NOT NULL, | |
| `world_id` int(11) NOT NULL, | |
| `primary_stat_type_id` int(11) NOT NULL, | |
| `secondary_stat_type_id` int(11) NOT NULL, | |
| `primary_stat_target` varchar(255) NOT NULL, | |
| `secondary_stat_target` varchar(255) NOT NULL, | |
| `value` bigint(20) NOT NULL, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| CREATE TABLE `stats` ( | |
| `namespace_id` int(11) NOT NULL, | |
| `stat_id` int(11) NOT NULL, | |
| `player_id` int(11) NOT NULL, | |
| `world_id` int(11) NOT NULL, | |
| `primary_stat_type_id` int(11) NOT NULL, | |
| `secondary_stat_type_id` int(11) NOT NULL, | |
| `primary_stat_target` varchar(255) NOT NULL, | |
| `secondary_stat_target` varchar(255) NOT NULL, | |
| `value` bigint(20) NOT NULL, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * StatCraft Bukkit Plugin | |
| * | |
| * Copyright (c) 2016 Kyle Wood (DemonWav) | |
| * https://www.demonwav.com | |
| * | |
| * MIT License | |
| */ | |
| package com.demonwav.statcraft.config |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * StatCraft Bukkit Plugin | |
| * | |
| * Copyright (c) 2016 Kyle Wood (DemonWav) | |
| * https://www.demonwav.com | |
| * | |
| * MIT License | |
| */ | |
| package com.demonwav.statcraft.stats; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| val result = if (damage == -1) { | |
| query | |
| .from(b) | |
| .where(b.id.eq(id), b.blockid.eq(blockid.toShort())) | |
| .uniqueResult(b.amount.sum()) | |
| } else { | |
| query | |
| .from(b) | |
| .where(b.id.eq(id), b.blockid.eq(blockid.toShort()), b.damage.eq(damage.toShort())) | |
| .uniqueResult(b.amount.sum()) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| From 18a7c61b49b65c2a682a9b8274e0d81e11975cae Mon Sep 17 00:00:00 2001 | |
| From: DemonWav <demonwav@gmail.com> | |
| Date: Mon, 29 Feb 2016 19:37:41 -0600 | |
| Subject: [PATCH] Add Location support to tab completers (vanilla feature | |
| missing in CraftBukkit) | |
| diff --git a/src/main/java/org/bukkit/command/Command.java b/src/main/java/org/bukkit/command/Command.java | |
| index 548d570..18c54b3 100644 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /home/demonwav/IdeaProjects/StatCraft/src/main/kotlin/com/demonwav/statcraft/StatCraft.kt: (490, 48) org.jetbrains.kotlin.codegen.CompilationException: Back-end (JVM) Internal error: Couldn't inline method call 'use' into | |
| local final fun <anonymous>(player: (Player..Player?)): kotlin.Unit defined in com.demonwav.statcraft.StatCraft.finishPlaytimeAndBed[AnonymousFunctionDescriptor@4ed7c1ce] | |
| { player -> | |
| val uuid = player.uniqueId | |
| val id = databaseManager.getPlayerId(uuid) | |
| try { | |
| databaseManager.connection.use { | |
| QSeen.seen.runQuery( | |
| { s, clause -> clause.columns(s.id, s.lastLeaveTime).values(id, currentTime).execute() }, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| inline fun <T> MutableIterable<T>.iter(func: MutableIterator<T>.(T) -> Unit) { | |
| val iter = iterator() | |
| while (iter.hasNext()) { | |
| val item = iter.next() | |
| iter.func(item) | |
| } | |
| } | |
| fun example() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| inline fun <T> MutableIterable<T>.iter(func: MutableIterator<T>.(T) -> Unit) { | |
| val iter = iterator() | |
| while (iter.hasNext()) { | |
| val item = iter.next() | |
| func(iter, item) | |
| } | |
| } | |
| fun example() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| inline fun <T> MutableIterable<T>.iter(func: MutableIterator<T>.(T) -> Unit) { | |
| val iter = iterator() | |
| while (iter.hasNext()) { | |
| val item = iter.next() | |
| func(iter, item) | |
| } | |
| } | |
| fun example() { |