core :: union_find
union–find algorithm using an efficient disjoint-set data structureaccept_scroll_and_zoom
gamnit :: camera_control_android
Two fingers camera manipulation, pinch to zoom and slide to scrollgamnit :: camera_control_linux
Mouse wheel and middle mouse button to control cameraapp.nit
on Android using a custom Java entry point
EulerCamera
and App::frame_core_draw
to get a stereoscopic view
# Portable services to load resources from the assets folder
module assets
# Resource from the assets folder
#
# At compilation, the asset folder should be at the root of the package.
# In practice, this is usually next to the folders `src` and `bin`.
#
# These assets are packaged with the application.
abstract class Asset
# Path to this asset within the assets folder
var path: String
end
# Text file from the assets folder
#
# Use `to_s` to get the content of this asset.
class TextAsset
super Asset
# Text content of this asset
redef var to_s = load is lazy
# Load this asset
fun load: String do return ""
# Error on the last call to `load`, if any
var error: nullable Error = null
end
lib/app/assets.nit:15,1--44,3