├── .github └── workflows │ └── github-pages.yml ├── .gitignore ├── .prettierrc ├── .vscode ├── extensions.json ├── settings.json ├── spellright.dict └── tasks.json ├── LICENSE ├── README.md ├── documentation ├── core-engine │ ├── declarations │ │ ├── ActorRenderer.d.ts │ │ ├── AddonEntityRegistry.d.ts │ │ ├── Animation.d.ts │ │ ├── Armor.d.ts │ │ ├── AttachableRender.d.ts │ │ ├── Block.d.ts │ │ ├── BlockRenderer.d.ts │ │ ├── BlockSource.d.ts │ │ ├── BlockState.d.ts │ │ ├── Callback.d.ts │ │ ├── Commands.d.ts │ │ ├── Config.d.ts │ │ ├── CoreEngine.d.ts │ │ ├── CustomBiome.d.ts │ │ ├── CustomEnchant.d.ts │ │ ├── Debug.d.ts │ │ ├── Defines.d.ts │ │ ├── Dimensions.d.ts │ │ ├── Entity.d.ts │ │ ├── EntityAI.d.ts │ │ ├── EntityModel.d.ts │ │ ├── Enums.d.ts │ │ ├── FileTools.d.ts │ │ ├── Game.d.ts │ │ ├── GameObject.d.ts │ │ ├── GenerationUtils.d.ts │ │ ├── ICRender.d.ts │ │ ├── IDRegistry.d.ts │ │ ├── Item.d.ts │ │ ├── ItemContainer.d.ts │ │ ├── ItemExtraData.d.ts │ │ ├── ItemModel.d.ts │ │ ├── LiquidRegistry.d.ts │ │ ├── Logger.d.ts │ │ ├── LowLevelUtils.d.ts │ │ ├── ModAPI.d.ts │ │ ├── ModJsAdapter.d.ts │ │ ├── ModPackJsAdapter.d.ts │ │ ├── NBT.d.ts │ │ ├── Native.d.ts │ │ ├── NativeTileEntity.d.ts │ │ ├── Network.d.ts │ │ ├── NetworkClient.d.ts │ │ ├── NetworkConnectedClientList.d.ts │ │ ├── NetworkEntity.d.ts │ │ ├── NetworkEntityType.d.ts │ │ ├── Particles.d.ts │ │ ├── Player.d.ts │ │ ├── PlayerActor.d.ts │ │ ├── Recipes.d.ts │ │ ├── Render.d.ts │ │ ├── RenderMesh.d.ts │ │ ├── Saver.d.ts │ │ ├── ShaderUniformSet.d.ts │ │ ├── SyncedNetworkData.d.ts │ │ ├── Texture.d.ts │ │ ├── Threading.d.ts │ │ ├── TileEntity.d.ts │ │ ├── ToolAPI.d.ts │ │ ├── Translation.d.ts │ │ ├── UI.d.ts │ │ ├── Updatable.d.ts │ │ ├── VanillaBlockID.d.ts │ │ ├── VanillaItemID.d.ts │ │ ├── VanillaTileID.d.ts │ │ ├── Variables.d.ts │ │ ├── World.d.ts │ │ ├── WorldRenderer.d.ts │ │ ├── com │ │ │ └── zhekasmirnov │ │ │ │ ├── apparatus │ │ │ │ └── api │ │ │ │ │ └── container │ │ │ │ │ ├── ItemContainer.d.ts │ │ │ │ │ ├── ItemContainerSlot.d.ts │ │ │ │ │ └── ItemContainerUiHandler.d.ts │ │ │ │ ├── horizon │ │ │ │ ├── modloader │ │ │ │ │ ├── ExecutionDirectory.d.ts │ │ │ │ │ ├── LaunchSequence.d.ts │ │ │ │ │ ├── ModContext.d.ts │ │ │ │ │ ├── configuration │ │ │ │ │ │ └── Configuration.d.ts │ │ │ │ │ ├── java │ │ │ │ │ │ ├── JavaDirectory.d.ts │ │ │ │ │ │ ├── JavaLibrary.d.ts │ │ │ │ │ │ └── JavaLibraryManifest.d.ts │ │ │ │ │ ├── library │ │ │ │ │ │ ├── Library.d.ts │ │ │ │ │ │ ├── LibraryDirectory.d.ts │ │ │ │ │ │ ├── LibraryMakeFile.d.ts │ │ │ │ │ │ └── LibraryManifest.d.ts │ │ │ │ │ ├── mod │ │ │ │ │ │ ├── Mod.d.ts │ │ │ │ │ │ ├── ModGraphics.d.ts │ │ │ │ │ │ ├── ModInstance.d.ts │ │ │ │ │ │ ├── ModManifest.d.ts │ │ │ │ │ │ └── Module.d.ts │ │ │ │ │ ├── repo │ │ │ │ │ │ ├── location │ │ │ │ │ │ │ └── ModLocation.d.ts │ │ │ │ │ │ └── storage │ │ │ │ │ │ │ └── TemporaryStorage.d.ts │ │ │ │ │ └── resource │ │ │ │ │ │ ├── ResourceManager.d.ts │ │ │ │ │ │ ├── ResourceOverride.d.ts │ │ │ │ │ │ ├── directory │ │ │ │ │ │ ├── Resource.d.ts │ │ │ │ │ │ ├── ResourceDirectory.d.ts │ │ │ │ │ │ └── ResourceMeta.d.ts │ │ │ │ │ │ ├── processor │ │ │ │ │ │ └── ResourceProcessor.d.ts │ │ │ │ │ │ └── runtime │ │ │ │ │ │ ├── RuntimeResource.d.ts │ │ │ │ │ │ ├── RuntimeResourceDirectory.d.ts │ │ │ │ │ │ └── RuntimeResourceHandler.d.ts │ │ │ │ └── runtime │ │ │ │ │ └── logger │ │ │ │ │ └── EventLogger.d.ts │ │ │ │ └── innercore │ │ │ │ ├── api │ │ │ │ ├── NativeItemInstanceExtra.d.ts │ │ │ │ ├── NativeRenderMesh.d.ts │ │ │ │ ├── NativeRenderer.d.ts │ │ │ │ ├── mod │ │ │ │ │ ├── recipes │ │ │ │ │ │ └── workbench │ │ │ │ │ │ │ ├── InventoryPool.d.ts │ │ │ │ │ │ │ ├── RecipeEntry.d.ts │ │ │ │ │ │ │ ├── WorkbenchField.d.ts │ │ │ │ │ │ │ └── WorkbenchFieldAPI.d.ts │ │ │ │ │ ├── ui │ │ │ │ │ │ ├── ContentProvider.d.ts │ │ │ │ │ │ ├── GuiBlockModel.d.ts │ │ │ │ │ │ ├── GuiRenderMesh.d.ts │ │ │ │ │ │ ├── IBackgroundProvider.d.ts │ │ │ │ │ │ ├── IElementProvider.d.ts │ │ │ │ │ │ ├── ItemModelCacheManager.d.ts │ │ │ │ │ │ ├── TextureSource.d.ts │ │ │ │ │ │ ├── background │ │ │ │ │ │ │ ├── DrawColor.d.ts │ │ │ │ │ │ │ ├── DrawCustom.d.ts │ │ │ │ │ │ │ ├── DrawFrame.d.ts │ │ │ │ │ │ │ ├── DrawImage.d.ts │ │ │ │ │ │ │ ├── DrawLine.d.ts │ │ │ │ │ │ │ ├── DrawText.d.ts │ │ │ │ │ │ │ ├── DrawingFactory.d.ts │ │ │ │ │ │ │ └── IDrawing.d.ts │ │ │ │ │ │ ├── container │ │ │ │ │ │ │ ├── AbstractSlot.d.ts │ │ │ │ │ │ │ ├── Container.d.ts │ │ │ │ │ │ │ ├── ScriptableUiVisualSlotImpl.d.ts │ │ │ │ │ │ │ ├── Slot.d.ts │ │ │ │ │ │ │ ├── UiAbstractContainer.d.ts │ │ │ │ │ │ │ └── UiVisualSlotImpl.d.ts │ │ │ │ │ │ ├── elements │ │ │ │ │ │ │ ├── ElementFactory.d.ts │ │ │ │ │ │ │ ├── UIButtonElement.d.ts │ │ │ │ │ │ │ ├── UICloseButtonElement.d.ts │ │ │ │ │ │ │ ├── UICustomElement.d.ts │ │ │ │ │ │ │ ├── UIElement.d.ts │ │ │ │ │ │ │ ├── UIElementCleaner.d.ts │ │ │ │ │ │ │ ├── UIFPSTextElement.d.ts │ │ │ │ │ │ │ ├── UIFrameElement.d.ts │ │ │ │ │ │ │ ├── UIImageElement.d.ts │ │ │ │ │ │ │ ├── UIInvSlotElement.d.ts │ │ │ │ │ │ │ ├── UIScaleElement.d.ts │ │ │ │ │ │ │ ├── UIScrollElement.d.ts │ │ │ │ │ │ │ ├── UISlotElement.d.ts │ │ │ │ │ │ │ ├── UISwitchElement.d.ts │ │ │ │ │ │ │ ├── UITabElement.d.ts │ │ │ │ │ │ │ └── UITextElement.d.ts │ │ │ │ │ │ ├── icon │ │ │ │ │ │ │ ├── ItemIconLoader.d.ts │ │ │ │ │ │ │ ├── ItemIconSource.d.ts │ │ │ │ │ │ │ └── ItemModels.d.ts │ │ │ │ │ │ ├── memory │ │ │ │ │ │ │ ├── BitmapCache.d.ts │ │ │ │ │ │ │ ├── BitmapWrap.d.ts │ │ │ │ │ │ │ ├── RandomBitmapWrap.d.ts │ │ │ │ │ │ │ └── SourceBitmapWrap.d.ts │ │ │ │ │ │ ├── types │ │ │ │ │ │ │ ├── Font.d.ts │ │ │ │ │ │ │ ├── FrameTexture.d.ts │ │ │ │ │ │ │ ├── FrameTextureSource.d.ts │ │ │ │ │ │ │ ├── ITouchEventListener.d.ts │ │ │ │ │ │ │ ├── Texture.d.ts │ │ │ │ │ │ │ ├── TouchEvent.d.ts │ │ │ │ │ │ │ ├── TouchEventType.d.ts │ │ │ │ │ │ │ └── UIStyle.d.ts │ │ │ │ │ │ └── window │ │ │ │ │ │ │ ├── IWindow.d.ts │ │ │ │ │ │ │ ├── IWindowEventListener.d.ts │ │ │ │ │ │ │ ├── UIAdaptiveWindow.d.ts │ │ │ │ │ │ │ ├── UITabbedWindow.d.ts │ │ │ │ │ │ │ ├── UIWindow.d.ts │ │ │ │ │ │ │ ├── UIWindowBackgroundDrawable.d.ts │ │ │ │ │ │ │ ├── UIWindowElementDrawable.d.ts │ │ │ │ │ │ │ ├── UIWindowGroup.d.ts │ │ │ │ │ │ │ ├── UIWindowLocation.d.ts │ │ │ │ │ │ │ ├── UIWindowStandard.d.ts │ │ │ │ │ │ │ ├── WindowParent.d.ts │ │ │ │ │ │ │ └── WindowProvider.d.ts │ │ │ │ │ └── util │ │ │ │ │ │ ├── ConfigVisualizer.d.ts │ │ │ │ │ │ └── ScriptableWatcher.d.ts │ │ │ │ └── unlimited │ │ │ │ │ ├── BlockShape.d.ts │ │ │ │ │ └── BlockVariant.d.ts │ │ │ │ └── mod │ │ │ │ ├── build │ │ │ │ └── Config.d.ts │ │ │ │ └── resource │ │ │ │ ├── ResourcePackManager.d.ts │ │ │ │ ├── ResourceStorage.d.ts │ │ │ │ ├── pack │ │ │ │ ├── IResourcePack.d.ts │ │ │ │ └── ResourcePack.d.ts │ │ │ │ └── types │ │ │ │ ├── ResourceFile.d.ts │ │ │ │ ├── TextureAnimationFile.d.ts │ │ │ │ ├── TextureAtlasDescription.d.ts │ │ │ │ └── enums │ │ │ │ ├── AnimationType.d.ts │ │ │ │ ├── FileType.d.ts │ │ │ │ ├── ParseError.d.ts │ │ │ │ └── TextureType.d.ts │ │ └── core_dump.d.ts │ └── headers │ │ ├── android-declarations.d.ts │ │ └── android.d.ts └── static │ ├── .nojekyll │ ├── en │ ├── README.md │ ├── config │ │ ├── _navbar.md │ │ └── _sidebar.md │ └── page │ │ ├── apps │ │ ├── horizon │ │ │ ├── index.md │ │ │ ├── pack-system.md │ │ │ └── packs.md │ │ └── innercore │ │ │ ├── changelog.md │ │ │ └── index.md │ │ ├── guides │ │ ├── getting-started │ │ │ └── config.md │ │ ├── minecraft │ │ │ ├── attributes.md │ │ │ └── playercontainers.md │ │ ├── mod-api │ │ │ └── callbacks.md │ │ ├── mod-resources │ │ │ └── materials.md │ │ ├── player │ │ │ └── abilities.md │ │ └── world │ │ │ ├── biomes.md │ │ │ └── dimensions.md │ │ ├── lib │ │ └── BackpackAPI.md │ │ ├── mod-lib │ │ ├── CoreUtility.md │ │ └── DungeonUtility.md │ │ ├── mod │ │ └── IndustrialCraft2.md │ │ ├── other │ │ ├── contributing.md │ │ └── create-page.md │ │ └── wiki │ │ └── building-mods │ │ └── mod_structure.md │ ├── images │ ├── dimensions-1.jpg │ ├── dimensions-2.jpg │ ├── dimensions-3.jpg │ ├── dimensions-4.jpg │ ├── dimensions-5.jpg │ ├── dimensions-6.jpg │ └── dimensions-7.jpg │ ├── index.html │ ├── ru │ ├── README.md │ ├── config │ │ ├── _navbar.md │ │ └── _sidebar.md │ └── page │ │ ├── building-mods │ │ ├── basic-methods-and-variables-of-executable-files.md │ │ ├── bytecode-compilation.md │ │ ├── libraries.md │ │ ├── mod-resources.md │ │ ├── mod_structure.md │ │ └── standart-mod-template.md │ │ └── coreengine-global-methods-and-variables.md │ └── src │ ├── config.js │ ├── docsify-v4.js │ ├── syntax │ └── json.min.js │ └── themes │ ├── dark-light.css │ ├── dark-light.js │ ├── fix.css │ └── vue.css ├── gruntfile.js ├── innercore-test_changelog-ru.html ├── package.json └── tsconfig.json /.github/workflows/github-pages.yml: -------------------------------------------------------------------------------- 1 | name: Build docs & Deploy 2 | on: 3 | push: 4 | branches: 5 | - master 6 | jobs: 7 | build: 8 | runs-on: ubuntu-latest 9 | steps: 10 | - name: Checkout 11 | uses: actions/checkout@v2 12 | - name: Setup Node 13 | uses: actions/setup-node@v2 14 | with: 15 | node-version: '14' 16 | - name: Cache 17 | uses: actions/cache@v1 18 | with: 19 | path: ~/.npm 20 | key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} 21 | restore-keys: | 22 | ${{ runner.os }}-node- 23 | - name: Setup grunt 24 | run: npm install -g grunt-cli 25 | - name: Setup other dependencies 26 | run: npm install --safe-dev 27 | - name: Build docs 28 | run: grunt docs_api 29 | - name: Deploy 30 | uses: JamesIves/github-pages-deploy-action@4.1.6 31 | with: 32 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} 33 | BASE_BRANCH: master 34 | BRANCH: gh-pages 35 | FOLDER: out 36 | single-commit: true -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | /documentation/core-engine/headers/core-engine.d.ts 2 | /package-lock.json 3 | /node_modules 4 | /OLD 5 | /out -------------------------------------------------------------------------------- /.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "printWidth": 120, 3 | "trailingComma": "none", 4 | "singleQuote": true 5 | } 6 | -------------------------------------------------------------------------------- /.vscode/extensions.json: -------------------------------------------------------------------------------- 1 | { 2 | "recommendations": [ 3 | "davidanson.vscode-markdownlint", 4 | "usernamehw.errorlens", 5 | "michelemelluso.gitignore", 6 | "spmeesseman.vscode-taskexplorer", 7 | "yzhang.markdown-all-in-one" 8 | ] 9 | } 10 | -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "files.exclude": { 3 | "node_modules": true 4 | }, 5 | "spellright.language": [ 6 | "en", 7 | "uk" 8 | ], 9 | "spellright.documentTypes": [ 10 | "markdown", 11 | "latex", 12 | "plaintext" 13 | ], 14 | "markdown.extension.tableFormatter.normalizeIndentation": true, 15 | "markdown.extension.list.indentationSize": "inherit", 16 | "markdown.extension.toc.orderedList": true 17 | } -------------------------------------------------------------------------------- /.vscode/spellright.dict: -------------------------------------------------------------------------------- 1 | shaders 2 | shader 3 | boolean 4 | minecraft 5 | Superflat 6 | Params 7 | perlin 8 | -------------------------------------------------------------------------------- /.vscode/tasks.json: -------------------------------------------------------------------------------- 1 | { 2 | // See https://go.microsoft.com/fwlink/?LinkId=733558 3 | // for the documentation about the tasks.json format 4 | "version": "2.0.0", 5 | "tasks": [ 6 | { 7 | "label": "Run typedoc", 8 | "type": "shell", 9 | "command": "grunt docs_api", 10 | "group": { 11 | "kind": "build", 12 | "isDefault": true 13 | } 14 | }, 15 | { 16 | "label": "Initialize Environment", 17 | "type": "shell", 18 | "options": { 19 | "cwd": "documentation" 20 | }, 21 | "command": "npm install --safe-dev", 22 | "group": { 23 | "kind": "build", 24 | "isDefault": true 25 | } 26 | } 27 | ] 28 | } -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Pre-Requirements 2 | 3 | - Visual Studio Code 4 | - node.js & npm 5 | - grunt-cli package installed globally using npm 6 | 7 | To install grunt-cli, run the following command in your Terminal: 8 | 9 | ```bat 10 | npm install -g grunt-cli 11 | ``` 12 | 13 | ## Building documentation and headers 14 | 15 | Documentation repository is located at [GitHub](https://github.com/mineprogramming/innercore-docs). 16 | 17 | To build this repository locally, open this folder in Visual Studio Code and run (_Ctrl+Shift+B_) **Initialize Environment** task. This will install all required npm dependencies locally. To build typedoc documentation and headers, run **Run Typedoc** task. 18 | 19 | [Goto Docs](/) 20 | -------------------------------------------------------------------------------- /documentation/core-engine/declarations/ActorRenderer.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Class, upon which armor and attachments render is based 3 | * It is a model that consists of parts, same as in deprecated [[Render]], 4 | * but more abstract, allows creating root parts instead of 5 | * inheritance from old humanoid model 6 | */ 7 | declare class ActorRenderer { 8 | /** 9 | * Constructs new [[ActorRenderer]] object without parts 10 | */ 11 | constructor(); 12 | /** 13 | * Constructs new [[ActorRenderer]] object, 14 | * based on one of default Minecraft render templates 15 | * @param templateName default template name 16 | */ 17 | constructor(templateName: DefaultRenderTemplate); 18 | 19 | getUniformSet(): ShaderUniformSet; 20 | 21 | setTexture(textureName: string): void; 22 | 23 | setMaterial(materialName: string): void; 24 | 25 | getPart(name: string): ActorRenderer.ModelPart; 26 | 27 | /** 28 | * Adds a child model part of an existing one 29 | * @param name child model name 30 | * @param parentName parent model name 31 | */ 32 | addPart(name: string, parentName: string, mesh?: RenderMesh): ActorRenderer.ModelPart; 33 | 34 | /** 35 | * Adds a root model part 36 | */ 37 | addPart(name: string, mesh?: RenderMesh): ActorRenderer.ModelPart; 38 | 39 | } 40 | 41 | declare namespace ActorRenderer { 42 | 43 | class ModelPart { 44 | 45 | /** 46 | * All methods of [[ActorRenderer.ModelPart]] build in such a way, 47 | * that you can create full render in one chain of calls 48 | * ```js 49 | * new ActorRenderer().addPart("Child", "Parent").addPart("Grandchild", "Child").endPart(); 50 | * ``` 51 | */ 52 | endPart(): ActorRenderer; 53 | 54 | setTexture(textureName: string): ModelPart; 55 | 56 | setMaterial(materialName: string): ModelPart; 57 | 58 | setTextureSize(w: number, h: number): ModelPart; 59 | 60 | setOffset(x: number, y: number, z: number): ModelPart; 61 | 62 | setRotation(x: number, y: number, z: number): ModelPart; 63 | 64 | setPivot(x: number, y: number, z: number): ModelPart; 65 | 66 | setMirrored(isMirrored: boolean): ModelPart; 67 | 68 | /** 69 | * @param inflate increases the box by a certain value in all directions 70 | */ 71 | addBox(x: number, y: number, z: number, sizeX: number, sizeY: number, sizeZ: number, inflate: number, u: number, v: number): ModelPart; 72 | 73 | clear(): ModelPart; 74 | 75 | } 76 | 77 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/AddonEntityRegistry.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Module used to manage custom entities added via add-ons 3 | */ 4 | declare namespace AddonEntityRegistry { 5 | /** 6 | * Spawns an entity defined via add-on on the specified coordinates 7 | * @param nameID entity name id, as defined from add-on 8 | */ 9 | function spawn(x: number, y: number, z: number, nameID: string): number; 10 | 11 | /** 12 | * @returns add-on entity information by entity id 13 | * @param entity 14 | */ 15 | function getEntityData(entity: number): AddonEntity; 16 | 17 | 18 | interface AddonEntity { 19 | /** 20 | * Entity unique id 21 | */ 22 | readonly id: number, 23 | 24 | /** 25 | * Add-on defined entity name id 26 | */ 27 | readonly type: string, 28 | 29 | /** 30 | * Executes command with the entity 31 | * @param command command to be executed 32 | * @returns error message or null if the command was run successfully 33 | */ 34 | exec(command: string): Nullable; 35 | 36 | /** 37 | * Executes command with the entity on the specified coordinates 38 | * @param command command to be executed 39 | * @returns error message or null if the command was run successfully 40 | */ 41 | execAt(command: string, x: number, y: number, z: number): Nullable; 42 | } 43 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/AttachableRender.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Class used to attach attachables to entities 3 | */ 4 | declare class AttachableRender { 5 | 6 | static attachRendererToItem(id: number, renderer: AttachableRender, texture?: string, material?: string): void; 7 | 8 | static detachRendererFromItem(id: number): void; 9 | 10 | /** 11 | * Constructs new [[AttachableRender]] object bind to given entity 12 | */ 13 | constructor(actorUid: number); 14 | 15 | getUniformSet(): ShaderUniformSet; 16 | 17 | /** 18 | * Sets the render, root render parts will be drawing 19 | * together with mob's render parts with same names 20 | * (names can be seen in json description of the model in resources) 21 | */ 22 | setRenderer(actorRenderer: ActorRenderer): AttachableRender; 23 | 24 | setTexture(textureName: string): AttachableRender; 25 | 26 | setMaterial(materialName: string): AttachableRender; 27 | 28 | destroy(): void; 29 | 30 | isAttached(): boolean; 31 | 32 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/Commands.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Namespace used to manipulate minecraft commands 3 | */ 4 | declare namespace Commands { 5 | /** 6 | * Executes specified command 7 | * @param command command to be executed 8 | * @returns error message or null if the command was run successfully 9 | */ 10 | function exec(command: string): Nullable; 11 | 12 | /** 13 | * Executes specified command using specified coordinates as command 14 | * location for all relative calculations 15 | * @param command command to be executed 16 | * @returns error message or null if the command was run successfully 17 | */ 18 | function execAt(command: string, x: number, y: number, z: number): Nullable; 19 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/Config.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Json configuration file reading/writing utility 3 | */ 4 | declare class Config extends com.zhekasmirnov.innercore.mod.build.Config { 5 | static class: java.lang.Class; 6 | } 7 | 8 | declare namespace Config { 9 | /** 10 | * Class representing config value with its path withing Config object 11 | */ 12 | class ConfigValue extends com.zhekasmirnov.innercore.mod.build.Config.ConfigValue { 13 | static class: java.lang.Class; 14 | } 15 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/Debug.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Defines some useful methods for debugging 3 | */ 4 | declare namespace Debug { 5 | /** 6 | * @returns current system time in milliseconds 7 | */ 8 | function sysTime(): number; 9 | 10 | /** 11 | * Spawns vanilla debug particle on the specified coordinates 12 | * @param id particle type id, should be one of the [[Native.ParticleType]] 13 | * @param vx x velocity 14 | * @param vy y velocity 15 | * @param vz y velocity 16 | * @param data additional particles data 17 | */ 18 | function addParticle(id: number, x: number, y: number, z: number, vx: number, vy: number, vz: number, data: number): void; 19 | 20 | /** 21 | * Writes general debug message (in green) to the chat 22 | * @param message message to be displayed 23 | */ 24 | function message(message: string): void; 25 | 26 | /** 27 | * Writes warning debug message (in gold) to the chat 28 | * @param message message to be displayed 29 | */ 30 | function warning(message: string): void; 31 | 32 | /** 33 | * Writes error debug message (in red) to the chat 34 | * @param message message to be displayed 35 | */ 36 | function error(message: string): void; 37 | 38 | /** 39 | * Writes several comma-separated values to the chat as a general debug 40 | * message, serializing javascript objects if possible 41 | * @param args messages to be displayed 42 | */ 43 | function m(...args: any[]): void; 44 | 45 | /** 46 | * Writes several values in JSON format to the copyable alert window text view, 47 | * serializing javascript objects if possible 48 | * @param args messages to be displayed 49 | */ 50 | function big(...args: any[]): void; 51 | 52 | /** 53 | * Displays an AlertDialog with given title and bitmap 54 | * @param bitmap android.graphics.Bitmap object of the bitmap to be 55 | * displayed 56 | * @param title title of the AlertDialog 57 | */ 58 | function bitmap(bitmap: android.graphics.Bitmap, title: string): void; 59 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/Defines.d.ts: -------------------------------------------------------------------------------- 1 | 2 | /** 3 | * Type used to mark Java bytes 4 | */ 5 | type jbyte = number; 6 | 7 | type Nullable = T | null; 8 | 9 | /** 10 | * Object representing the set of coordinates in the three-dimensional world 11 | */ 12 | interface Vector { 13 | x: number, 14 | y: number, 15 | z: number 16 | } 17 | 18 | /** 19 | * Object representing coordinate set with side data 20 | */ 21 | interface BlockPosition extends Vector { 22 | /** 23 | * Side of the block, one of the [[Native.BlockSide]] constants 24 | */ 25 | side: number 26 | } 27 | 28 | /** 29 | * Object representing RGB color 30 | */ 31 | interface Color { 32 | r: number, 33 | g: number, 34 | b: number 35 | } 36 | 37 | /** 38 | * Object representing pitch/yaw angle set (in radians) 39 | */ 40 | interface LookAngle { 41 | pitch: number, 42 | yaw: number 43 | } 44 | 45 | /** 46 | * Object representing item instance in the inventory 47 | */ 48 | interface ItemInstance { 49 | /** 50 | * Item id 51 | */ 52 | id: number, 53 | 54 | /** 55 | * Amount of items of the specified id 56 | */ 57 | count: number, 58 | 59 | /** 60 | * Item data value. Generally specifies some property of the item, e.g. 61 | * color, material, etc. Defaults to 0, in many cases -1 means "any data 62 | * value" 63 | */ 64 | data: number, 65 | 66 | /** 67 | * Item extra data. Contains some additional item data such as enchants, 68 | * custom item name or some additional properties 69 | */ 70 | extra?: ItemExtraData 71 | } 72 | 73 | /** 74 | * Array of three or four elements representing item id, count, data and extra respectively. 75 | * Uses in block drop functions 76 | */ 77 | type ItemInstanceArray = [number, number, number, ItemExtraData?]; 78 | 79 | /** 80 | * Object representing block in the world 81 | */ 82 | interface Tile { 83 | id: number, 84 | data: number 85 | } 86 | 87 | /** 88 | * Object representing current weather in the world 89 | */ 90 | interface Weather { 91 | /** 92 | * Current rain level, from 0 (no rain) to 10 (heavy rain) 93 | */ 94 | rain: number, 95 | /** 96 | * Current lightning level, from 0 (no lightning) to 10 97 | */ 98 | thunder: number 99 | } 100 | 101 | declare class CustomEntity { 102 | 103 | } 104 | -------------------------------------------------------------------------------- /documentation/core-engine/declarations/EntityModel.d.ts: -------------------------------------------------------------------------------- 1 | declare class EntityModel { 2 | 3 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/Game.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Module that provides some general game-related functions 3 | */ 4 | declare namespace Game { 5 | /** 6 | * Prevents current callback function from being called in Minecraft. 7 | * For most callbacks it prevents default game behaviour 8 | */ 9 | function prevent(): void; 10 | 11 | /** 12 | * @returns true if the current callback function has already been 13 | * prevented from being called in Minecraft using [[Game.prevent]], 14 | * false otherwise 15 | */ 16 | function isActionPrevented(): boolean; 17 | 18 | /** 19 | * Writes message to the chat. Message can be formatted using 20 | * [[Native.Color]] values 21 | * @param msg message to be displayed 22 | */ 23 | function message(msg: string): void; 24 | 25 | /** 26 | * Writes message above the hot bar. Message can be formatted using 27 | * [[Native.Color]] values 28 | * @param msg message to be displayed 29 | */ 30 | function tipMessage(msg: string): void; 31 | 32 | /** 33 | * Displays android AlertDialog with given message and dialog title 34 | * @param message message to be displayed 35 | * @param title title of the AlertDialog 36 | */ 37 | function dialogMessage(message: string, title: string): void; 38 | 39 | /** 40 | * Sets game difficulty, one of [[Native.GameDifficulty]] values 41 | * @param difficulty game difficulty to be set 42 | */ 43 | function setDifficulty(difficulty: number): void; 44 | 45 | /** 46 | * @returns current game difficulty, one of the [[Native.GameDifficulty]] 47 | * values 48 | */ 49 | function getDifficulty(): number; 50 | 51 | /** 52 | * Sets current level game mode 53 | * @param gameMode new game mode, should be one of the [[Native.GameMode]] 54 | * values 55 | */ 56 | function setGameMode(gameMode: number): void; 57 | 58 | /** 59 | * @returns current level game mode, one of the [[Native.GameMode]] values 60 | */ 61 | function getGameMode(): number; 62 | 63 | /** 64 | * @returns string containing current Minecraft version 65 | */ 66 | function getMinecraftVersion(): string; 67 | 68 | /** 69 | * @returns string containing current Core Engine version 70 | */ 71 | function getEngineVersion(): string; 72 | 73 | /** 74 | * @returns true if item spending allowed 75 | */ 76 | function isItemSpendingAllowed(player?: number): boolean; 77 | 78 | /** 79 | * true if developer mode was enabled in InnerCore config, false otherwise 80 | */ 81 | let isDeveloperMode: boolean; 82 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/IDRegistry.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Module used to manage item and block ids. Items and blocks have the same 3 | * underlying nature, so their ids are interchangeable. Though, the blocks are 4 | * defined "twice", as an item (in player's hand or inventory) and as a tile 5 | * (a block placed in the world) 6 | */ 7 | declare namespace IDRegistry { 8 | /** 9 | * Defines the numeric id of the first user-defined item 10 | */ 11 | const ITEM_ID_OFFSET: number; 12 | 13 | /** 14 | * Defines the numeric id of the first user-defined block 15 | */ 16 | const BLOCK_ID_OFFSET: number; 17 | 18 | /** 19 | * Defines maximum item/block id 20 | */ 21 | const MAX_ID: number; 22 | 23 | /** 24 | * Generates a new numeric block id 25 | * @param name string block id. Used in [[Block]] module functions and 26 | * in some other block-related functions. Inner Core converts it to 27 | * block_ as minecraft vanilla block id to avoid string id clashes 28 | * @returns numeric block id 29 | */ 30 | function genBlockID(name: string): number; 31 | 32 | /** 33 | * Generates a new numeric item id 34 | * @param name string item id. Used in [[Item]] module functions and 35 | * in some other item-related functions. Inner Core converts it to 36 | * item_ as minecraft vanilla item id to avoid string id clashes 37 | * @returns numeric item id 38 | */ 39 | function genItemID(name: string): number; 40 | 41 | /** 42 | * Gets item or block string id by its numeric id 43 | * @param id numeric item or block id 44 | */ 45 | function getNameByID(id: number): string; 46 | 47 | /** 48 | * Ensures given id is a tile id, not a block id. It is generally recommended 49 | * to use [[Block.convertItemToBlockId]] since it performs less calculations 50 | * @param id block or tile id 51 | * @returns tile id 52 | */ 53 | function ensureBlockId(id: number): number; 54 | 55 | /** 56 | * Ensures given id is a block id, not a tile id. It is generally recommended 57 | * to use [[Block.convertBlockToItemId]] since it performs less calculations 58 | * @param id block or tile id 59 | * @returns block id 60 | */ 61 | function ensureItemId(id: number): number; 62 | 63 | /** 64 | * @param id numeric item or block id 65 | * @returns true if item is vanilla Minecraft item, false otherwise 66 | */ 67 | function isVanilla(id: number): boolean; 68 | 69 | /** 70 | * Gets type of item ("block" or "item") and its string id in Minecraft 71 | * @param id numeric item or block id 72 | * @returns string in format "type:string_id" or 73 | * "type:string_id#extra_information" 74 | */ 75 | function getIdInfo(id: number): string; 76 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/ItemContainer.d.ts: -------------------------------------------------------------------------------- 1 | // Backward compatibility 2 | declare type TransferPolicy = com.zhekasmirnov.apparatus.api.container.ItemContainerFuncs.TransferPolicy; 3 | 4 | /** 5 | * New type of TileEntity container that supports multiplayer 6 | */ 7 | declare class ItemContainer extends com.zhekasmirnov.apparatus.api.container.ItemContainer { 8 | static class: java.lang.Class; 9 | /** 10 | * Constructs a new [[ItemContainer]] object 11 | */ 12 | constructor(); 13 | /** 14 | * Constructs a new [[ItemContainer]] object from given deprecated [[UI.Container]] object 15 | */ 16 | constructor(legacyContainer: UI.Container); 17 | } 18 | 19 | declare class ItemContainerSlot extends com.zhekasmirnov.apparatus.api.container.ItemContainerSlot {} -------------------------------------------------------------------------------- /documentation/core-engine/declarations/ItemExtraData.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Class representing item extra data. Used to store additional information 3 | * about item other then just item id and data 4 | */ 5 | declare class ItemExtraData extends com.zhekasmirnov.innercore.api.NativeItemInstanceExtra { 6 | static class: java.lang.Class; 7 | /** 8 | * Creates an empty [[ItemExtraData]] instance 9 | */ 10 | constructor(); 11 | /** 12 | * Creates a copy of current [[ItemExtraData]] instance with the same contents 13 | */ 14 | constructor(extraData?: ItemExtraData); 15 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/Logger.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Module used to log messages to Inner Core log and android log 3 | */ 4 | declare namespace Logger { 5 | /** 6 | * Writes message to the log, using specified log prefix 7 | * @param message message to be logged 8 | * @param prefix prefix of the message, can be used to filter log 9 | */ 10 | function Log(message: string, prefix: string): void; 11 | 12 | /** 13 | * Logs java Throwable with full stack trace to 14 | * @param error java Throwable to be logged 15 | */ 16 | function LogError(error: java.lang.Throwable): void; 17 | 18 | /** 19 | * Writes logger content to file and clears all buffers 20 | */ 21 | function Flush(): void; 22 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/LowLevelUtils.d.ts: -------------------------------------------------------------------------------- 1 | declare namespace LowLevelUtils { 2 | type Type_pack = "resource" | "behavior" | "behaviour"; 3 | 4 | export function setLoadingTip(tip: string): void; 5 | export function addRuntimePack(typeStr: string, name: string) 6 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/NativeTileEntity.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Interface providing access to native tile entities - chests, hoppers, furnaces, 3 | * smelters, etc. See full lists of supported native tile entities in the 4 | * [[Native.TileEntityType]] enum 5 | */ 6 | declare interface NativeTileEntity { 7 | /** 8 | * @returns native tile entity type constant, one of the [[Native.TileEntityType]] 9 | * constants 10 | */ 11 | getType(): number, 12 | 13 | /** 14 | * @returns slots count for the specified native tile entity 15 | */ 16 | getSize(): number, 17 | 18 | /** 19 | * @param slot slot number 20 | * @returns item instance in the specified slot of item TE 21 | */ 22 | getSlot(slot: number): ItemInstance, 23 | 24 | /** 25 | * Sets the contents of a native tile entity's slot 26 | * @param slot slot number 27 | * @param id item id 28 | * @param count item count 29 | * @param data item data 30 | * @param extra item extra data 31 | */ 32 | setSlot(slot: number, id: number, count: number, data: number, extra?: ItemExtraData): void; 33 | 34 | /** 35 | * Sets the contents of a native tile entity's slot 36 | * @param slot slot number 37 | * @param item item information 38 | */ 39 | setSlot(slot: number, item: ItemInstance): void; 40 | 41 | /** 42 | * @returns compound tag associated with specified native tile entity 43 | */ 44 | getCompoundTag(): NBT.CompoundTag; 45 | 46 | /** 47 | * Sets compound tag for the specified tile entity 48 | */ 49 | setCompoundTag(tag: NBT.CompoundTag): void; 50 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/Network.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * New module to work with client and server packets in multiplayer. 3 | */ 4 | declare namespace Network { 5 | /** 6 | * @returns array containing connected clients 7 | */ 8 | function getConnectedClients(): native.Array; 9 | 10 | /** 11 | * @returns array containing connected players uids 12 | */ 13 | function getConnectedPlayers(): native.Array; 14 | 15 | /** 16 | * @returns Client object for player by player's entity id 17 | */ 18 | function getClientForPlayer(player: number): NetworkClient; 19 | 20 | /** 21 | * Event that is called when a client receives a packet with given name 22 | * @param name name of the packet 23 | */ 24 | function addClientPacket(name: string, func: (packetData: T) => void): void; 25 | 26 | /** 27 | * Event that is called when server receives a packet with the specified name from client 28 | * @param name name of the packet 29 | */ 30 | function addServerPacket(name: string, func: (client: NetworkClient, data: T) => void): void; 31 | 32 | /** 33 | * Sends packet object with specified name to all clients 34 | */ 35 | function sendToAllClients(name: string, packetData: object): void; 36 | 37 | /** 38 | * Sends packet object with the specified name from client to server 39 | */ 40 | function sendToServer(name: string, packetData: object): void; 41 | 42 | /** 43 | * Sends message to all players 44 | * @param message text of the message 45 | */ 46 | function sendServerMessage(message: string): void; 47 | 48 | /** 49 | * Converts item or block id from server to local value 50 | */ 51 | function serverToLocalId(id: string | number): number; 52 | 53 | /** 54 | * Converts item or block id from local to server value 55 | */ 56 | function localToServerId(id: string | number): number; 57 | 58 | function inRemoteWorld(): boolean; 59 | } 60 | -------------------------------------------------------------------------------- /documentation/core-engine/declarations/NetworkClient.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Class that represents network client 3 | */ 4 | declare class NetworkClient { 5 | 6 | /** 7 | * Sends given packet to the following client 8 | * @param name name of the packet to send 9 | * @param packetData packet data object 10 | */ 11 | send(name: string, packetData: object): void; 12 | 13 | /** 14 | * @returns unique numeric entity ID of the player 15 | */ 16 | getPlayerUid(): number; 17 | 18 | getDisconnectCause(): java.io.IOException; 19 | 20 | getDisconnectPacket(): string; 21 | 22 | /** 23 | * Sends a packet to the client with a text like a system message 24 | */ 25 | sendMessage(message: string): void; 26 | 27 | /** 28 | * Disconnects player from the server and sends a packet with given reason 29 | */ 30 | disconnect(reason: string): void; 31 | 32 | /** 33 | * Disconnects player from the server with no further information 34 | */ 35 | disconnect(): void; 36 | 37 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/NetworkEntity.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Class that represents network entity of the block, currently is not learned 3 | */ 4 | declare class NetworkEntity { 5 | constructor(type: NetworkEntityType, context: any); 6 | remove(): void; 7 | send(name: string, data: any): void; 8 | getClients(): NetworkConnectedClientList; 9 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/NetworkEntityType.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Class that represents network entity type 3 | */ 4 | declare class NetworkEntityType { 5 | constructor(name: string); 6 | setClientListSetupListener(action: (list: NetworkConnectedClientList, target: object, entity) => void): this; 7 | setClientEntityAddedListener(action: (entity: number, packet: any) => T): this; 8 | setClientEntityRemovedListener(action: (target: any, entity: number) => void): this; 9 | setClientAddPacketFactory(action: (target: any, entity: number, client: any) => any): this; 10 | addClientPacketListener(name: string, action: (target: any, entity: number, packetData: any) => void): this; 11 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/RenderMesh.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Class representing a set of vertices with some other parameters required to 3 | * display them correctly. Used as block, entity and item models, in animations 4 | * and actually anywhere you need some physical shape 5 | */ 6 | declare class RenderMesh extends com.zhekasmirnov.innercore.api.NativeRenderMesh { 7 | /** 8 | * Creates a new [[RenderMesh]] and initializes it from file. 9 | * See [[importFromFile]] method description for parameters details 10 | */ 11 | constructor(path: string, type: string, params: Nullable); 12 | /** 13 | * Creates a new empty [[RenderMesh]] 14 | */ 15 | constructor(); 16 | } 17 | 18 | declare namespace RenderMesh { type ImportParams = com.zhekasmirnov.innercore.api.NativeRenderMesh.ImportParams } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/Saver.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Module used to save data between world sessions 3 | */ 4 | declare namespace Saver { 5 | /** 6 | * Creates saves scope, a universal data storage container. This storage 7 | * container should be used whenever you need to save some data between 8 | * world sessions. If you want to store primitives, use an object to wrap 9 | * them 10 | * 11 | * Example: 12 | * ```ts 13 | * var thirst = 20; 14 | * Saver.addSavesScope("thirst", 15 | * function read(scope){ 16 | * thirst = scope? scope.thirst: 20; 17 | * }, 18 | * 19 | * function save(){ 20 | * return {"value": thirst}; 21 | * } 22 | * ); 23 | * ``` 24 | * @param name saves scope name 25 | * @param loadFunc function used to load saved data 26 | * @param saveFunc function used to save data 27 | */ 28 | function addSavesScope(name: string, loadFunc: LoadScopeFunc, saveFunc: SaveScopeFunc): void; 29 | 30 | /** 31 | * Registers object as scope saver 32 | * @param name saves scope name 33 | * @param saver object that implements [[Saver.ScopeSaver]] interface and 34 | * can be loaded and saved via its functions calls 35 | */ 36 | function registerScopeSaver(name: string, saver: any): ScopeSaver; 37 | 38 | function registerObjectSaver(name: string, saver: any): void; 39 | 40 | function registerObject(obj: any, saverId: any): void; 41 | 42 | function setObjectIgnored(obj: any, ignore: any): void; 43 | 44 | /** 45 | * Function that returns object representing created scope. No 46 | * primitives are allowed as return value 47 | */ 48 | type SaveScopeFunc = 49 | /** 50 | * @returns saved data 51 | */ 52 | () => object; 53 | 54 | /** 55 | * Function that loads data from scope 56 | */ 57 | type LoadScopeFunc = 58 | /** 59 | * @param scope data 60 | */ 61 | (scope: Nullable) => void; 62 | 63 | /** 64 | * Interface that should be implemented to pass the object as 65 | * [[Saver.registerScopeSaver]] parameter 66 | */ 67 | interface ScopeSaver { 68 | /** 69 | * Function used to load saved data 70 | */ 71 | read: LoadScopeFunc, 72 | 73 | /** 74 | * Function used to save data 75 | */ 76 | save: SaveScopeFunc 77 | } 78 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/ShaderUniformSet.d.ts: -------------------------------------------------------------------------------- 1 | declare class ShaderUniformSet { 2 | lock(): ShaderUniformSet; 3 | unlock(): ShaderUniformSet; 4 | setUniformValueArr(uniformSet: string, uniformName: string, value: number[]): ShaderUniformSet; 5 | setUniformValue(uniformSet: string, uniformName: string, ...value: number[]): ShaderUniformSet; 6 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/SyncedNetworkData.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Class to work with values, synchronized between server and all clients 3 | */ 4 | declare class SyncedNetworkData { 5 | /** 6 | * @returns value by key 7 | */ 8 | getInt(key: any, fallback?: number): number; 9 | /** 10 | * @returns value by key 11 | */ 12 | getLong(key: any, fallback?: number): number; 13 | /** 14 | * @returns value by key 15 | */ 16 | getFloat(key: any, fallback?: number): number; 17 | /** 18 | * @returns value by key 19 | */ 20 | getDouble(key: any, fallback?: number): number; 21 | /** 22 | * @returns value by key 23 | */ 24 | getString(key: any, fallback?: string): string; 25 | /** 26 | * @returns value by key 27 | */ 28 | getBoolean(key: any, fallback?: boolean): boolean; 29 | /** 30 | * Sets value by key 31 | */ 32 | putInt(key: any, value: number): void; 33 | /** 34 | * Sets value by key 35 | */ 36 | putLong(key: any, value: number): void; 37 | /** 38 | * Sets value by key 39 | */ 40 | putFloat(key: any, value: number): void; 41 | /** 42 | * Sets value by key 43 | */ 44 | putDouble(key: any, value: number): void; 45 | /** 46 | * Sets value by key 47 | */ 48 | putString(key: any, value: string): void; 49 | /** 50 | * Sets value by key 51 | */ 52 | putBoolean(key: any, value: boolean): void; 53 | 54 | /** 55 | * Sends changed data values 56 | */ 57 | sendChanges(): void; 58 | 59 | /** 60 | * Event that catches changes of any data values. 61 | * @param networkData - SyncedNetworkData object where the changes had happened; 62 | * @param isExternalStorage - 63 | * false, if change had happened by calling put from this object, 64 | * true, if it came by network from other connected data object. 65 | */ 66 | addOnDataChangedListener(func: (networkData: SyncedNetworkData, isExternalChange: boolean) => void): void; 67 | 68 | /** 69 | * Adds data validator to the object 70 | */ 71 | addVerifier(key: any, func: (key: any, newValue: any) => void): void; 72 | } 73 | -------------------------------------------------------------------------------- /documentation/core-engine/declarations/Texture.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Class representing texture that can be animated 3 | * @deprecated no longer supported and should not be used in new code 4 | */ 5 | declare class Texture { 6 | /** 7 | * Creates new [[Texture]] object using specified file path 8 | */ 9 | constructor(path: string); 10 | 11 | /** 12 | * Sets texture file path 13 | * @returns reference to itself to be used in sequential calls 14 | */ 15 | setTexture(path: string): Texture; 16 | 17 | /** 18 | * Specifies texture resolution. If not equal to file dimensions, the image 19 | * will be stretched to fit the resolution 20 | * @returns reference to itself to be used in sequential calls 21 | */ 22 | setResolution(w: number, h: number): Texture; 23 | 24 | /** 25 | * Makes texture animated 26 | * @param animation array of paths to the animation frames. Each frame should 27 | * be stored in a separate file 28 | * @param delay specifies each frame delay in ticks 29 | * @returns reference to itself to be used in sequential calls 30 | */ 31 | setAnimation(animation: string[], delay: number): Texture; 32 | 33 | /** 34 | * Resets animation 35 | * @returns reference to itself to be used in sequential calls 36 | */ 37 | resetAnimation(token: number): Texture; 38 | 39 | /** 40 | * @returns current animation frame 41 | */ 42 | getTexture(token: number): string; 43 | 44 | /** 45 | * @returns texture resolution after recalculating it with pixel scale 46 | */ 47 | getResolution(): { w: number, h: number }; 48 | 49 | /** 50 | * Sets pixel scale for the texture 51 | */ 52 | setPixelScale(scale: number): Texture; 53 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/Threading.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Module used to create and manipulate threads. Threads let you execute 3 | * time-consuming tasks without blocking current execution thread 4 | */ 5 | declare namespace Threading { 6 | /** 7 | * Function used to format error messages in a custom way 8 | */ 9 | type ErrorMessageFormatFunction = 10 | /** 11 | * @param error java.lang.Throwable instance or javascript exception 12 | * @param priority current thread priority 13 | */ 14 | (error: any, priority: number) => string; 15 | 16 | 17 | /** 18 | * Function used to create formatted error message with the full debug 19 | * information about exception in one of the threads. Usually called by Core 20 | * Engine 21 | * @param error java.lang.Throwable instance or javascript exception 22 | * @param name thread name used to localize errors if there are any 23 | * @param priority current thread priority 24 | * @param formatFunc function that formats the exception itself 25 | */ 26 | function formatFatalErrorMessage(error: any, name: string, priority: number, formatFunc: ErrorMessageFormatFunction): string; 27 | 28 | /** 29 | * Creates and runs new thread with specified function as a task 30 | * @param name thread name used to localize errors if there are any 31 | * @param func function that runs in the new thread. Usually it is some 32 | * time-consuming task, that is executed in the new thread to avoid blocking 33 | * user interfaces 34 | * @param priority priority of the thread (integer value). The higher 35 | * priority is, the quicker the task will be executed. Default value is 0 36 | * @param isErrorFatal if true, all errors in the thread are considered 37 | * fatal and lead to fatal error AlertDialog, formatted with *formatFunc* 38 | * @param formatFunc function that formats exceptions in the thread to 39 | * display in fatal error AlertDialog 40 | * @return java.lang.Thread instance representing created thread 41 | */ 42 | function initThread(name: string, func: () => void, priority?: number, isErrorFatal?: boolean, formatFunc?: ErrorMessageFormatFunction): java.lang.Thread; 43 | 44 | /** 45 | * Gets thread by its name 46 | * @param name name of the thread 47 | * @return java.lang.Thread instance representing the thread 48 | */ 49 | function getThread(name: string): java.lang.Thread; 50 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/Translation.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Module that can be used to localize mods 3 | * All default strings (e.g. item names, windows titles, etc.) in the mod should 4 | * be in English. Add translations to these strings using 5 | * [[Translation.addTranslation]]. For items and blocks translations are applied 6 | * automatically. For the other strings, use [[Translation.translate]] 7 | */ 8 | declare namespace Translation { 9 | /** 10 | * Adds translations for specified object in several languages 11 | * @param name default string in English or name key 12 | * @param localization object containing two-letter language codes as keys 13 | * and localized strings in the specified language as values 14 | */ 15 | function addTranslation(name: string, localization: object): void; 16 | 17 | /** 18 | * Translates string from English to current game language (if available). 19 | * Add translations via [[Translation.addTranslation]] to apply them 20 | * @param name default string in English or name key 21 | * @returns string in the current game language or input string if 22 | * translation is not available 23 | */ 24 | function translate(name: string): string; 25 | 26 | /** 27 | * @returns two-letter language code for current game language 28 | */ 29 | function getLanguage(): string; 30 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/Updatable.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Module used to create and manage Updatables. Updatables provide the proper 3 | * way to manage objects that update their state every tick. Updatables may not 4 | * be notified every tick, if there are too many, to avoid user interface 5 | * freezes 6 | */ 7 | declare namespace Updatable { 8 | /** 9 | * Adds object to updatables list 10 | * @param obj object to be added to updatables list 11 | */ 12 | function addUpdatable(obj: Updatable): any; 13 | 14 | /** 15 | * Adds object to updatables list 16 | * @param obj object to be added to updatables list 17 | */ 18 | function addLocalUpdatable(obj: Updatable): any; 19 | 20 | /** 21 | * @returns java.util.ArrayList instance containing all defined 22 | * [[Updatable]] objects 23 | */ 24 | function getAll(): java.util.ArrayList; 25 | 26 | /** 27 | * @returns current thread tick number 28 | */ 29 | function getSyncTime(): number; 30 | } 31 | 32 | /** 33 | * Updatable is an object that is notified every tick via its 34 | * [[Updatable.update]] method call 35 | */ 36 | interface Updatable { 37 | /** 38 | * Called every tick 39 | */ 40 | update: () => void; 41 | 42 | /** 43 | * Once true, the object will be removed from updatables list and will no 44 | * longer receive update calls 45 | */ 46 | remove?: boolean; 47 | 48 | /** 49 | * Any other user-defined properties 50 | */ 51 | [key: string]: any; 52 | } 53 | -------------------------------------------------------------------------------- /documentation/core-engine/declarations/Variables.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Java object of the mod, contains some useful values and methods 3 | */ 4 | declare var __mod__: Mod.ModJsAdapter; 5 | 6 | /** 7 | * Mod name 8 | */ 9 | declare var __name__: string; 10 | 11 | /** 12 | * Full path to the mod's directory, ends with "/" 13 | */ 14 | declare var __dir__: string; 15 | 16 | /** 17 | * Main mod configuration manager, settings are stored in config.json file. For 18 | * more information about config.json, see {@page Mod Configuration Files} 19 | */ 20 | declare var __config__: Config; 21 | 22 | /** 23 | * Full path to current Horizon pack directory 24 | */ 25 | declare var __packdir__: string; 26 | 27 | /** 28 | * Full path to current Inner Core modpack directory 29 | */ 30 | declare var __modpack__: ModPack.ModPackJsAdapter; 31 | -------------------------------------------------------------------------------- /documentation/core-engine/declarations/WorldRenderer.d.ts: -------------------------------------------------------------------------------- 1 | declare namespace WorldRenderer { 2 | export function getGlobalUniformSet(): ShaderUniformSet; 3 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/apparatus/api/container/ItemContainerUiHandler.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module apparatus { 4 | export module api { 5 | export module container { 6 | export class ItemContainerUiHandler extends java.lang.Object implements innercore.api.mod.ui.container.UiAbstractContainer { 7 | static class: java.lang.Class; 8 | constructor(container: ItemContainer); 9 | onWindowClosed(): void; 10 | getWindow(): innercore.api.mod.ui.window.IWindow; 11 | openAs(window: innercore.api.mod.ui.window.IWindow): void; 12 | close(): void; 13 | getParent(): ItemContainer; 14 | addElementInstance(element: innercore.api.mod.ui.elements.UIElement, name: string): void; 15 | getElement(elementName: string): Nullable; 16 | getSlotVisualImpl(name: string): innercore.api.mod.ui.container.UiVisualSlotImpl; 17 | getBinding(elementName: string, bindingName: string): T; 18 | setBinding(elementName: string, bindingName: string, value: T): void; 19 | handleBindingDirty(elementName: string, bindingName: string): void; 20 | applyAllBindingsFromMap(): void; 21 | setBindingByComposedName(name: string, value: PrimitiveTypes): void; 22 | receiveBindingsFromServer(bindings: org.json.JSONObject): void; 23 | handleInventoryToSlotTransaction(inventorySlot: number, slot: string, amount: number): void; 24 | handleSlotToSlotTransaction(from: string, to: string, amount: number): void; 25 | handleSlotToInventoryTransaction(slot: string, amount: number): void; 26 | } 27 | } 28 | } 29 | } 30 | } 31 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/ExecutionDirectory.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export class ExecutionDirectory extends globalThis.java.lang.Object { 6 | static class: globalThis.java.lang.Class; 7 | readonly directory: globalThis.java.io.File; 8 | readonly isPackDriven: boolean; 9 | constructor(dir: globalThis.java.io.File, isPackDriven: boolean); 10 | addLibraryDirectory(lib: library.LibraryDirectory): void; 11 | getLibByName(name: string): Nullable; 12 | addJavaDirectory(directory: java.JavaDirectory): void; 13 | build(context: android.content.Context, logger: runtime.logger.EventLogger): LaunchSequence; 14 | clear(): void; 15 | } 16 | } 17 | } 18 | } 19 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/LaunchSequence.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export class LaunchSequence extends globalThis.java.lang.Object { 6 | static class: globalThis.java.lang.Class; 7 | constructor(dir: ExecutionDirectory, libraries: globalThis.java.util.List, javaLibraries: globalThis.java.util.List); 8 | buildSequence(logger: runtime.logger.EventLogger): void; 9 | loadAll(logger: runtime.logger.EventLogger): void; 10 | getAllLibraries(): globalThis.java.util.List; 11 | } 12 | } 13 | } 14 | } 15 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/ModContext.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export class ModContext extends globalThis.java.lang.Object { 6 | static class: globalThis.java.lang.Class; 7 | readonly context: android.content.Context; 8 | readonly resourceManager: resource.ResourceManager; 9 | readonly executionDirectory: ExecutionDirectory; 10 | getActivityContext(): android.content.Context; 11 | getResourceManager(): resource.ResourceManager; 12 | getExecutionDirectory(): ExecutionDirectory; 13 | getActiveMods(): globalThis.java.util.List; 14 | getDisabledMods(): globalThis.java.util.List; 15 | getEventLogger(): runtime.logger.EventLogger; 16 | clearContext(): void; 17 | clearModsAndContext(): void; 18 | addMod(mod: mod.Mod): void; 19 | addMods(mods: globalThis.java.util.Collection): void; 20 | injectAll(): void; 21 | buildAll(): void; 22 | initializeAll(): void; 23 | launchAll(): void; 24 | constructor(context: android.content.Context, resman: resource.ResourceManager, exdir: ExecutionDirectory); 25 | addEventReceiver(event: string, receiver: ModContext.EventReceiver | ((...mods: mod.Mod[]) => void)): void; 26 | } 27 | export module ModContext { 28 | export class EventReceiver extends globalThis.java.lang.Object { 29 | static class: globalThis.java.lang.Class; 30 | onEvent(...mods: mod.Mod[]): void; 31 | constructor(); 32 | constructor(impl: { 33 | onEvent: (...mods: mod.Mod[]) => void; 34 | }); 35 | } 36 | } 37 | } 38 | } 39 | } 40 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/configuration/Configuration.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module configuration { 6 | export abstract class Configuration extends globalThis.java.lang.Object { 7 | static class: globalThis.java.lang.Class; 8 | abstract refresh(): void; 9 | abstract get(key: string, clazz: globalThis.java.lang.Class): T; 10 | abstract get(key: string): any; 11 | abstract set(key: string, value: any): boolean; 12 | abstract delete(key: string): any; 13 | abstract isContainer(key: string): boolean; 14 | abstract getChild(key: string): Configuration; 15 | abstract isReadOnly(): boolean; 16 | abstract save(): void; 17 | abstract load(): void; 18 | getInt(key: string): number; 19 | getFloat(key: string): number; 20 | getDouble(key: string): number; 21 | getLong(key: string): number; 22 | getString(key: string): Nullable; 23 | getBoolean(key: string): boolean; 24 | getArray(key: string): Nullable>; 25 | checkAndRestore(json: org.json.JSONObject): void; 26 | checkAndRestore(json: string): void; 27 | } 28 | } 29 | } 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/java/JavaDirectory.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module java { 6 | export class JavaDirectory extends globalThis.java.lang.Object { 7 | readonly mod: mod.Mod; 8 | readonly directory: globalThis.java.io.File; 9 | readonly manifest: JavaLibraryManifest; 10 | constructor(mod: mod.Mod, dir: globalThis.java.io.File); 11 | getName(): string; 12 | getSubDirectory(path: string, createIfRequired: boolean): globalThis.java.io.File; 13 | getDestinationDirectory(): globalThis.java.io.File; 14 | getJarDirectory(): globalThis.java.io.File; 15 | getBuildDexFile(): globalThis.java.io.File; 16 | getCompiledDexFile(): globalThis.java.io.File; 17 | getSourceDirectories(): string; 18 | getLibraryPaths(bootPaths: globalThis.java.util.List): string; 19 | getArguments(): string[]; 20 | isVerboseRequired(): boolean; 21 | getAllSourceFiles(): string[]; 22 | getBootClassNames(): globalThis.java.util.List; 23 | addToExecutionDirectory(exdir: ExecutionDirectory, context: android.content.Context): JavaLibrary; 24 | compileToClassesFile(context: android.content.Context): void; 25 | getCompiledClassesFile(): globalThis.java.io.File; 26 | getCompiledClassesFiles(): globalThis.java.util.List; 27 | isInDevMode(): boolean; 28 | setPreCompiled(prec: boolean): void; 29 | isPreCompiled(): boolean; 30 | } 31 | } 32 | } 33 | } 34 | } 35 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/java/JavaLibrary.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module java { 6 | export class JavaLibrary extends globalThis.java.lang.Object { 7 | static class: globalThis.java.lang.Class; 8 | constructor(dir: JavaDirectory, dexFile: globalThis.java.io.File); 9 | constructor(dir: JavaDirectory, dexFiles: globalThis.java.util.List); 10 | getDirectory(): JavaDirectory; 11 | getDexFiles(): globalThis.java.util.List; 12 | isInitialized(): boolean; 13 | initialize(): void; 14 | } 15 | } 16 | } 17 | } 18 | } 19 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/java/JavaLibraryManifest.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module java { 6 | export class JavaLibraryManifest extends globalThis.java.lang.Object { 7 | static class: globalThis.java.lang.Class; 8 | readonly arguments: string[]; 9 | readonly verbose: boolean; 10 | readonly sourceDirs: globalThis.java.util.List; 11 | readonly libraryDirs: globalThis.java.util.List; 12 | readonly libraryPaths: globalThis.java.util.List; 13 | readonly bootClasses: globalThis.java.util.List; 14 | constructor(file: globalThis.java.io.File); 15 | } 16 | } 17 | } 18 | } 19 | } 20 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/library/Library.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module library { 6 | export class Library extends globalThis.java.lang.Object { 7 | static class: globalThis.java.lang.Class; 8 | static load(path: string): Library; 9 | getResult(): number; 10 | refreshModuleList(): void; 11 | getModules(): globalThis.java.util.List; 12 | } 13 | } 14 | } 15 | } 16 | } 17 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/library/LibraryDirectory.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module library { 6 | export class LibraryDirectory extends globalThis.java.lang.Object { 7 | static class: globalThis.java.lang.Class; 8 | readonly directory: globalThis.java.io.File; 9 | readonly manifest: LibraryManifest; 10 | readonly makeFile: LibraryMakeFile; 11 | readonly soFile: globalThis.java.io.File; 12 | constructor(mod: mod.Mod, directory: globalThis.java.io.File); 13 | constructor(directory: globalThis.java.io.File); 14 | isInDevMode(): boolean; 15 | isPreCompiled(): boolean; 16 | isSharedLibrary(): boolean; 17 | getVersionCode(): number; 18 | getName(): string; 19 | getSoFileName(): string; 20 | getIncludeDirs(): globalThis.java.util.List; 21 | getDependencyNames(): globalThis.java.util.List; 22 | getExecutableFile(): globalThis.java.io.File; 23 | getLibrary(): Library; 24 | compileToTargetFile(directory: ExecutionDirectory, context: android.content.Context, target: globalThis.java.io.File): void; 25 | setPreCompiled(pre: boolean): void; 26 | addToExecutionDirectory(dir: ExecutionDirectory, context: android.content.Context, target: globalThis.java.io.File): void; 27 | loadExecutableFile(): void; 28 | hashCode(): number; 29 | } 30 | } 31 | } 32 | } 33 | } 34 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/library/LibraryMakeFile.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module library { 6 | export class LibraryMakeFile extends globalThis.java.lang.Object { 7 | static class: globalThis.java.lang.Class; 8 | constructor(file: globalThis.java.io.File); 9 | getCppFlags(): string; 10 | getFiles(): globalThis.java.util.List; 11 | } 12 | } 13 | } 14 | } 15 | } 16 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/library/LibraryManifest.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module library { 6 | export class LibraryManifest extends globalThis.java.lang.Object { 7 | static class: globalThis.java.lang.Class; 8 | constructor(file: globalThis.java.io.File); 9 | getFile(): globalThis.java.io.File; 10 | getName(): string; 11 | getSoName(): string; 12 | getVersion(): number; 13 | getDependencies(): globalThis.java.util.List; 14 | getInclude(): globalThis.java.util.List; 15 | isSharedLibrary(): boolean; 16 | isShared(): boolean; 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/mod/ModGraphics.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module mod { 6 | export class ModGraphics extends globalThis.java.lang.Object { 7 | static class: globalThis.java.lang.Class; 8 | constructor(); 9 | constructor(dir: globalThis.java.io.File); 10 | getNamedGroup(name: string): globalThis.java.util.HashMap; 11 | getGroup(name: string): globalThis.java.util.Collection; 12 | getAllBitmaps(): globalThis.java.util.List; 13 | } 14 | } 15 | } 16 | } 17 | } 18 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/mod/ModInstance.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module mod { 6 | export class ModInstance extends globalThis.java.lang.Object { 7 | static class: globalThis.java.lang.Class; 8 | constructor(module: Module); 9 | getModule(): Module; 10 | } 11 | } 12 | } 13 | } 14 | } 15 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/mod/ModManifest.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module mod { 6 | export class ModManifest extends globalThis.java.lang.Object { 7 | static class: globalThis.java.lang.Class; 8 | constructor(file: globalThis.java.io.File); 9 | getParentDirectory(): globalThis.java.io.File; 10 | getDirectories(): globalThis.java.util.List; 11 | getModules(): globalThis.java.util.List; 12 | getMainModule(): ModManifest.Module; 13 | getName(): string; 14 | } 15 | export module ModManifest { 16 | export class DirectoryType extends globalThis.java.lang.Object { 17 | static class: globalThis.java.lang.Class; 18 | static readonly LIBRARY: DirectoryType; 19 | static readonly RESOURCE: DirectoryType; 20 | static readonly SUBMOD: DirectoryType; 21 | static readonly JAVA: DirectoryType; 22 | static byName(name: string): DirectoryType; 23 | } 24 | export class Directory extends globalThis.java.lang.Object { 25 | static class: globalThis.java.lang.Class; 26 | readonly file: globalThis.java.io.File; 27 | readonly type: DirectoryType; 28 | constructor(file: globalThis.java.io.File, type: DirectoryType); 29 | constructor(json: org.json.JSONObject); 30 | asModLocation(): repo.location.ModLocation; 31 | } 32 | export class Module extends globalThis.java.lang.Object { 33 | static class: globalThis.java.lang.Class; 34 | readonly nameId: string; 35 | readonly name: string; 36 | readonly author: string; 37 | readonly description: string; 38 | readonly versionName: string; 39 | readonly versionCode: number; 40 | constructor(nameId: string, json: org.json.JSONObject); 41 | getDisplayedDescription(): string; 42 | } 43 | } 44 | } 45 | } 46 | } 47 | } 48 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/mod/Module.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module mod { 6 | export class Module extends globalThis.java.lang.Object { 7 | static class: globalThis.java.lang.Class; 8 | static getInstance(handle: number): Module; 9 | getParent(): Module; 10 | getNameID(): string; 11 | getType(): string; 12 | isInitialized(): boolean; 13 | onEvent(event: string): void; 14 | isMod(): boolean; 15 | } 16 | } 17 | } 18 | } 19 | } 20 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/repo/location/ModLocation.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module repo { 6 | export module location { 7 | export class ModLocation extends globalThis.java.lang.Object { 8 | static class: globalThis.java.lang.Class; 9 | initializeInLocalStorage(temporaryStorage: storage.TemporaryStorage, logger: runtime.logger.EventLogger): globalThis.java.io.File; 10 | constructor(); 11 | constructor(impl: { 12 | initializeInLocalStorage: (temporaryStorage: storage.TemporaryStorage, logger: runtime.logger.EventLogger) => globalThis.java.io.File; 13 | }); 14 | } 15 | } 16 | } 17 | } 18 | } 19 | } 20 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/repo/storage/TemporaryStorage.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module repo { 6 | export module storage { 7 | export class TemporaryStorage extends globalThis.java.lang.Object { 8 | static class: globalThis.java.lang.Class; 9 | constructor(dir: globalThis.java.io.File); 10 | allocate(key: string): globalThis.java.io.File; 11 | recycle(key: string): boolean; 12 | } 13 | } 14 | } 15 | } 16 | } 17 | } 18 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/resource/ResourceManager.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module resource { 6 | export class ResourceManager extends globalThis.java.lang.Object { 7 | static class: globalThis.java.lang.Class; 8 | readonly context: android.content.Context; 9 | readonly runtimeDir: runtime.RuntimeResourceDirectory; 10 | constructor(ctx: android.content.Context); 11 | getAssets(): android.content.res.AssetManager; 12 | addResourcePrefixes(...prefixes: string[]): void; 13 | getResourceOverridePrefixes(): globalThis.java.util.List; 14 | addResourceProcessor(processor: processor.ResourceProcessor): void; 15 | addRuntimeResourceHandler(handler: runtime.RuntimeResourceHandler): void; 16 | addResourceDirectory(directory: directory.ResourceDirectory): void; 17 | clear(): void; 18 | getProcessedResources(resources: globalThis.java.util.List): globalThis.java.util.List; 19 | getResource(path: string): globalThis.java.util.List; 20 | addResourcePath(path: string): void; 21 | deployAllOverrides(): void; 22 | } 23 | } 24 | } 25 | } 26 | } 27 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/resource/ResourceOverride.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module resource { 6 | export class ResourceOverride extends globalThis.java.lang.Object { 7 | static class: globalThis.java.lang.Class; 8 | readonly path: string; 9 | readonly override: string; 10 | constructor(path: string, override: string); 11 | constructor(path: string, override: globalThis.java.io.File); 12 | constructor(resource: directory.Resource, override: string); 13 | constructor(resource: directory.Resource, override: globalThis.java.io.File); 14 | constructor(resource: directory.Resource); 15 | isActive(): boolean; 16 | deploy(): boolean; 17 | deploy(prefixes: globalThis.java.util.List): boolean; 18 | deploy(prefixes: string[]): boolean; 19 | remove(): boolean; 20 | } 21 | } 22 | } 23 | } 24 | } 25 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/resource/directory/Resource.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module resource { 6 | export module directory { 7 | export class Resource extends globalThis.java.lang.Object { 8 | static class: globalThis.java.lang.Class; 9 | static readonly DEFAULT_RESOURCE_PACK = "resource_packs/vanilla/"; 10 | static readonly RESOURCE_INDEX_SEPARATOR = "_"; 11 | readonly directory: ResourceDirectory; 12 | readonly file: globalThis.java.io.File; 13 | constructor(dir: ResourceDirectory, file: globalThis.java.io.File, path: string); 14 | constructor(dir: ResourceDirectory, file: globalThis.java.io.File); 15 | getPath(): string; 16 | getPathWithIndex(): string; 17 | getRealPath(): string; 18 | getPathWithoutExtension(): string; 19 | getAtlasPath(): string; 20 | getName(): string; 21 | getNameWithoutExtension(): string; 22 | getNameWithIndex(): string; 23 | getRealName(): string; 24 | hasIndex(): boolean; 25 | getIndex(): number; 26 | getExtension(): string; 27 | getMeta(): ResourceMeta; 28 | getLink(path: string): Resource; 29 | addOverrides(overrides: globalThis.java.util.List): void; 30 | } 31 | } 32 | } 33 | } 34 | } 35 | } 36 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/resource/directory/ResourceDirectory.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module resource { 6 | export module directory { 7 | export class ResourceDirectory extends globalThis.java.lang.Object { 8 | static class: globalThis.java.lang.Class; 9 | readonly manager: ResourceManager; 10 | readonly runtimeDir: runtime.RuntimeResourceDirectory; 11 | readonly mod: mod.Mod; 12 | readonly directory: globalThis.java.io.File; 13 | constructor(manager: ResourceManager, mod: mod.Mod, directory: globalThis.java.io.File); 14 | constructor(manager: ResourceManager, directory: globalThis.java.io.File); 15 | equals(obj: globalThis.java.lang.Object): boolean; 16 | initialize(): void; 17 | getResourceName(file: globalThis.java.io.File): string; 18 | getResource(path: string): globalThis.java.util.List; 19 | } 20 | } 21 | } 22 | } 23 | } 24 | } 25 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/resource/directory/ResourceMeta.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module resource { 6 | export module directory { 7 | export class ResourceMeta extends globalThis.java.lang.Object { 8 | static class: globalThis.java.lang.Class; 9 | readonly file: globalThis.java.io.File; 10 | constructor(file: globalThis.java.io.File); 11 | } 12 | } 13 | } 14 | } 15 | } 16 | } 17 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/resource/processor/ResourceProcessor.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module resource { 6 | export module processor { 7 | export class ResourceProcessor extends globalThis.java.lang.Object { 8 | static class: globalThis.java.lang.Class; 9 | initialize(manager: ResourceManager): void; 10 | process(resource: directory.Resource, resources: globalThis.java.util.Collection): void; 11 | constructor(); 12 | constructor(impl: { 13 | initialize: (manager: ResourceManager) => void; 14 | process: (resource: directory.Resource, resources: globalThis.java.util.Collection) => void; 15 | }); 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/resource/runtime/RuntimeResource.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module resource { 6 | export module runtime { 7 | export class RuntimeResource extends globalThis.java.lang.Object { 8 | static class: globalThis.java.lang.Class; 9 | constructor(directory: RuntimeResourceDirectory, override: ResourceOverride, name: string); 10 | getOverride(): ResourceOverride; 11 | getDirectory(): RuntimeResourceDirectory; 12 | getName(): string; 13 | getFile(): globalThis.java.io.File; 14 | } 15 | } 16 | } 17 | } 18 | } 19 | } 20 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/resource/runtime/RuntimeResourceDirectory.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module resource { 6 | export module runtime { 7 | export class RuntimeResourceDirectory extends globalThis.java.lang.Object { 8 | static class: globalThis.java.lang.Class; 9 | readonly resourceManager: ResourceManager; 10 | readonly directory: globalThis.java.io.File; 11 | constructor(manager: ResourceManager, dir: globalThis.java.io.File); 12 | clear(): void; 13 | addHandler(handler: RuntimeResourceHandler): void; 14 | handleAll(): void; 15 | } 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/modloader/resource/runtime/RuntimeResourceHandler.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module modloader { 5 | export module resource { 6 | export module runtime { 7 | export class RuntimeResourceHandler extends globalThis.java.lang.Object { 8 | static class: globalThis.java.lang.Class; 9 | getResourceName(): string; 10 | getResourcePath(): string; 11 | handle(res: RuntimeResource): void; 12 | constructor(); 13 | constructor(impl: { 14 | getResourceName: () => string; 15 | getResourcePath: () => string; 16 | handle: (res: RuntimeResource) => void; 17 | }); 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } 24 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/horizon/runtime/logger/EventLogger.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module horizon { 4 | export module runtime { 5 | export module logger { 6 | export class EventLogger extends java.lang.Object { 7 | static class: java.lang.Class; 8 | getMessages(filter: EventLogger.Filter): java.util.List; 9 | constructor(); 10 | section(section: string): void; 11 | debug(tag: string, message: string): void; 12 | info(tag: string, message: string): void; 13 | fault(tag: string, message: string, error: java.lang.Throwable): void; 14 | fault(tag: string, message: string): void; 15 | getStream(type: EventLogger.MessageType, tag: string): java.io.OutputStream; 16 | clear(): void; 17 | } 18 | export module EventLogger { 19 | export class MessageType extends java.lang.Object { 20 | static class: java.lang.Class; 21 | static readonly DEBUG: MessageType; 22 | static readonly INFO: MessageType; 23 | static readonly FAULT: MessageType; 24 | static readonly EXCEPTION: MessageType; 25 | static readonly STACKTRACE: MessageType; 26 | } 27 | export class Message extends java.lang.Object { 28 | static class: java.lang.Class; 29 | readonly type: java.lang.Object; 30 | readonly tag: string; 31 | readonly message: string; 32 | readonly section: string; 33 | } 34 | export class Filter extends java.lang.Object { 35 | static class: java.lang.Class; 36 | filter(message: Message): boolean; 37 | constructor(); 38 | constructor(impl: { 39 | filter: (message: Message) => boolean 40 | }); 41 | } 42 | } 43 | } 44 | } 45 | } 46 | } 47 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/recipes/workbench/RecipeEntry.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module recipes { 7 | export module workbench { 8 | export class RecipeEntry extends java.lang.Object { 9 | static class: java.lang.Class; 10 | static readonly noentry: RecipeEntry; 11 | readonly data: number; 12 | readonly id: number; 13 | constructor(id: number, data: number); 14 | constructor(slot: ui.container.Slot); 15 | getMask(): java.lang.Character; 16 | getCodeByItem(id: number, data: number): number; 17 | getCode(): number; 18 | isMatching(slot: ui.container.AbstractSlot): boolean; 19 | isMatching(entry: RecipeEntry): boolean; 20 | equals(obj: java.lang.Object): boolean; 21 | hashCode(): number; 22 | } 23 | } 24 | } 25 | } 26 | } 27 | } 28 | } 29 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/recipes/workbench/WorkbenchField.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module recipes { 7 | export module workbench { 8 | export class WorkbenchField extends java.lang.Object { 9 | static class: java.lang.Class; 10 | constructor(); 11 | constructor(impl: { 12 | asScriptableField: () => ui.container.AbstractSlot[], 13 | getFieldSlot: (i: number) => ui.container.AbstractSlot; 14 | }); 15 | asScriptableField(): ui.container.AbstractSlot[]; 16 | getFieldSlot(i: number): ui.container.AbstractSlot; 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } 24 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/recipes/workbench/WorkbenchFieldAPI.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module recipes { 7 | export module workbench { 8 | export class WorkbenchFieldAPI extends java.lang.Object { 9 | static class: java.lang.Class; 10 | readonly container: WorkbenchField; 11 | constructor(field: WorkbenchField); 12 | getFieldSlot(i: number): ui.container.AbstractSlot; 13 | decreaseFieldSlot(i: number): void; 14 | prevent(): void; 15 | isPrevented(): boolean; 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/ContentProvider.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export class ContentProvider extends java.lang.Object { 8 | static class: java.lang.Class; 9 | content: window.WindowContent; 10 | drawing: object; 11 | drawingWatcher: util.ScriptableWatcher; 12 | elementMap: java.util.HashMap; 13 | elements: object; 14 | window: window.UIWindow; 15 | constructor(window: window.UIWindow); 16 | setContentObject(content: window.WindowContent): void; 17 | setupElements(): void; 18 | refreshElements(): void; 19 | setupDrawing(): void; 20 | refreshDrawing(): void; 21 | invalidateAllContent(): void; 22 | toString(): string; 23 | } 24 | } 25 | } 26 | } 27 | } 28 | } 29 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/GuiRenderMesh.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export class GuiRenderMesh extends java.lang.Object { 8 | static class: java.lang.Class; 9 | rx: number; 10 | ry: number; 11 | rz: number; 12 | x: number; 13 | y: number; 14 | z: number; 15 | draw(gl: javax.microedition.khronos.opengles.GL10): void; 16 | setVertices(vertices: number[]): void; 17 | setIndices(indices: number[]): void; 18 | setTextureCoordinates(textureCoords: number[]): void; 19 | setColors(colors: number[]): void; 20 | loadBitmap(bitmap: android.graphics.Bitmap): void; 21 | } 22 | } 23 | } 24 | } 25 | } 26 | } 27 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/IBackgroundProvider.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export class IBackgroundProvider extends java.lang.Object { 8 | static class: java.lang.Class; 9 | constructor(); 10 | constructor(impl: { 11 | addDrawing(idrawing: background.IDrawing): void; 12 | clearAll(): void; 13 | prepareCache(): void; 14 | releaseCache(): void; 15 | setBackgroundColor(color: number): void; 16 | }); 17 | addDrawing(idrawing: background.IDrawing): void; 18 | clearAll(): void; 19 | prepareCache(): void; 20 | releaseCache(): void; 21 | setBackgroundColor(color: number): void; 22 | } 23 | } 24 | } 25 | } 26 | } 27 | } 28 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/IElementProvider.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export class IElementProvider extends java.lang.Object { 8 | static class: java.lang.Class; 9 | constructor(); 10 | constructor(impl: { 11 | addOrRefreshElement(element: elements.UIElement): void; 12 | getStyleFor(element: elements.UIElement): types.UIStyle; 13 | invalidateAll(): void; 14 | releaseAll(): void; 15 | removeElement(element: elements.UIElement): void; 16 | resetAll(): void; 17 | runCachePreparation(): void; 18 | setBackgroundProvider(bgprovider: IBackgroundProvider): void; 19 | setWindowStyle(style: types.UIStyle): void; 20 | }); 21 | addOrRefreshElement(element: elements.UIElement): void; 22 | getStyleFor(element: elements.UIElement): types.UIStyle; 23 | invalidateAll(): void; 24 | releaseAll(): void; 25 | removeElement(element: elements.UIElement): void; 26 | resetAll(): void; 27 | runCachePreparation(): void; 28 | setBackgroundProvider(bgprovider: IBackgroundProvider): void; 29 | setWindowStyle(style: types.UIStyle): void; 30 | } 31 | export interface IElementProvider { 32 | addOrRefreshElement(element: elements.UIElement): void; 33 | getStyleFor(element: elements.UIElement): types.UIStyle; 34 | invalidateAll(): void; 35 | releaseAll(): void; 36 | removeElement(element: elements.UIElement): void; 37 | resetAll(): void; 38 | runCachePreparation(): void; 39 | setBackgroundProvider(bgprovider: IBackgroundProvider): void; 40 | setWindowStyle(style: types.UIStyle): void; 41 | } 42 | } 43 | } 44 | } 45 | } 46 | } 47 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/ItemModelCacheManager.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export class ItemModelCacheManager extends java.lang.Object { 8 | static class: java.lang.Class; 9 | static getSingleton(): ItemModelCacheManager; 10 | getCacheGroupDirectory(group: string): java.io.File; 11 | getCachePath(group: string, name: string): java.io.File; 12 | getCurrentCacheGroup(): string; 13 | setCurrentCacheGroup(groupName: string, lock: string): void; 14 | } 15 | } 16 | } 17 | } 18 | } 19 | } 20 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/TextureSource.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export class TextureSource extends java.lang.Object { 8 | static class: java.lang.Class; 9 | loadAllStandartAssets(): void; 10 | put(name: string, bmp: android.graphics.Bitmap): void; 11 | get(name: string): android.graphics.Bitmap; 12 | getSafe(name: string): android.graphics.Bitmap; 13 | loadFile(file: java.io.File, namePrefix: string): void; 14 | loadAsset(name: string): void; 15 | loadDirectory(dir: java.io.File): void; 16 | loadDirectory(dir: java.io.File, namePrefix: string): void; 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/background/DrawColor.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module background { 8 | export interface ColorDrawingDescription { 9 | type: "background", 10 | color?: number, 11 | mode?: number, 12 | colorMode?: number 13 | } 14 | export class DrawColor extends java.lang.Object implements IDrawing { 15 | static class: java.lang.Class; 16 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 17 | onSetup(scriptable: ColorDrawingDescription, style: types.UIStyle): void; 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } 24 | } 25 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/background/DrawCustom.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module background { 8 | export interface CustomDrawingDescription { 9 | type: "custom", 10 | onDraw?: (canvas: android.graphics.Canvas, scale: number) => void; 11 | } 12 | export class DrawCustom extends java.lang.Object implements IDrawing { 13 | static class: java.lang.Class; 14 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 15 | onSetup(scriptable: CustomDrawingDescription, style: types.UIStyle): void; 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/background/DrawFrame.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module background { 8 | export interface FrameDrawingDescription { 9 | type: "frame", 10 | bitmap?: string, 11 | sides?: boolean[], 12 | x?: number, 13 | y?: number, 14 | scale?: number, 15 | width?: number, height?: number, 16 | color?: number, 17 | bg?: number 18 | } 19 | export class DrawFrame extends java.lang.Object implements IDrawing { 20 | static class: java.lang.Class; 21 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 22 | onSetup(scriptable: FrameDrawingDescription, style: types.UIStyle): void; 23 | } 24 | } 25 | } 26 | } 27 | } 28 | } 29 | } 30 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/background/DrawImage.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module background { 8 | export interface ImageDrawingDescription { 9 | type: "bitmap", 10 | x?: number, y?: number, 11 | width?: number, 12 | height?: number, 13 | scale?: number, 14 | bitmap?: string 15 | } 16 | export class DrawImage extends java.lang.Object implements IDrawing { 17 | static class: java.lang.Class; 18 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 19 | onSetup(scriptable: ImageDrawingDescription, style: types.UIStyle): void; 20 | } 21 | } 22 | } 23 | } 24 | } 25 | } 26 | } 27 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/background/DrawLine.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module background { 8 | export interface LineDrawingDescription { 9 | type: "line", 10 | x1?: number, y1?: number, x2?: number, y2?: number, 11 | color?: number, width?: number 12 | } 13 | export class DrawLine extends java.lang.Object implements IDrawing { 14 | static class: java.lang.Class; 15 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 16 | onSetup(scriptable: LineDrawingDescription, style: types.UIStyle): void; 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } 24 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/background/DrawText.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module background { 8 | export interface TextDrawingDescription { 9 | type: "text", 10 | x?: number, y?: number, 11 | text?: string, 12 | font?: types.FontDescription 13 | } 14 | export class DrawText extends java.lang.Object implements IDrawing { 15 | static class: java.lang.Class; 16 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 17 | onSetup(scriptable: TextDrawingDescription, style: types.UIStyle): void; 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } 24 | } 25 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/background/DrawingFactory.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module background { 8 | export type StandardDrawingTypes = 9 | ColorDrawingDescription | 10 | CustomDrawingDescription | 11 | FrameDrawingDescription | 12 | ImageDrawingDescription | 13 | LineDrawingDescription | 14 | TextDrawingDescription; 15 | export class DrawingFactory extends java.lang.Object { 16 | static class: java.lang.Class; 17 | static put(name: string, element: java.lang.Class): void; 18 | static construct(desc: StandardDrawingTypes, style: types.UIStyle): Nullable; 19 | } 20 | } 21 | } 22 | } 23 | } 24 | } 25 | } 26 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/background/IDrawing.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module background { 8 | export class IDrawing extends java.lang.Object { 9 | static class: java.lang.Class; 10 | constructor(); 11 | constructor(impl: { 12 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 13 | onSetup(scriptable: object, style: types.UIStyle): void; 14 | }); 15 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 16 | onSetup(scriptable: object, style: types.UIStyle): void; 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } 24 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/container/AbstractSlot.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module container { 8 | export class AbstractSlot extends java.lang.Object { 9 | static class: java.lang.Class; 10 | constructor(); 11 | constructor(impl: { 12 | getId(): number; getCount(): number; getData(): number; 13 | getExtra(): Nullable; 14 | set(id: number, count: number, data: number, extra: Nullable): void; 15 | validate(): void; 16 | }) 17 | getId(): number; getCount(): number; getData(): number; 18 | getExtra(): Nullable; 19 | set(id: number, count: number, data: number, extra: Nullable): void; 20 | validate(): void; 21 | } 22 | } 23 | } 24 | } 25 | } 26 | } 27 | } 28 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/container/ScriptableUiVisualSlotImpl.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module container { 8 | export class ScriptableUiVisualSlotImpl extends java.lang.Object implements UiVisualSlotImpl { 9 | static class: java.lang.Class; 10 | constructor(scriptable: ItemInstance); 11 | getId(): number; 12 | getCount(): number; 13 | getData(): number; 14 | getExtra(): Nullable; 15 | } 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/container/Slot.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module container { 8 | export class Slot extends java.lang.Object implements AbstractSlot { 9 | static class: java.lang.Class; 10 | id: number; 11 | count: number; 12 | data: number; 13 | extra: Nullable; 14 | getClassName(): "slot"; 15 | constructor(id: number, count: number, data: number); 16 | constructor(id: number, count: number, data: number, extra: Nullable); 17 | constructor(); 18 | constructor(parent: ItemInstance); 19 | set(id: number, count: number, data: number): void; 20 | set(id: number, count: number, data: number, extra: Nullable): void; 21 | put(name: string, prop: any): void; 22 | getInt(name: string): number; 23 | validate(): void; 24 | /** @deprecated */ drop(x: number, y: number, z: number): void; 25 | getTarget(): ItemInstance; 26 | getId(): number; getCount(): number; getData(): number; 27 | getExtraValue(): number; 28 | getExtra(): Nullable; 29 | save(): Slot; 30 | } 31 | } 32 | } 33 | } 34 | } 35 | } 36 | } 37 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/container/UiVisualSlotImpl.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module container { 8 | export class UiVisualSlotImpl extends java.lang.Object { 9 | static class: java.lang.Class; 10 | constructor(); 11 | constructor(impl: { 12 | getId(): number; getCount(): number; getData(): number; 13 | getExtra(): Nullable; 14 | }); 15 | getId(): number; getCount(): number; getData(): number; 16 | getExtra(): Nullable; 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } 24 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/elements/ElementFactory.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module elements { 8 | export type StandardElementTypes = 9 | ButtonElementDescription | 10 | CustomElementDescription | 11 | FPSTextElementDescription | 12 | FrameElementDescription | 13 | ImageElementDescription | 14 | InvSlotElementDescription | 15 | ScaleElementDescription | 16 | ScrollElementDescription | 17 | SlotElementDescription | 18 | SwitchElementDescription | 19 | TabElementDescription | 20 | TextElementDescription; 21 | export class ElementFactory extends java.lang.Object { 22 | static class: java.lang.Class; 23 | static put(name: string, element: java.lang.Class): void; 24 | static construct(type: string, win: window.UIWindow, descr: StandardElementTypes | T): Nullable; 25 | static construct(win: window.UIWindow, descr: StandardElementTypes | T): Nullable; 26 | } 27 | } 28 | } 29 | } 30 | } 31 | } 32 | } 33 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/elements/UIButtonElement.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module elements { 8 | export interface ButtonElementDescription extends BasicElementDescription { 9 | type: "button" | "closeButton" | "close_button", 10 | scale?: number, 11 | bitmap?: BitmapTypes, 12 | bitmap2?: BitmapTypes 13 | } 14 | export class UIButtonElement extends UIElement { 15 | static class: java.lang.Class; 16 | constructor(win: window.UIWindow, desc: ButtonElementDescription); 17 | onSetup(desc: ButtonElementDescription): void; 18 | onDraw(cvs: android.graphics.Canvas, scale: number): void; 19 | onBindingUpdated(name: string, value: T): void; 20 | } 21 | } 22 | } 23 | } 24 | } 25 | } 26 | } 27 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/elements/UICloseButtonElement.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module elements { 8 | export class UICloseButtonElement extends UIButtonElement { 9 | static class: java.lang.Class; 10 | constructor(window: window.UIWindow, desc: ButtonElementDescription); 11 | onTouchEvent(event: types.TouchEvent): void; 12 | } 13 | } 14 | } 15 | } 16 | } 17 | } 18 | } 19 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/elements/UICustomElement.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module elements { 8 | export interface CustomElementDescription extends BasicElementDescription { 9 | type: "custom", 10 | custom?: { 11 | onSetup?: (element: UICustomElement) => void, 12 | onDraw?: (element: UICustomElement, cvs: android.graphics.Canvas, scale: number) => void, 13 | onTouchReleased?: (element: UICustomElement) => void, 14 | onBindingUpdated?: (element: UICustomElement, name: string, val: T) => void, 15 | onReset?: (element: UICustomElement) => void, 16 | onRelease?: (element: UICustomElement) => void, 17 | onContainerInit?: (element: UICustomElement, container: container.UiAbstractContainer, elementName: string) => void 18 | } 19 | } 20 | export class UICustomElement extends UIElement { 21 | static class: java.lang.Class; 22 | constructor(win: window.UIWindow, desc: CustomElementDescription); 23 | getScope(): object; 24 | onSetup(desc: CustomElementDescription): void; 25 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 26 | onTouchReleased(event: types.TouchEvent): void; 27 | onBindingUpdated(name: string, val: T): void; 28 | onReset(): void; 29 | onRelease(): void; 30 | setupInitialBindings(container: container.UiAbstractContainer, elementName: string): void; 31 | } 32 | } 33 | } 34 | } 35 | } 36 | } 37 | } 38 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/elements/UIElementCleaner.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module elements { 8 | export class UIElementCleaner extends java.lang.Object { 9 | static class: java.lang.Class; 10 | element: UIElement; 11 | rect: android.graphics.Rect; 12 | constructor(element: UIElement); 13 | clone(): UIElementCleaner; 14 | set(rect: android.graphics.Rect): void; 15 | clean(canvas: android.graphics.Canvas, scale: number): void; 16 | debug(canvas: android.graphics.Canvas, scale: number): void; 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } 24 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/elements/UIFPSTextElement.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module elements { 8 | export interface FPSTextElementDescription extends BasicElementDescription { 9 | type: "fps", 10 | font?: types.FontDescription, 11 | multiline?: boolean, 12 | format?: boolean, 13 | formatMaxCharsPerLine?: number, 14 | text?: string, 15 | interpolate?: boolean, 16 | period?: number 17 | } 18 | export class UIFPSTextElement extends UITextElement { 19 | static class: java.lang.Class; 20 | constructor(win: window.UIWindow, desc: FPSTextElementDescription); 21 | onSetup(desc: FPSTextElementDescription): void; 22 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 23 | } 24 | } 25 | } 26 | } 27 | } 28 | } 29 | } 30 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/elements/UIFrameElement.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module elements { 8 | export interface FrameElementDescription extends BasicElementDescription { 9 | type: "frame", 10 | bitmap?: BitmapTypes, 11 | width?: number, height?: number, 12 | scale?: number, 13 | color?: number, 14 | sides?: types.Sides 15 | } 16 | export class UIFrameElement extends UIElement { 17 | static class: java.lang.Class; 18 | constructor(win: window.UIWindow, desc: FrameElementDescription); 19 | onSetup(desc: FrameElementDescription): void; 20 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 21 | onBindingUpdated(name: string, val: T): void; 22 | onRelease(): void; 23 | } 24 | } 25 | } 26 | } 27 | } 28 | } 29 | } 30 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/elements/UIImageElement.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module elements { 8 | export interface ImageElementDescription extends BasicElementDescription { 9 | type: "image", 10 | width?: number, height?: number, 11 | scale?: number, 12 | bitmap?: BitmapTypes, 13 | overlay?: BitmapTypes 14 | } 15 | export class UIImageElement extends UIElement { 16 | static class: java.lang.Class; 17 | height: number; 18 | overlay: types.Texture; 19 | texture: types.Texture; 20 | textureScale: number; 21 | width: number; 22 | constructor(win: window.UIWindow, desc: ImageElementDescription); 23 | onSetup(desc: ImageElementDescription): void; 24 | isAnimated(): boolean; 25 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 26 | onBindingUpdated(name: string, val: T): void; 27 | onRelease(): void; 28 | } 29 | } 30 | } 31 | } 32 | } 33 | } 34 | } 35 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/elements/UIInvSlotElement.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module elements { 8 | export interface InvSlotElementDescription extends BasicElementDescription { 9 | type: "invSlot" | "invslot", 10 | bitmap?: string, 11 | size?: number, 12 | maxStackSize?: number, 13 | visual?: boolean, 14 | darken?: boolean, 15 | isDarkenAtZero?: boolean, 16 | text?: string, 17 | onItemChanged?: (container: container.UiAbstractContainer, oldId: number, oldCount: number, oldData: number) => void, 18 | isValid?: (id: number, count: number, data: number, container: container.UiAbstractContainer, item: ItemInstance) => boolean, 19 | index?: number; 20 | } 21 | export class UIInvSlotElement extends UISlotElement { 22 | static class: java.lang.Class; 23 | constructor(win: window.UIWindow, desc: UIInvSlotElement); 24 | onSetup(desc: InvSlotElementDescription): void; 25 | onTouchEvent(event: types.TouchEvent): void; 26 | onBindingUpdated(name: string, val: T): void; 27 | setupInitialBindings(container: container.UiAbstractContainer, elementName: string): void; 28 | } 29 | } 30 | } 31 | } 32 | } 33 | } 34 | } 35 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/elements/UIScaleElement.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module elements { 8 | export interface ScaleElementDescription extends BasicElementDescription { 9 | type: "scale", 10 | scale?: number, 11 | direction?: number, 12 | invert?: boolean, 13 | pixelate?: boolean, 14 | bitmap?: string, 15 | width?: number, height?: number, 16 | background?: string, 17 | backgroundOffset?: { x?: number, y?: number }, 18 | overlay?: string, 19 | overlayOffset?: { x?: number, y?: number }, 20 | value?: number 21 | } 22 | export class UIScaleElement extends UIElement { 23 | static class: java.lang.Class; 24 | static readonly DIRECTION_DOWN: number; 25 | static readonly DIRECTION_LEFT: number; 26 | static readonly DIRECTION_RIGHT: number; 27 | static readonly DIRECTION_UP: number; 28 | constructor(win: window.UIWindow, desc: ScaleElementDescription); 29 | onSetup(desc: ScaleElementDescription): void; 30 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 31 | onBindingUpdated(name: string, val: T): void; 32 | onRelease(): void; 33 | } 34 | } 35 | } 36 | } 37 | } 38 | } 39 | } 40 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/elements/UIScrollElement.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module elements { 8 | export interface ScrollElementDescription extends BasicElementDescription { 9 | type: "scroll", 10 | isInt?: boolean, 11 | width?: number, length?: number, 12 | min?: number, max?: number, 13 | divider?: number, 14 | bindingObject?: any, 15 | bindingProperty?: string, 16 | configValue?: Config.ConfigValue, 17 | bitmapHandle?: BitmapTypes, 18 | bitmapHandleHover?: BitmapTypes, 19 | bitmapBg?: string, 20 | bitmapBgHover?: string, 21 | ratio?: number, 22 | onNewValue?: (result: number, container: container.UiAbstractContainer, element: UIScrollElement) => void 23 | } 24 | export class UIScrollElement extends UIElement { 25 | static class: java.lang.Class; 26 | constructor(win: window.UIWindow, desc: ScrollElementDescription); 27 | onSetup(desc: ScrollElementDescription): void; 28 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 29 | onBindingUpdated(name: string, val: T): void; 30 | onRelease(): void; 31 | onTouchEvent(event: types.TouchEvent): void; 32 | } 33 | } 34 | } 35 | } 36 | } 37 | } 38 | } 39 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/elements/UISwitchElement.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module elements { 8 | export interface SwitchElementDescription extends BasicElementDescription { 9 | type: "switch", 10 | bindingObject?: any, 11 | bindingProperty?: string, 12 | configValue?: Config.ConfigValue, 13 | bitmapOn?: BitmapTypes, 14 | bitmapOnHover?: BitmapTypes, 15 | bitmapOff?: BitmapTypes, 16 | bitmapOffHover?: BitmapTypes, 17 | scale?: number, 18 | onNewState?: (val: boolean, container: container.UiAbstractContainer, element: UISwitchElement) => void 19 | } 20 | export class UISwitchElement extends UIElement { 21 | static class: java.lang.Class; 22 | constructor(win: window.UIWindow, desc: SwitchElementDescription); 23 | onSetup(desc: SwitchElementDescription): void; 24 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 25 | onBindingUpdated(name: string, val: T): void; 26 | onTouchEvent(event: types.TouchEvent): void; 27 | onRelease(): void; 28 | } 29 | } 30 | } 31 | } 32 | } 33 | } 34 | } 35 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/elements/UITabElement.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module elements { 8 | export interface TabElementDescription extends BasicElementDescription { 9 | type: "tab", 10 | selectedColor?: number, 11 | deselectedColor?: number, 12 | tabIndex?: number, 13 | isAlwaysSelected?: boolean, 14 | isSelected?: boolean 15 | } 16 | export class UITabElement extends UIFrameElement { 17 | static class: java.lang.Class; 18 | constructor(win: window.UIWindow, desc: TabElementDescription); 19 | onSetup(desc: TabElementDescription): void; 20 | onTouchEvent(event: types.TouchEvent): void; 21 | onReset(): void; 22 | } 23 | } 24 | } 25 | } 26 | } 27 | } 28 | } 29 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/elements/UITextElement.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module elements { 8 | export interface TextElementDescription extends BasicElementDescription { 9 | type: "text", 10 | font?: types.FontDescription, 11 | multiline?: boolean, 12 | format?: boolean, 13 | formatMaxCharsPerLine?: number, 14 | text?: string 15 | } 16 | export class UITextElement extends UIElement { 17 | static class: java.lang.Class; 18 | constructor(win: window.UIWindow, desc: TextElementDescription); 19 | onSetup(desc: TextElementDescription): void; 20 | onDraw(canvas: android.graphics.Canvas, scale: number): void; 21 | onBindingUpdated(name: string, val: T): void; 22 | } 23 | } 24 | } 25 | } 26 | } 27 | } 28 | } 29 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/icon/ItemIconLoader.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module icon { 8 | export class ItemIconLoader extends java.lang.Object { 9 | static class: java.lang.Class; 10 | static load(): void; 11 | static init(): void; 12 | } 13 | } 14 | } 15 | } 16 | } 17 | } 18 | } 19 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/icon/ItemIconSource.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module icon { 8 | export class ItemIconSource extends java.lang.Object { 9 | static class: java.lang.Class; 10 | static readonly instance: ItemIconSource; 11 | private constructor(); 12 | static init(): void; 13 | static isGlintAnimationEnabled(): boolean; 14 | registerIcon(id: number, name: string): void; 15 | registerIcon(id: number, data: number, name: string): void; 16 | registerIcon(id: number, bmp: android.graphics.Bitmap): void; 17 | registerIcon(id: number, data: number, bmp: android.graphics.Bitmap): void; 18 | checkoutIcon(_name: string): Nullable; 19 | getIconName(id: number, data: number): string; 20 | getIconPath(id: number, data: number): string; 21 | getNullableIcon(id: number, data: number): Nullable; 22 | getIcon(id: number, data: number, icon: android.graphics.Bitmap, enableCache: boolean): android.graphics.Bitmap; 23 | getScaledIcon(originIcon: android.graphics.Bitmap, id: number, data: number, size: number, glint: number): android.graphics.Bitmap; 24 | static generateAllModItemModels(): void; 25 | } 26 | } 27 | } 28 | } 29 | } 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/memory/BitmapCache.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module memory { 8 | export class BitmapCache extends java.lang.Object { 9 | static class: java.lang.Class; 10 | static readonly CACHE_DIR: string; 11 | static init(): void; 12 | static getCacheFile(name: string): java.io.File; 13 | static getUseId(): number; 14 | static getStackPos(id: number): number; 15 | static registerWrap(wrap: BitmapWrap): void; 16 | static unregisterWrap(wrap: BitmapWrap): void; 17 | static writeToFile(file: java.io.File, bitmap: android.graphics.Bitmap): void; 18 | static readFromFile(file: java.io.File, bitmap: android.graphics.Bitmap): void; 19 | static testCaching(src: android.graphics.Bitmap): android.graphics.Bitmap; 20 | static storeOldWraps(maxStackPos: number): void; 21 | static immediateGC(): void; 22 | static asyncGC(): void; 23 | } 24 | } 25 | } 26 | } 27 | } 28 | } 29 | } 30 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/memory/BitmapWrap.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module memory { 8 | export abstract class BitmapWrap extends java.lang.Object { 9 | static class: java.lang.Class; 10 | static readonly MISSING_BITMAP: android.graphics.Bitmap; 11 | abstract resize(x: number, y: number): BitmapWrap; 12 | abstract restore(): boolean; 13 | abstract store(): boolean; 14 | constructor(); 15 | storeIfNeeded(): void; 16 | restoreIfNeeded(): void; 17 | getWidth(): number; 18 | getHeight(): number; 19 | getConfig(): android.graphics.Bitmap.Config; 20 | getStackPos(): number; 21 | get(): android.graphics.Bitmap; 22 | isRecycled(): boolean; 23 | recycle(): void; 24 | removeCache(): void; 25 | getResizedCache(width: number, height: number): android.graphics.Bitmap; 26 | static wrap(bmp: android.graphics.Bitmap): BitmapWrap; 27 | static wrap(name: string, width: number, height: number): BitmapWrap; 28 | static wrap(name: string): BitmapWrap; 29 | } 30 | } 31 | } 32 | } 33 | } 34 | } 35 | } 36 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/memory/RandomBitmapWrap.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module memory { 8 | export class RandomBitmapWrap extends BitmapWrap { 9 | static class: java.lang.Class; 10 | constructor(bitmap: android.graphics.Bitmap); 11 | store(): boolean; 12 | restore(): boolean; 13 | resize(width: number, height: number): BitmapWrap; 14 | recycle(): void; 15 | } 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/memory/SourceBitmapWrap.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module memory { 8 | export class SourceBitmapWrap extends BitmapWrap { 9 | static class: java.lang.Class; 10 | constructor(name: string, width: number, height: number); 11 | store(): boolean; 12 | restore(): boolean; 13 | resize(width: number, height: number): BitmapWrap; 14 | recycle(): void; 15 | } 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/types/FrameTextureSource.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module types { 8 | export interface Sides { up?: boolean, down?: boolean, left?: boolean, right?: boolean } 9 | export class FrameTextureSource extends java.lang.Object { 10 | static class: java.lang.Class; 11 | static getFrameTexture(name: string, style: UIStyle): FrameTexture; 12 | static scriptableAsSides(obj: Sides): [boolean, boolean, boolean, boolean]; 13 | } 14 | } 15 | } 16 | } 17 | } 18 | } 19 | } 20 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/types/ITouchEventListener.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module types { 8 | export interface ITouchEventListenerJS { 9 | (touchEvent: TouchEvent): void; 10 | } 11 | export class ITouchEventListener extends java.lang.Object { 12 | static class: java.lang.Class; 13 | constructor(); 14 | constructor(impl: { onTouchEvent: (event: TouchEvent) => void }); 15 | onTouchEvent(event: TouchEvent): void; 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/types/TouchEvent.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module types { 8 | export class TouchEvent extends java.lang.Object { 9 | static class: java.lang.Class; 10 | _x: number; 11 | _y: number; 12 | downX: number; 13 | downY: number; 14 | localX: number; 15 | localY: number; 16 | type: TouchEventType; 17 | x: number; 18 | y: number; 19 | constructor(listener: ITouchEventListener | ITouchEventListenerJS); 20 | hasMovedSinceLastDown(): boolean; 21 | update(event: android.view.MotionEvent): void; 22 | preparePosition(win: window.UIWindow, rect: android.graphics.Rect): void; 23 | posAsScriptable(): { x: number, y: number }; 24 | localPosAsScriptable(): { x: number, y: number }; 25 | } 26 | } 27 | } 28 | } 29 | } 30 | } 31 | } 32 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/types/TouchEventType.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module types { 8 | export class TouchEventType extends java.lang.Object { 9 | static class: java.lang.Class; 10 | static readonly DOWN: TouchEventType; 11 | static readonly UP: TouchEventType; 12 | static readonly MOVE: TouchEventType; 13 | static readonly CLICK: TouchEventType; 14 | static readonly LONG_CLICK: TouchEventType; 15 | static readonly CANCEL: TouchEventType; 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/window/IWindowEventListener.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module window { 8 | export class IWindowEventListener extends java.lang.Object { 9 | static class: java.lang.Class; 10 | constructor(implementation: { 11 | onClose(win: UIWindow): void; 12 | onOpen(win: UIWindow): void; 13 | }); 14 | onClose(win: UIWindow): void; 15 | onOpen(win: UIWindow): void; 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/window/UIAdaptiveWindow.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module window { 8 | export class UIAdaptiveWindow extends UIWindowGroup { 9 | static class: java.lang.Class; 10 | constructor(content: WindowContent); 11 | setContent(content: WindowContent): void; 12 | /** 13 | * Sets style profile for the current [[AdaptiveWindow]] 14 | * @param profile 0 for classic profile, 1 for default profile 15 | */ 16 | setProfile(profile: 0 | 1): void; 17 | /** 18 | * Forces [[AdaptiveWindow]] to be displayed using some profile 19 | * @param profile 0 for classic profile, 1 for default profile or -1 not 20 | * to force any profile. By default forced profile is -1 21 | */ 22 | setForcedProfile(profile: 0 | 1): void; 23 | open(): void; 24 | } 25 | } 26 | } 27 | } 28 | } 29 | } 30 | } 31 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/window/UIWindowBackgroundDrawable.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module window { 8 | export class UIWindowBackgroundDrawable extends android.graphics.drawable.Drawable implements IBackgroundProvider { 9 | static class: java.lang.Class; 10 | window: UIWindow; 11 | constructor(win: UIWindow); 12 | setBackgroundColor(color: number): void; 13 | addDrawing(drawing: background.IDrawing): void; 14 | clearAll(): void; 15 | draw(canvas: NonNullable): void; 16 | prepareCache(): void; 17 | releaseCache(): void; 18 | setAlpha(alpha: number): void; 19 | /* Just for TS not to be angry */ 20 | setColorFilter(par1: number, par2: android.graphics.PorterDuff.Mode): void; 21 | setColorFilter(filter: Nullable): void; 22 | /** @returns -3 */ 23 | getOpacity(): number; 24 | } 25 | } 26 | } 27 | } 28 | } 29 | } 30 | } 31 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/window/UIWindowElementDrawable.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module window { 8 | export class UIWindowElementDrawable extends android.graphics.drawable.Drawable implements IElementProvider, types.ITouchEventListener { 9 | static class: java.lang.Class; 10 | isDebugEnabled: boolean; 11 | window: UIWindow; 12 | windowElements: java.util.ArrayList; 13 | constructor(win: UIWindow); 14 | setBackgroundProvider(provider: IBackgroundProvider): void; 15 | addOrRefreshElement(element: elements.UIElement): void; 16 | removeElement(element: elements.UIElement): void; 17 | releaseAll(): void; 18 | resetAll(): void; 19 | invalidateAll(): void; 20 | runCachePreparation(): void; 21 | getStyleFor(element: elements.UIElement): types.UIStyle; 22 | setWindowStyle(style: types.UIStyle): void; 23 | draw(canvas: NonNullable): void; 24 | drawDirty(canvas: android.graphics.Canvas, scale: number): void; 25 | onTouchEvent(event: types.TouchEvent): void; 26 | setAlpha(alpha: number): void; 27 | /* Just for TS not to be angry */ 28 | setColorFilter(par1: number, par2: android.graphics.PorterDuff.Mode): void; 29 | setColorFilter(filter: Nullable): void; 30 | /** @returns -3 */ 31 | getOpacity(): number; 32 | toString(): string; 33 | } 34 | } 35 | } 36 | } 37 | } 38 | } 39 | } 40 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/window/UIWindowStandard.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module window { 8 | export abstract class UIWindowStandard extends UIWindowGroup { 9 | static class: java.lang.Class; 10 | constructor(content: StandardWindowContent); 11 | getContent(): StandardWindowContent; 12 | getStyleSafe(): types.UIStyle; 13 | setContent(content: StandardWindowContent): void; 14 | } 15 | } 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/window/WindowParent.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module window { 8 | export class WindowParent extends java.lang.Object { 9 | static class: java.lang.Class; 10 | static openWindow(window: UIWindow): void; 11 | static closeWindow(window: UIWindow): void; 12 | static applyWindowInsets(window: UIWindow, insets: android.view.WindowInsets): void; 13 | static releaseWindowLayout(layout: android.view.View): void; 14 | } 15 | } 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/ui/window/WindowProvider.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module ui { 7 | export module window { 8 | export class WindowProvider extends java.lang.Object { 9 | static class: java.lang.Class; 10 | static readonly instance: WindowProvider; 11 | static getFrame(): number; 12 | onWindowOpened(window: IWindow): void; 13 | onWindowClosed(window: IWindow): void; 14 | onBackPressed(): boolean; 15 | onActivityStopped(): void; 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/util/ConfigVisualizer.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module util { 7 | export class ConfigVisualizer extends java.lang.Object { 8 | static class: java.lang.Class; 9 | /** 10 | * Constructs new [[ConfigVisualizer]] instance with specified elements 11 | * names prefix 12 | * @param config configuration file to be loaded 13 | * @param prefix elements names prefix used for this visualizer 14 | */ 15 | constructor(config: innercore.mod.build.Config, prefix: string); 16 | /** 17 | * Constructs new [[ConfigVisualizer]] instance with default elements 18 | * names prefix (*config_vis*) 19 | * @param config configuration file to be loaded 20 | */ 21 | constructor(config: innercore.mod.build.Config); 22 | /** 23 | * Removes all elements with current element name prefix. In other 24 | * words, removes all elements that were created by this 25 | * [[ConfigVisualizer]] instance 26 | * @param elements target [[WindowContent.elements]] section 27 | */ 28 | clearVisualContent(elements: UI.ElementSet): void; 29 | /** 30 | * Creates elements in the window to visualize configuration file 31 | * @param elements target [[WindowContent.elements]] section 32 | * @param prefs top left position of the first element. Default position 33 | * is (0, 0, 0) 34 | */ 35 | createVisualContent(elements: UI.ElementSet, prefs?: Partial): void; 36 | } 37 | } 38 | } 39 | } 40 | } 41 | } 42 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/mod/util/ScriptableWatcher.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module mod { 6 | export module util { 7 | export class ScriptableWatcher extends java.lang.Object { 8 | static class: java.lang.Class; 9 | object: object; 10 | constructor(obj: object); 11 | isDirty(): boolean; 12 | validate(): void; 13 | invalidate(): void; 14 | setTarget(obj: object): void; 15 | refresh(): void; 16 | toString(): string; 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/unlimited/BlockShape.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module unlimited { 6 | export class BlockShape extends java.lang.Object { 7 | static class: java.lang.Class; 8 | x1: number; 9 | x2: number; 10 | y1: number; 11 | y2: number; 12 | z1: number; 13 | z2: number; 14 | constructor(x1: number, y1: number, z1: number, x2: number, y2: number, z2: number); 15 | constructor(); 16 | set(x1: number, y1: number, z1: number, x2: number, y2: number, z2: number): void; 17 | setToBlock(id: number, data: number): void; 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/api/unlimited/BlockVariant.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module api { 5 | export module unlimited { 6 | interface IBlockVariant extends Block.BlockVariation { isTech?: boolean } 7 | export class BlockVariant extends java.lang.Object { 8 | static class: java.lang.Class; 9 | readonly data: number; 10 | readonly inCreative: boolean; 11 | isTechnical: boolean; 12 | readonly name: string; 13 | renderType: number; 14 | shape: BlockShape; 15 | readonly textureIds: number[]; 16 | readonly textures: string[]; 17 | readonly uid: number; 18 | constructor(uid: number, data: number, name: string, textures: string[], textureIds: number[], inCreative: boolean); 19 | constructor(uid: number, data: number, object: IBlockVariant); 20 | getGuiBlockModel(): mod.ui.GuiBlockModel; 21 | getSpriteTexturePath(): string; 22 | } 23 | } 24 | } 25 | } 26 | } 27 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/mod/resource/ResourcePackManager.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module mod { 5 | export module resource { 6 | export class ResourcePackManager extends java.lang.Object { 7 | static class: java.lang.Class; 8 | static readonly LOGGER_TAG = "INNERCORE-RESOURCES"; 9 | static instance: ResourcePackManager; 10 | resourcePackDefinition: string; 11 | resourcePackList: string; 12 | resourceStorage: ResourceStorage; 13 | constructor(); 14 | static getBlockTextureName(texture: string, meta: number): Nullable; 15 | static getItemTextureName(texture: string, meta: number): Nullable; 16 | static getSourcePath(): string; 17 | static isValidBlockTexture(texture: string, meta: number): boolean; 18 | static isValidItemTexture(texture: string, meta: number): boolean; 19 | initializeResources(): void; 20 | } 21 | } 22 | } 23 | } 24 | } 25 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/mod/resource/ResourceStorage.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module mod { 5 | export module resource { 6 | export class ResourceStorage extends java.lang.Object implements pack.IResourcePack { 7 | static class: java.lang.Class; 8 | static readonly VANILLA_RESOURCE = "resource_packs/vanilla/"; 9 | animationList: org.json.JSONArray; 10 | blockTexttureDescriptor: types.TextureAtlasDescription; 11 | itemTextureDescriptor: types.TextureAtlasDescription; 12 | textureList: org.json.JSONArray; 13 | static addTextureToLoad(path: string): void; 14 | static loadAllTextures(): void; 15 | static nativeAddTextureToLoad(path: string): void; 16 | addResourceFile(textureType: types.enums.TextureType, resource: horizon.modloader.resource.directory.Resource): void; 17 | build(): void; 18 | getAbsolutePath(): string; 19 | getId(): string; 20 | getLinkedFilePath(link: string): string; 21 | getPackName(): string; 22 | } 23 | } 24 | } 25 | } 26 | } 27 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/mod/resource/pack/IResourcePack.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module mod { 5 | export module resource { 6 | export module pack { 7 | export class IResourcePack extends java.lang.Object { 8 | static class: java.lang.Class; 9 | getAbsolutePath(): string; 10 | getPackName(): string; 11 | constructor(); 12 | constructor(impl: { 13 | getAbsolutePath: () => string; 14 | getPackName: () => string; 15 | }); 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/mod/resource/pack/ResourcePack.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module mod { 5 | export module resource { 6 | export module pack { 7 | export class ResourcePack extends java.lang.Object implements IResourcePack { 8 | static class: java.lang.Class; 9 | isLoaded: boolean; 10 | resourceFiles: java.util.ArrayList; 11 | constructor(dir: string); 12 | getAbsolutePath(): string; 13 | getPackName(): string; 14 | readAllFiles(): void; 15 | } 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/mod/resource/types/ResourceFile.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module mod { 5 | export module resource { 6 | export module types { 7 | export class ResourceFile extends java.io.File { 8 | static class: java.lang.Class; 9 | constructor(rp: pack.IResourcePack, file: java.io.File); 10 | constructor(path: NonNullable); 11 | getAnimationType(): enums.AnimationType; 12 | getLocalDir(): string; 13 | getLocalPath(): string; 14 | getParseError(): enums.ParseError; 15 | getResourcePack(): pack.IResourcePack; 16 | getTextureType(): enums.TextureType; 17 | getType(): enums.FileType; 18 | setResourcePack(rp: pack.IResourcePack): void; 19 | } 20 | } 21 | } 22 | } 23 | } 24 | } 25 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/mod/resource/types/TextureAnimationFile.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module mod { 5 | export module resource { 6 | export module types { 7 | export class TextureAnimationFile extends ResourceFile { 8 | static class: java.lang.Class; 9 | constructor(rfile: ResourceFile); 10 | constructor(path: NonNullable); 11 | constructAnimation(): org.json.JSONObject; 12 | isValid(): boolean; 13 | } 14 | } 15 | } 16 | } 17 | } 18 | } 19 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/mod/resource/types/TextureAtlasDescription.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module mod { 5 | export module resource { 6 | export module types { 7 | export class TextureAtlasDescription extends java.lang.Object { 8 | static class: java.lang.Class; 9 | jsonObject: org.json.JSONObject; 10 | textureData: org.json.JSONObject; 11 | constructor(path: string); 12 | constructor(json: org.json.JSONObject); 13 | addTextureFile(file: java.io.File, name: string): void; 14 | addTexturePath(path: string, meta: number, name: string): void; 15 | getTextureCount(texture: string): number; 16 | getTextureName(texture: string, meta: number): string; 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/mod/resource/types/enums/AnimationType.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module mod { 5 | export module resource { 6 | export module types { 7 | export module enums { 8 | export class AnimationType extends java.lang.Object { 9 | static class: java.lang.Class; 10 | static readonly TEXTURE: AnimationType; 11 | static readonly DESCRIPTOR: AnimationType; 12 | } 13 | } 14 | } 15 | } 16 | } 17 | } 18 | } 19 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/mod/resource/types/enums/FileType.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module mod { 5 | export module resource { 6 | export module types { 7 | export module enums { 8 | export class FileType extends java.lang.Object { 9 | static class: java.lang.Class; 10 | static readonly RAW: FileType; 11 | static readonly JSON: FileType; 12 | static readonly EXECUTABLE: FileType; 13 | static readonly MANIFEST: FileType; 14 | static readonly TEXTURE: FileType; 15 | static readonly ANIMATION: FileType; 16 | static readonly INVALID: FileType; 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } 24 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/mod/resource/types/enums/ParseError.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module mod { 5 | export module resource { 6 | export module types { 7 | export module enums { 8 | export class ParseError extends java.lang.Object { 9 | static class: java.lang.Class; 10 | static readonly ANIMATION_INVALID_DELAY: ParseError; 11 | static readonly ANIMATION_INVALID_FILE: ParseError; 12 | static readonly ANIMATION_INVALID_JSON: ParseError; 13 | static readonly ANIMATION_INVALID_NAME: ParseError; 14 | static readonly ANIMATION_NAME_MISSING: ParseError; 15 | static readonly ANIMATION_TILE_MISSING: ParseError; 16 | static readonly NONE: ParseError; 17 | toString(): string; 18 | } 19 | } 20 | } 21 | } 22 | } 23 | } 24 | } 25 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/com/zhekasmirnov/innercore/mod/resource/types/enums/TextureType.d.ts: -------------------------------------------------------------------------------- 1 | declare module com { 2 | export module zhekasmirnov { 3 | export module innercore { 4 | export module mod { 5 | export module resource { 6 | export module types { 7 | export module enums { 8 | export class TextureType extends java.lang.Object { 9 | static class: java.lang.Class; 10 | static readonly BLOCK: TextureType; 11 | static readonly DEFAULT: TextureType; 12 | static readonly GUI: TextureType; 13 | static readonly ITEM: TextureType; 14 | static readonly PARTICLE: TextureType; 15 | } 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } 22 | } -------------------------------------------------------------------------------- /documentation/core-engine/declarations/core_dump.d.ts: -------------------------------------------------------------------------------- 1 | declare namespace MobRegistry { 2 | namespace customEntities { } 3 | namespace loadedEntities { } 4 | 5 | function registerEntity(name: any): any; 6 | 7 | function registerUpdatableAsEntity(updatable: any): any; 8 | 9 | function spawnEntityAsPrototype(typeName: any, coords: any, extraData: any): any; 10 | 11 | function getEntityUpdatable(entity: number): any; 12 | 13 | function registerNativeEntity(entity: number): any; 14 | 15 | function registerEntityRemove(entity: number): any; 16 | 17 | function resetEngine(): any; 18 | } 19 | 20 | declare namespace MobSpawnRegistry { 21 | namespace spawnData { } 22 | 23 | function registerSpawn(entityType: any, rarity: number, condition: any, denyNaturalDespawn: any): any; 24 | 25 | function getRandomSpawn(rarityMultiplier: any): any; 26 | 27 | function getRandPosition(): any; 28 | 29 | function executeSpawn(spawn: any, position: any): any; 30 | var counter: number; 31 | 32 | function tick(): any; 33 | 34 | function onChunkGenerated(x: number, z: number): any; 35 | } 36 | 37 | declare function EntityModelWatcher(entity: number, model: any): any; 38 | declare function EntityAIWatcher(customPrototype: any): any; 39 | 40 | -------------------------------------------------------------------------------- /documentation/core-engine/headers/android-declarations.d.ts: -------------------------------------------------------------------------------- 1 | declare module native { export class Array { constructor(); length: number; [index: number]: T; } } 2 | 3 | import globalAndroid = android; 4 | 5 | -------------------------------------------------------------------------------- /documentation/static/.nojekyll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mineprogramming/innercore-docs/3f7125bb1d8437c3e096ae6e3a2e8e8ad6d1ee68/documentation/static/.nojekyll -------------------------------------------------------------------------------- /documentation/static/en/README.md: -------------------------------------------------------------------------------- 1 | > English selected... 2 | -------------------------------------------------------------------------------- /documentation/static/en/config/_navbar.md: -------------------------------------------------------------------------------- 1 | - Language 2 | - [:uk: English](/en/) 3 | - [:ru: Русский](/ru/) 4 | -------------------------------------------------------------------------------- /documentation/static/en/config/_sidebar.md: -------------------------------------------------------------------------------- 1 | - [Horizon](/en/page/apps/horizon/index.md) 2 | 3 | - [Packs](/en/page/apps/horizon/packs.md) 4 | - [Pack System](/en/page/apps/horizon/pack-system.md) 5 | 6 | - [InnerCore](/en/page/apps/innercore/index.md) 7 | 8 | - [Core Engine v2.1 API](/api/ ':ignore :target=_self') 9 | - [Versions](/en/page/apps/innercore/changelog.md) 10 | 11 | - Guides 12 | Getting Started 13 | 14 | - [Mod Configuration Files](/en/page/guides/getting-started/config.md) 15 | 16 | Minecraft 17 | 18 | - [Attributes](/en/page/guides/minecraft/attributes.md) 19 | - [Player Containers](/en/page/guides/minecraft/playercontainers.md) 20 | 21 | Mod Api 22 | 23 | - [Callbacks](/en/page/guides/mod-api/callbacks.md) 24 | 25 | Mod Resources 26 | 27 | - [Materials](/en/page/guides/mod-resources/materials.md) 28 | 29 | Player 30 | 31 | - [Abilities](/en/page/guides/player/abilities.md) 32 | 33 | World 34 | 35 | - [Biomes](/en/page/guides/world/biomes.md) 36 | - [Dimensions](/en/page/guides/world/dimensions.md) 37 | 38 | - Mods: 39 | [IndustrialCraft](/en/page/mod/IndustrialCraft2.md) 40 | 41 | - Mod Libraries: 42 | [Core Utility](/en/page/mod-lib/CoreUtility.md) 43 | [Dungeon Utility](/en/page/mod-lib/DungeonUtility.md) 44 | 45 | - Libraries: 46 | [BackpackAPI](/en/page/lib/BackpackAPI.md) 47 | 48 | - [Contributing](/en/page/other/contributing.md) 49 | - [Creating new pages[OLD]](/en/page/other/create-page.md) 50 | -------------------------------------------------------------------------------- /documentation/static/en/page/apps/horizon/index.md: -------------------------------------------------------------------------------- 1 | ## What is HMK? 2 | 3 | _**HMK** - Horizon Modding Kernel App_ 4 | 5 | Horizon is a universal platform for launching mobile games with mods. At the moment, it supports only InnerCore, which contains Minecraft: Bedrock Edition 1.11.4 and 1.16.201. Horizon allows you to create and store several independent InnerCore packages, which in turn allows you to divide different mod packs and worlds with these packages. Development can take place in JavaScript, Java, C++ and not only. 6 | 7 | ## Structure of the HMK pack 8 | 9 | 1. The game on which the launcher is based 10 | 2. The launcher on which the user will play 11 | 3. The browser of mods that the user can apply to the game 12 | 13 | ## Native mods 14 | 15 | Mods are written in c++ and applied to game directly. 16 | They have full access to game and can use all its functions. 17 | 18 | ## Useful links 19 | 20 | [Group in VK](https://vk.com/core_engine) 21 | 22 | [Video guide for setting up the environment for development](https://www.youtube.com/watch?v=ofwKkRYh97k) 23 | 24 | [Video guide for creating new projects and importing old](https://www.youtube.com/watch?v=ykAVJoxKTKc) 25 | 26 | [Tools for development of mods](https://icmods.mineprogramming.org/dev) 27 | 28 | [Horizon](https://play.google.com/store/apps/details?id=com.zheka.horizon) 29 | 30 | [Discussion in VK for sending messages about bugs](https://vk.com/topic-134044100_41523503) 31 | 32 | [Documentation for development of mods](https://docs.mineprogramming.org/) 33 | 34 | [Toolchain for development of mods](https://github.com/zheka2304/innercore-mod-toolchain) 35 | -------------------------------------------------------------------------------- /documentation/static/en/page/apps/horizon/pack-system.md: -------------------------------------------------------------------------------- 1 | ## What are packs? 2 | 3 | Packs are fully independent instances of games with mods (with separate saves and mods). Mods can be installed manually or using internal mod managers. 4 | 5 | All installed packs will be showed on main screen, to select and open a pack just click on it. After pack is selected it will be opened automatically during next launches. To exit from pack menu to pack selection press back on navigation panel. 6 | 7 | ## How to install / remove a pack? 8 | 9 | To install the pack, click the large + button and select the pack you are interested in. 10 | 11 | To delete an already downloaded/not installed pack, you need to hold on the pack and a context menu will open, which has the following content: 12 | 13 | ## Clonning packs 14 | 15 | Cloning packs allows you to create full copy of pack and all its mods and saves, that will be fully independent from original pack. To clone a pack long-click on it and press clone. 16 | 17 | ## Deleting packs 18 | 19 | If you want to free storage space, used by some pack, just long-click and press delete, but notice, that it will delete all its saves. Packs will not be deleted if app is uninstalled. 20 | 21 | ## Pack context menu 22 | 23 | - Add to favorites - mark this pack as a favorite 24 | - Clone - duplicates the pack completely with all worlds and mods 25 | - Re-install - completely reinstalls the package from the cache with the data saved 26 | - Show info - opens a dialog box with information about the package, such as: 27 | - Title - The full name of the pack 28 | - Pack Description 29 | - Game - What game was created for 30 | - Version - The version of the current pack and the latest available version 31 | - State - pack status 32 | - Installed - pack is already installed 33 | - Pending - expected download and installation 34 | - NOT_INSTALLED - not downloaded and not installed 35 | - Local directory -path to the pack from /sdcard/games/horizon/packs 36 | - External UUID - UUID of pack 37 | - Changelog - opens the full changelog for this pack 38 | - Delete - completely deletes all pack data, including worlds, resource packs, mods, etc. 39 | -------------------------------------------------------------------------------- /documentation/static/en/page/apps/horizon/packs.md: -------------------------------------------------------------------------------- 1 | ## What is in the pack 2 | 3 | In main menu of InnerCore pack there are 5 buttons: 4 | 5 | 1. **Play** - button to start the game 6 | 2. **Native mods** - button on the right side of the screen to open the native mods menu 7 | 3. **Mod browser** - mod browser for this game 8 | 1. Download mods - a tab where you can download any mods for the game. 9 | 2. My mods - a tab where you can manage your installed mods. 10 | 3. Modpacks - ready-made builds of mods that are created by developers 11 | 4. Updates - list of mods that are available for update 12 | 5. Visit website - opens a full-fledged mods site for the game 13 | 4. **Preferences and links** 14 | 1. Pack settings 15 | 1. **Disable the loading screen** - displaying the loading screen of mods, when turned on on some devices, it may speed up the download 16 | 2. **Developer Mode** - useful for mod creators, includes debugging mode in supported mods. 17 | 3. **Limitation of updates by version** - the number of updates of mods in the tick will be limited by the execution time, otherwise by the number of updated objects. Simply put, how many calls to the tick can mods make. 18 | 4. **Maximum updates per tick** - adjustment of the _time limit_ 19 | 5. **Advanced stream priority settings** - a higher priority of the server stream stabilizes the number of ticks per second of TPS \(this means more stable operation and response time\), however, this can cause freezes and frame drawdown per second of FPS 20 | 6. **Server thread priority** - adjustment of the _expanded thread priority setting_ 21 | 7. **Threshold FPS** - as long as FPS is below this threshold, the server thread will work at the lower priority, otherwise the upper priority will be set 22 | 8. **Number of additional threads** - Additional threads are an experimental setup. On powerful devices, it can improve performance under heavy load. 23 | 9. **Priority of additional threads** - adjustment of _the number of additional threads._ 24 | 10. **Auto-save** - allows you to save the world and mods data if the game may abruptly shut down or incorrectly 25 | 11. **Autosave period** - time in seconds between autosave launches_ 26 | 12. **Enable Socket Server** - Allows players on a local network to connect to your world using sockets 27 | 13. **Use the native protocol** - connect using the native protocol \(by default, the protocol based on _sockets_\ has a higher priority) 28 | 14. **Force the Local Native Protocol** - _**for developers!**_ Use the native protocol for communication between the local client and the server. This setting is only needed for debugging mods and the engine, **do not use it for the game!** 29 | 2. Guides and links - a tab with links and guides 30 | 3. Thanks - a tab with credits of the developers, testers, mod developers 31 | 4. About app 32 | -------------------------------------------------------------------------------- /documentation/static/en/page/guides/minecraft/attributes.md: -------------------------------------------------------------------------------- 1 | Attributes is a mechanism that allows to set some floating-point attributes for any entity (including player). Those values include health, speed, attack damage and many others. 2 | 3 | Some of the attributes belong to players only, other ones are shared between all the actors. Currently known attributes with descriptions are listed below. 4 | 5 | ## Known Attributes List 6 | 7 | ### minecraft:health 8 | 9 | How much health the mob starts with. Units are in # of half hearts. 10 | 11 | ### minecraft:follow_range 12 | 13 | How far away the mob will stay from a target, in blocks, that it is following (usually the owner). 14 | 15 | ### minecraft:knockback_resistance 16 | 17 | How much resistance is there against knockback effects. 0 mean no resistance, 1 means fully immune. 18 | 19 | ### minecraft:movement 20 | 21 | How fast the mob moves in the world. Units are blocks per tick, 20 ticks in a second. This means that a mob with 0.25 movement speed will run 5 blocks every second (20 ticks \* 0.25 blocks per tick). 22 | 23 | ### minecraft:underwater_movement 24 | 25 | How fast the mob moves in the world. Units are blocks per tick, 20 ticks in a second. This means that a mob with 0.25 movement speed will run 5 blocks every second (20 ticks \* 0.25 blocks per tick). 26 | 27 | ### minecraft:attack_damage 28 | 29 | How much damage the entity inflicts. 30 | 31 | ### minecraft:absorption 32 | 33 | ### minecraft:luck 34 | 35 | ### minecraft:fall_damage 36 | 37 | ### minecraft:horse.jump_strength 38 | 39 | ### minecraft:player.hunger 40 | 41 | Player's hunger level 42 | 43 | ### minecraft:player.saturation 44 | 45 | Player's saturation level 46 | 47 | ### minecraft:player.exhaustion 48 | 49 | Player's exhaustion level 50 | 51 | ### minecraft:player.level 52 | 53 | Player's level 54 | 55 | ### minecraft:player.experience 56 | 57 | Player's experience level 58 | -------------------------------------------------------------------------------- /documentation/static/en/page/guides/minecraft/playercontainers.md: -------------------------------------------------------------------------------- 1 | Containers allow to store items in TileEntities and some entities. 2 | 3 | ContainerCategory - maybe type of container \ 4 | ContainerEnumName - maybe unique id of container or id of name 5 | 6 | ## Known containers in inventory 7 | 8 | ### armor_items 9 | #### ContainerModel 10 | FilteredContainerModel \ 11 | ContainerCategory = 1 \ 12 | ContainerEnumName = 6 13 | 14 | ### combined_hotbar_and_inventory_items 15 | #### ContainerModel 16 | FilteredContainerModel \ 17 | ContainerCategory = 1 \ 18 | ContainerEnumName = 12 19 | 20 | ### hotbar_items 21 | #### ContainerModel 22 | FilteredContainerModel \ 23 | ContainerCategory = 1 \ 24 | ContainerEnumName = 27 25 | 26 | ### inventory_items 27 | #### ContainerModel 28 | FilteredContainerModel \ 29 | ContainerCategory = 1 \ 30 | ContainerEnumName = 28 31 | 32 | ### offhand_items 33 | 34 | #### ContainerModel 35 | 36 | FilteredContainerModel \ 37 | ContainerCategory = 1 \ 38 | ContainerEnumName = 33 39 | 40 | 41 | ### crafting_input_items 42 | 43 | #### ContainerModel 44 | FilteredContainerModel \ 45 | ContainerCategory = 2 \ 46 | ContainerEnumName = 13 47 | 48 | ### cursor_items 49 | 50 | #### ContainerModel 51 | 52 | FilteredContainerModel \ 53 | ContainerCategory = 2 \ 54 | ContainerEnumName = 58 55 | 56 | 57 | ### crafting_output_items 58 | 59 | #### ContainerModel 60 | 61 | FilteredContainerModel \ 62 | ContainerCategory = 3 \ 63 | ContainerEnumName = 14 64 | 65 | ### recipe_construction 66 | 67 | Stores items in Construction tab. 68 | #### ContainerModel 69 | 70 | FilteredContainerModel \ 71 | ContainerCategory = 3 \ 72 | ContainerEnumName = 15 73 | 74 | ### recipe_nature 75 | 76 | Stores items in Nature tab. 77 | 78 | #### ContainerModel 79 | 80 | FilteredContainerModel \ 81 | ContainerCategory = 3 \ 82 | ContainerEnumName = 16 83 | 84 | ### recipe_items 85 | 86 | Stores items in Items tab. 87 | 88 | #### ContainerModel 89 | 90 | FilteredContainerModel \ 91 | ContainerCategory = 3 \ 92 | ContainerEnumName = 17 93 | 94 | ### recipe_search 95 | 96 | #### ContainerModel 97 | 98 | FilteredContainerModel \ 99 | ContainerCategory = 3 \ 100 | ContainerEnumName = 18 101 | 102 | ### recipe_equimpent 103 | 104 | Stores items in Equimpent tab. 105 | 106 | #### ContainerModel 107 | 108 | FilteredContainerModel \ 109 | ContainerCategory = 3 \ 110 | ContainerEnumName = 20 111 | 112 | ### creative_output_items 113 | 114 | #### ContainerModel 115 | 116 | FilteredContainerModel \ 117 | ContainerCategory = 3 \ 118 | ContainerEnumName = 59 119 | -------------------------------------------------------------------------------- /documentation/static/en/page/guides/mod-resources/materials.md: -------------------------------------------------------------------------------- 1 | Inner Core allows you to add new materials and attach shaders to them to use for items in the inventory and 3d models. 2 | 3 | **Material** is a set of OpenGL properties, vertex and fragment shaders that is used for an in-game object. 4 | 5 | ## Adding custom materials 6 | 7 | Custom materials files should be located in the resource pack in the _custom-materials_ directory. Each file should have _.material_ extension and can contain one or multiple material descriptions. An example of such a file for vanilla barrel material is listed below: 8 | 9 | ```json 10 | { 11 | "materials": { 12 | "version": "1.0.0", 13 | 14 | "barrier": { 15 | "+defines": ["ALPHA_TEST", "TEXEL_AA", "ATLAS_TEXTURE"], 16 | "+states": ["DisableAlphaWrite"], 17 | 18 | "vertexFields": [{ "field": "Position" }, { "field": "UV1" }, { "field": "Color" }, { "field": "UV0" }], 19 | 20 | "vertexShader": "shaders/barrier.vertex", 21 | "vrGeometryShader": "shaders/uv.geometry", 22 | "fragmentShader": "shaders/renderchunk.fragment", 23 | 24 | "msaaSupport": "Both", 25 | 26 | "depthFunc": "LessEqual", 27 | 28 | "blendSrc": "SourceAlpha", 29 | "blendDst": "OneMinusSrcAlpha", 30 | 31 | "+samplerStates": [ 32 | { 33 | "samplerIndex": 0, 34 | "textureFilter": "TexelAA" 35 | }, 36 | { 37 | "samplerIndex": 1, 38 | "textureFilter": "Bilinear" 39 | } 40 | ] 41 | } 42 | } 43 | } 44 | ``` 45 | 46 | Full documentation of _.material_ file format is currently unavailable. 47 | 48 | You can inherit an existing material using _material_name:material_parent_ syntax in your material declaration. 49 | 50 | > _Note that Minecraft doesn't display any materials or shaders compilation errors and doesn't display an object with invalid materials or shaders at all._ 51 | 52 | ## Using custom shaders 53 | 54 | You can add custom shaders to your mod by locating them in the _custom-shaders_ directory or in child directories. 55 | 56 | Custom shaders for Minecraft: Bedrock Edition use GLSL language. You can find some of the examples of shaders in Minecraft's vanilla resource pack. We recommend using _entity.vertex_ / _entity.fragment_ as a scratch. 57 | 58 | If you locate your shader in one of the subdirectories, you should use relative path in your material declaration. 59 | -------------------------------------------------------------------------------- /documentation/static/en/page/mod/IndustrialCraft2.md: -------------------------------------------------------------------------------- 1 | [IC2](https://raw.githubusercontent.com/MineExplorer/IndustrialCraft_2/master/README.md ':include') -------------------------------------------------------------------------------- /documentation/static/en/page/other/contributing.md: -------------------------------------------------------------------------------- 1 | ## Minor Fixes 2 | If you found any minor mistake, you can notify me via: 3 | + E-mail: Ih01@i.ua 4 | + VK: [@igormelikhov](https://vk.com/igormelikhov) 5 | + Telegram: [@ichzerowan](https://t.me/ichzerowan) 6 | 7 | ## Contribution 8 | 9 | If you wish to help us improve articles and documentation, fork the 10 | documentation's [GitHub repository](https://github.com/mineprogramming/innercore-docs). 11 | All the required information about how to build the documentation can be found in repository's README.md file. -------------------------------------------------------------------------------- /documentation/static/images/dimensions-1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mineprogramming/innercore-docs/3f7125bb1d8437c3e096ae6e3a2e8e8ad6d1ee68/documentation/static/images/dimensions-1.jpg -------------------------------------------------------------------------------- /documentation/static/images/dimensions-2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mineprogramming/innercore-docs/3f7125bb1d8437c3e096ae6e3a2e8e8ad6d1ee68/documentation/static/images/dimensions-2.jpg -------------------------------------------------------------------------------- /documentation/static/images/dimensions-3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mineprogramming/innercore-docs/3f7125bb1d8437c3e096ae6e3a2e8e8ad6d1ee68/documentation/static/images/dimensions-3.jpg -------------------------------------------------------------------------------- /documentation/static/images/dimensions-4.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mineprogramming/innercore-docs/3f7125bb1d8437c3e096ae6e3a2e8e8ad6d1ee68/documentation/static/images/dimensions-4.jpg -------------------------------------------------------------------------------- /documentation/static/images/dimensions-5.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mineprogramming/innercore-docs/3f7125bb1d8437c3e096ae6e3a2e8e8ad6d1ee68/documentation/static/images/dimensions-5.jpg -------------------------------------------------------------------------------- /documentation/static/images/dimensions-6.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mineprogramming/innercore-docs/3f7125bb1d8437c3e096ae6e3a2e8e8ad6d1ee68/documentation/static/images/dimensions-6.jpg -------------------------------------------------------------------------------- /documentation/static/images/dimensions-7.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mineprogramming/innercore-docs/3f7125bb1d8437c3e096ae6e3a2e8e8ad6d1ee68/documentation/static/images/dimensions-7.jpg -------------------------------------------------------------------------------- /documentation/static/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Document 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /documentation/static/ru/README.md: -------------------------------------------------------------------------------- 1 | lmao -------------------------------------------------------------------------------- /documentation/static/ru/config/_navbar.md: -------------------------------------------------------------------------------- 1 | - Язык 2 | - [:ru: Русский](/ru/) 3 | - [:uk: English](/en/) 4 | -------------------------------------------------------------------------------- /documentation/static/ru/config/_sidebar.md: -------------------------------------------------------------------------------- 1 | - [Главная](/ru/) 2 | - Построение модов 3 | - [Структура модов](/ru/page/building-mods/mod_structure.md) 4 | - [Стандартный шаблон модов](/ru/page/building-mods/standart-mod-template.md) 5 | - [Ресурсы](/ru/page/building-mods/mod-resources.md) 6 | - [Компиляция в байткод](/ru/page/building-mods/bytecode-compilation.md) 7 | - [Базовые методы и переменные исполняемых файлов](/ru/page/building-mods/basic-methods-and-variables-of-executable-files.md) 8 | - [Библиотеки](/ru/page/building-mods/libraries.md) 9 | - [Глобальные методы и переменные CoreEngine](/ru/page/coreengine-global-methods-and-variables.md) 10 | - [CoreEngine Апи](/api/ ':ignore') 11 | 12 | - [Hello World](api/modules.html#helloWorld ':ignore :target=_self') 13 | -------------------------------------------------------------------------------- /documentation/static/ru/page/building-mods/basic-methods-and-variables-of-executable-files.md: -------------------------------------------------------------------------------- 1 | # Понятие параметра SCOPE 2 | 3 | Этот параметр используется только в методах для запуска других исполняемых файлов. Этот объект описывает новые переменные в пространстве имен запускаемого файла, где имя поля в этом объекте - имя новой переменной, а значение - соответсвенно ее значение.  Параметр SCOPE может быть не передан или иметь значение null, тогда никаких новых переменных не будет создано. 4 | 5 | Пример: 6 | 7 | ```javascript 8 | SCOPE это объект { 9 | x: 2, 10 | 11 | sqr: function(a){ 12 | return a * a; 13 | } 14 | } 15 | ``` 16 | 17 | В исполняемом файле, который запущен с таким SCOPE появятся переменная x со значением 2 и функция sqr, возводящая число в квадрат. 18 | 19 | В коде исполняемых файлов вне зависимости от API всегда есть набор стандартных методов и переменных, связанных со структурой мода и его файлами. Далее будут перечисленны все. 20 | 21 | Не зависят от типа исполняемого файла: 22 | 23 | Переменные: 24 | 25 | *''__name__'' - переменная, содержащая имя мода в виде строки, в основном используется в логах. 26 | *''__dir__'' - директория мода, которая содержит все его файлы, заканчивается на / 27 | *''__config__ ''- реализация основного конфига мода (config.json), который будет визуализирован в меню настройки модов. Обычно создавать дополнительные конфиги не приходится. 28 | *''__mod__ ''- java-объект самого мода, содержаший все остальные значения, техническая переменная. 29 | 30 | Методы: 31 | 32 | *''runCustomSource(path, SCOPE)'' - запускает исполняемый файл на указанном пути path (локальный путь в директории данного мода) с данным объектом SCOPE. Важно то, что этот файл должен быть описан в build.config и иметь тип custom. 33 | *''importLib(libName, moduleName)'' - импортирует указанный модуль из указанной библиотеки, где libName - имя файла библиотеки без расширения, а moduleName, имя нужного модуля в библиотеке или строка "*", в последнем случае будут импортированы все модули из данной библитеки. В самих библиотеках данный метод недоступен. 34 | 35 | Только в библиотеках: 36 | 37 | *''registerAPIUnit(moduleName, moduleValue)'' - регистрирует модуль библиотеки, который далее можно будет импортировать с помощью ''importLib(libName, moduleName)'' или ''importLib(libName, "*")'', где moduleName - имя модуля, а moduleValue - любое значение, которое вы хотите передать, обычно это объект с набором методов. 38 | 39 | Только в лаунчере: 40 | 41 | *''Launch(SCOPE)'' - запускает все основные файлы мода с данным SCOPE, если мод уже запущен, то выдаст исключение RuntimeException. 42 | -------------------------------------------------------------------------------- /documentation/static/ru/page/building-mods/bytecode-compilation.md: -------------------------------------------------------------------------------- 1 | Компиляция модов в байткод крайне полезна для релизных версий. Во-первых это позволяет увеличить быстродействие, а во-вторых шифрует исходный код, если это требуется. 2 | 3 | Компиляция производится через меню Inner Core, для этого вам нужно открыть список модов, найти там требуемый вам мод и открыть меню разработчика (кнопка с гаечным ключом). 4 | Порядок компиляции: 5 | 6 | - Убедитесь, что вы находитесь в режиме построения разработки (build type: develop). 7 | - Проверьте статус всех ваших исполняемых файлов, он должен быть "ok" для всех, в противном случае у вас возникли ошибки при запуске мода и их стоит исправить при компиляции. 8 | - Нажмите кнопку компиляции, подтвердите действие ("Yes"), после чего появится окно процесса компиляции, в зависимости от объема мода и мощности устройства, это займет от нескольких секунд до 10 минут. 9 | - Если во время компиляции возникли ошибки, то скорее всего вы не выполнили пункт 2. Откажитесь от переключения в релизный тип построения ("No") и исправльте ошибки. Если ошибок нет, то есть 2 варианта проблемы: либо файл, который надо скомпилировать, слишком большой, в этом случае надо разбить его на несколько (директории построения), либо он содержит незавершенный блок кода, в этом случае его надо объеденить с тем, где находится завершение к или просто перенести его (завершение) в нужный файл. 10 | - Если компиляция прошла успешна, перезапустите Inner Core, зайдите обратно в меню разработчика и убедитесь, что статус для всех файлов теперь "ok [bytecode]". 11 | 12 | Чтобы вернуться после компиляции к разработке мода, вам надо в том же меню разработчика нажать ту же кнопку (при условии, что build type: release) и подтвердить действие. После этого необходим перезапуск, чтобы мод перезагрузился в режиме разработчика. 13 | 14 | == Скрытие исходного кода == 15 | 16 | Если вам совсем не хочется делиться своими исходниками с другими, то после компиляции в релизной версии удалить все файлы с исходным кодом, кроме библиотек, они не будут нужны для работы. '''ВНИМАНИЕ'''!!! ВЫ НЕ СМОЖЕТЕ ИЗ СКОМПИЛИРОВАННОГО МОДА ПОЛУЧИТЬ ИСХОДНЫЙ КОД, ЭТО НЕВОЗМОЖНО. УДАЛЯЙТЕ ИСХОДНЫЙ КОД ТОЛЬКО УБЕДИВШИСЬ, ЧТО У ВАС ЕСТЬ ЕГО ПОЛНАЯ И АКТУАЛЬНАЯ РЕЗЕРВНАЯ КОПИЯ. 17 | -------------------------------------------------------------------------------- /documentation/static/ru/page/building-mods/standart-mod-template.md: -------------------------------------------------------------------------------- 1 | В большинстве случаев вам не потребуется импровизировать со структурой мода. Для этого тут описан шаблонный файл построения и то, какую структуру должен иметь мод с таким построением. 2 | 3 | Здесь приведено содержимое файла build.config: 4 | 5 | ```json 6 | { 7 | "defaultConfig":{ 8 | "buildType":"develop", 9 | "api":"CoreEngine", 10 | "libraryDir":"lib/" 11 | }, 12 | 13 | "resources":[ 14 | { 15 | "path":"res/", 16 | "resourceType":"resource" 17 | }, 18 | { 19 | "path":"gui/", 20 | "resourceType":"gui" 21 | } 22 | ], 23 | 24 | "buildDirs":[ 25 | { 26 | "targetSource":"main.js", 27 | "dir":"dev/" 28 | } 29 | ], 30 | 31 | "compile":[ 32 | { 33 | "path":"main.js", 34 | "sourceType":"mod" 35 | }, 36 | { 37 | "path":"launcher.js", 38 | "sourceType":"launcher" 39 | } 40 | ] 41 | } 42 | ``` 43 | 44 | ## Структура мода 45 | 46 | Начнем с API, он един для всего мода - это Core Engine. Основная часть дальнейшей документации будет как раз по нему, т.к. это самый распространенный и удобный вид API в большинстве случаев. 47 | 48 | Если вам нужно подключить какие то библиотеки, вы можете создать директорию lib в директории мода и копировать их туда, после чего их можно будет подключить из любых исполняемых файлов мода. 49 | 50 | Все ресурсы мода должны находиться в директории res, если их нет, она должна быть пустой. Аналогично для текстур интерфейса, только они должны находиться в директории gui. Как конкретно работают ресурсы вы сможете прочитать [[InnerCore/Ресурсы|здесь ]]. 51 | 52 | В директории мода должен присутствовать файл launcher.js, который по-умолчанию должен содержать только команду Launch(); Более подробная работа с лаунчером мода будет описана в другой главе. 53 | 54 | ## Исходный код мода 55 | 56 | Так же в моде обязана присутствовать директория построения dev, в которой должен быть файл построения .includes, в нем прописаны все локальные пути файлов, которые участвуют в построении в нужном порядке, так же он может содержать комментарии (// или #) и пустые строки 57 | 58 | Пример содержимого .includes: 59 | 60 | ```text 61 | // Предположим, что .includes находится в директории dev/ в моде 62 | // Этот файл должен находиться на пути dev/header.js 63 | header.js 64 | // Эти файлы соответсвенно должны находиться в dev/source/ 65 | source/blocks.js 66 | source/items.js 67 | //Все эти файлы будут собраны в файл main.js и запущены, как основной код мода. 68 | ``` 69 | 70 | ## Заключение 71 | 72 | Как говорилось в начале данная структура подходит для большинства модов и если вам не нужно ничего особенного, то оптимально использовать именно её. 73 | -------------------------------------------------------------------------------- /documentation/static/ru/page/coreengine-global-methods-and-variables.md: -------------------------------------------------------------------------------- 1 | 2 | Кроме [[InnerCore/Базовые_методы_и_переменные_исполняемых_файлов|базовых переменных и методов исполняемых файлов]], Inner Core предоставляет некоторое количество других глобальных методов. Их список приведён ниже: 3 | 4 | *getCoreAPILevel() - возвращает текущую версию API Inner Core, может использоваться для того, чтобы обеспечивать совместимость модов с прошлыми версиями Inner Core. Текущая версия - 8 5 | *runOnMainThread(func) - запускает функцию func на главном потоке Майнкрафта 6 | *getMCPEVersion() - возвращает текущую версию Майнкрафта в формате: 7 | 8 | ```javascript 9 | { 10 |     str: "1.0.3.12", // string representation 11 |     array: [1, 0, 3, 12], // array representation 12 |    main: 17 // array[0] * 17 + array[1] 13 | } 14 | ``` 15 | 16 | * addParticle(x, y, z, id, vx, vy, vz, data) - добавляет на координатах x, y, z ванильную частицу типа id и задаёт ей ускорение vx, vy, vz. data? 17 | * message(message) - выводит отладочное сообщение тёмно-зелёным цветом с префиксом "DEBUG: " в чат 18 | * warning(message) - выводит отладочное сообщение золотистым цветом с префиксом "WARNING: " в чат 19 | * error(message) - выводит отладочное сообщение тёмно-красным цветом с префиксом "ERROR: " в чат 20 | * m(messages...) - выводит несколько отладочных сообщений, разделённых запятыми, тёмно-зелёным цветом с префиксом "DEBUG: " в чат. Если одно из сообщений является объектом, он выведется как JSON-строка 21 | * bitmap(bitmap, title) - показывает диалоговое окно с изображением, взятым из параметра bitmap типа ''Bitmap'', и с заголовком title 22 | -------------------------------------------------------------------------------- /documentation/static/src/syntax/json.min.js: -------------------------------------------------------------------------------- 1 | (Prism.languages.json = { 2 | property: { pattern: /(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/, lookbehind: !0, greedy: !0 }, 3 | string: { pattern: /(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/, lookbehind: !0, greedy: !0 }, 4 | comment: { pattern: /\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/, greedy: !0 }, 5 | number: /-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i, 6 | punctuation: /[{}[\],]/, 7 | operator: /:/, 8 | boolean: /\b(?:false|true)\b/, 9 | null: { pattern: /\bnull\b/, alias: 'keyword' } 10 | }), 11 | (Prism.languages.webmanifest = Prism.languages.json); 12 | -------------------------------------------------------------------------------- /documentation/static/src/themes/fix.css: -------------------------------------------------------------------------------- 1 | .markdown-section { 2 | padding: 1rem 15px; 3 | } 4 | .sidebar-nav ul li p { 5 | margin: 0; 6 | } 7 | .sidebar-nav ul li ul li a { 8 | padding-top: 0; 9 | padding-bottom: 0; 10 | } -------------------------------------------------------------------------------- /gruntfile.js: -------------------------------------------------------------------------------- 1 | module.exports = function (grunt) { 2 | grunt.initConfig({ 3 | pkg: grunt.file.readJSON('package.json'), 4 | concat: { 5 | dist: { 6 | src: [ 7 | 'documentation/core-engine/declarations/com/zhekasmirnov/**/*.d.ts', 8 | 'documentation/core-engine/declarations/*.d.ts' 9 | ], 10 | dest: 'documentation/core-engine/headers/core-engine.d.ts' 11 | }, 12 | options: { 13 | banner: '/// \n\n' 14 | } 15 | }, 16 | 17 | typedoc: { 18 | build: { 19 | options: { 20 | out: './out/api/', 21 | name: 'Core Engine v2.1 API', 22 | readme: './README.md', 23 | theme: 'default', 24 | validation: { 25 | invalidLink: true 26 | }, 27 | entryPoints: ['./documentation/core-engine/headers/core-engine.d.ts'], 28 | 'sourcefile-url-prefix': 'https://github.com/mineprogramming/innercore-docs/blob/gh-pages/headers/', 29 | } 30 | } 31 | }, 32 | 33 | copy: { 34 | main: { 35 | files: [ 36 | { 37 | expand: true, 38 | flatten: true, 39 | src: 'documentation/core-engine/headers/*', 40 | dest: 'out/headers/' 41 | }, 42 | { 43 | expand: true, 44 | flatten: true, 45 | src: 'documentation/static/core-engine/images/*', 46 | dest: 'out/api/assets/images/pages/' 47 | }, 48 | { 49 | expand: true, 50 | src: '**/*', 51 | cwd: 'documentation/static/', 52 | dest: 'out' 53 | }, 54 | { 55 | expand: true, 56 | src: 'README.md', 57 | dest: 'out/en' 58 | }, 59 | { 60 | expand: true, 61 | src: 'README.md', 62 | dest: 'out' 63 | } 64 | ] 65 | } 66 | } 67 | }); 68 | 69 | grunt.loadNpmTasks('grunt-contrib-concat'); 70 | grunt.loadNpmTasks('grunt-contrib-copy'); 71 | grunt.loadNpmTasks('grunt-typedoc'); 72 | grunt.registerTask('docs_api', ['concat', 'typedoc', 'copy']); 73 | grunt.registerTask('copyf', ['copy']); 74 | }; 75 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "core-engine-api", 3 | "version": "2.0.0", 4 | "description": "InnerCore Docs v2", 5 | "devDependencies": { 6 | "docsify-cli": "^4.4.3", 7 | "grunt": "^1.4.1", 8 | "grunt-cli": "^1.4.3", 9 | "grunt-contrib-concat": "^2.0.0", 10 | "grunt-contrib-copy": "^1.0.0", 11 | "grunt-contrib-requirejs": "^1.0.0", 12 | "grunt-typedoc": "^0.2.4", 13 | "nlfurniss-typedoc-plugin-sourcefile-url": "^2.0.0", 14 | "typedoc": "^0.22.11", 15 | "typescript": "^4.5.4", 16 | "underscore.string": "^3.3.6" 17 | }, 18 | "scripts": { 19 | "serve-docs": "docsify serve ./documentation/static", 20 | "serve-out": "docsify serve ./out", 21 | "build": "grunt docs_api", 22 | "build-serve": "npm run build && npm run serve-out" 23 | }, 24 | "repository": { 25 | "type": "git", 26 | "url": "https://github.com/mineprogramming/innercore-docs.git" 27 | }, 28 | "license": "GPL-3.0" 29 | } 30 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ES5", 4 | "lib": [ 5 | "ES6" 6 | ] 7 | }, 8 | "include": [ 9 | "documentation/core-engine/headers/core-engine.d.ts" 10 | ], 11 | "exclude": [ 12 | "documentation/static/**", 13 | ] 14 | } --------------------------------------------------------------------------------