mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-06-14 20:44:05 +09:00
asset archiving wip
This commit is contained in:
@@ -53,9 +53,9 @@ class BasicDebugInfoWindow : UICanvas() {
|
||||
private var ingame: IngameInstance? = null
|
||||
internal var world: GameWorld? = null // is set by IngameRenderer.setRenderedWorld(GameWorld)
|
||||
|
||||
private val icons = TextureRegionPack(Gdx.files.internal("assets/graphics/gui/debug_window_symbols.tga"), 21, 26)
|
||||
private val back = Texture(Gdx.files.internal("assets/graphics/gui/debug_window_background.tga"))
|
||||
private val back2 = Texture(Gdx.files.internal("assets/graphics/gui/debug_window_background2.tga"))
|
||||
private val icons = TextureRegionPack(AssetCache.getFileHandle("graphics/gui/debug_window_symbols.tga"), 21, 26)
|
||||
private val back = Texture(AssetCache.getFileHandle("graphics/gui/debug_window_background.tga"))
|
||||
private val back2 = Texture(AssetCache.getFileHandle("graphics/gui/debug_window_background2.tga"))
|
||||
|
||||
private val ARROW_RIGHT = 0xC0.toChar()
|
||||
private val ARROW_LEFT = 0xC1.toChar()
|
||||
|
||||
@@ -46,11 +46,11 @@ object Toolkit : Disposable {
|
||||
}
|
||||
private lateinit var fboBlur: Float16FrameBuffer
|
||||
|
||||
// val baloonTile = TextureRegionPack("assets/graphics/gui/message_black_tileable.tga", 36, 36)
|
||||
val shadowTile = TextureRegionPack("assets/graphics/gui/blur_shadow.tga", 32, 32)
|
||||
// val baloonTile = TextureRegionPack(AssetCache.getFileHandle("graphics/gui/message_black_tileable.tga"), 36, 36)
|
||||
val shadowTile = TextureRegionPack(AssetCache.getFileHandle("graphics/gui/blur_shadow.tga"), 32, 32)
|
||||
|
||||
val textureWhiteSquare = Texture(Gdx.files.internal("assets/graphics/ortho_line_tex_2px.tga"))
|
||||
val textureWhiteCircle = Texture(Gdx.files.internal("assets/graphics/circle_512.tga"))
|
||||
val textureWhiteSquare = Texture(AssetCache.getFileHandle("graphics/ortho_line_tex_2px.tga"))
|
||||
val textureWhiteCircle = Texture(AssetCache.getFileHandle("graphics/circle_512.tga"))
|
||||
|
||||
init {
|
||||
App.disposables.add(this)
|
||||
@@ -59,7 +59,7 @@ object Toolkit : Disposable {
|
||||
textureWhiteCircle.setFilter(Texture.TextureFilter.Linear, Texture.TextureFilter.Linear)
|
||||
|
||||
CommonResourcePool.addToLoadingList("toolkit_box_border") {
|
||||
TextureRegionPack(Gdx.files.internal("./assets/graphics/gui/box_border_flat_tileable.tga"), 1, 1)
|
||||
TextureRegionPack(AssetCache.getFileHandle("graphics/gui/box_border_flat_tileable.tga"), 1, 1)
|
||||
}
|
||||
CommonResourcePool.loadAll()
|
||||
}
|
||||
|
||||
@@ -4,6 +4,7 @@ import com.badlogic.gdx.Input
|
||||
import com.badlogic.gdx.graphics.Camera
|
||||
import com.badlogic.gdx.graphics.OrthographicCamera
|
||||
import com.badlogic.gdx.graphics.g2d.SpriteBatch
|
||||
import net.torvald.terrarum.AssetCache
|
||||
import net.torvald.terrarum.CommonResourcePool
|
||||
import net.torvald.terrarum.imagefont.TinyAlphNum
|
||||
import net.torvald.terrarumsansbitmap.gdx.TextureRegionPack
|
||||
@@ -26,7 +27,7 @@ class UIItemConfigKeycap(
|
||||
if (keySize < 3) throw IllegalArgumentException("Key size must be greater than 2 (got $keySize)")
|
||||
|
||||
CommonResourcePool.addToLoadingList("ui_item_keymap_keycap") {
|
||||
TextureRegionPack("./assets/graphics/gui/ui_control_key_map_keycap.tga", 8, 32)
|
||||
TextureRegionPack(AssetCache.getFileHandle("graphics/gui/ui_control_key_map_keycap.tga"), 8, 32)
|
||||
}
|
||||
CommonResourcePool.loadAll()
|
||||
}
|
||||
|
||||
@@ -4,6 +4,7 @@ import com.badlogic.gdx.Gdx
|
||||
import com.badlogic.gdx.graphics.Color
|
||||
import com.badlogic.gdx.graphics.OrthographicCamera
|
||||
import com.badlogic.gdx.graphics.g2d.SpriteBatch
|
||||
import net.torvald.terrarum.AssetCache
|
||||
import net.torvald.terrarum.CommonResourcePool
|
||||
import net.torvald.terrarum.imagefont.BigAlphNum
|
||||
import net.torvald.terrarum.utils.PasswordBase32
|
||||
@@ -34,7 +35,7 @@ class UIItemRedeemCodeArea(
|
||||
|
||||
init {
|
||||
CommonResourcePool.addToLoadingList("spritesheet:terrarum_redeem_code_form") {
|
||||
TextureRegionPack(Gdx.files.internal("assets/graphics/code_input_cells.tga"), CELL_W, CELL_H)
|
||||
TextureRegionPack(AssetCache.getFileHandle("graphics/code_input_cells.tga"), CELL_W, CELL_H)
|
||||
}
|
||||
CommonResourcePool.loadAll()
|
||||
}
|
||||
|
||||
@@ -7,6 +7,7 @@ import com.badlogic.gdx.graphics.OrthographicCamera
|
||||
import com.badlogic.gdx.graphics.Texture
|
||||
import com.badlogic.gdx.graphics.g2d.SpriteBatch
|
||||
import net.torvald.terrarum.App
|
||||
import net.torvald.terrarum.AssetCache
|
||||
import net.torvald.terrarum.CommonResourcePool
|
||||
import net.torvald.terrarum.blendNormalStraightAlpha
|
||||
import net.torvald.terrarum.toInt
|
||||
@@ -28,7 +29,7 @@ class UIItemToggleButton(
|
||||
|
||||
init {
|
||||
CommonResourcePool.addToLoadingList("gui_toggler_icons") {
|
||||
TextureRegionPack(Texture(Gdx.files.internal("assets/graphics/gui/toggler_icons.tga")), 14, 14)
|
||||
TextureRegionPack(Texture(AssetCache.getFileHandle("graphics/gui/toggler_icons.tga")), 14, 14)
|
||||
}
|
||||
CommonResourcePool.loadAll()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user