{"id":23102477,"url":"https://github.com/404setup/vico","last_synced_at":"2025-04-03T21:26:49.537Z","repository":{"id":267472230,"uuid":"901182023","full_name":"404Setup/Vico","owner":"404Setup","description":null,"archived":false,"fork":false,"pushed_at":"2024-12-11T12:04:19.000Z","size":80,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-09T09:28:50.718Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/404Setup.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-12-10T07:32:30.000Z","updated_at":"2024-12-11T12:04:23.000Z","dependencies_parsed_at":"2024-12-10T15:23:20.870Z","dependency_job_id":"a1b94304-199c-4bea-8125-9a2289aa5d60","html_url":"https://github.com/404Setup/Vico","commit_stats":null,"previous_names":["404setup/vico"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/404Setup%2FVico","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/404Setup%2FVico/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/404Setup%2FVico/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/404Setup%2FVico/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/404Setup","download_url":"https://codeload.github.com/404Setup/Vico/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247081059,"owners_count":20880366,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-16T23:59:47.094Z","updated_at":"2025-04-03T21:26:49.518Z","avatar_url":"https://github.com/404Setup.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# VicoLib\nProvides a reusable API for easy development\n\n## Update Tool\nSupport: Github Release, Hangar, Modrinth, Spigot, Spiget\n\n## MessageSender\nEasy to use Kyori API operations\n\n```Java\n// You cannot use this method to create new instances everywhere.\n//It should only be called once during the lifetime of your plugin.\nVicoImpl plugin = VicoAPI.getVicoPlugin(); \n\nplugin.getMessageSender().sendMessage(\"message\", sender);\nplugin.getMessageSender().close(); // Called when the plugin is closed\n```\n\n## Player teleport\nIt is just a very simple API and does not work with ProxyServer.\n\n```Java\n// You cannot use this method to create new instances everywhere.\n//It should only be called once during the lifetime of your plugin.\nVicoImpl plugin = VicoAPI.getVicoPlugin();\n\n// In folia, it always returns true\nplugin.getPluginPlayer().teleport(player, location);\nCompletableFuture\u003cBoolean\u003e result = plugin.getPluginPlayer().teleportAsync(player, location);\n```\n\n## Scheduler\nVico has two types of schedulers, namely Proxy scheduler and PluginServer scheduler.\n\n### Proxy Scheduler\n\n```Java\nVicoAPI.getProxyScheduler(proxyServer).runAsyncOnProxy(this, () -\u003e System.out.println(\"ProxyServer test\"));\nVicoAPI.getProxyScheduler(proxyServer).runAsyncOnPlugin(this, () -\u003e System.out.println(\"ProxyServer test\"));\n```\n\n### Plugin Scheduler\n\nProper use of PluginSchedulerBuilder can reduce a lot of boilerplate code and reduce the workload of developers, \nbut you still need to distribute the tasks reasonably, which is for Folia compatibility considerations.\n\nExcept for some broken APIs, it is not that difficult to be compatible, and the standard API is basically stable.\n\n```java\nPluginSchedulerBuilder.builder(this).sync().setTask(() -\u003e System.out.println(\"PluginServer test\")).run();\n\n// In Spigot and Paper, this is equivalent to the following code\nBukkit.getScheduler().runTask(this, () -\u003e System.out.println(\"PluginServer test\"));\n\n// In Folia\nBukkit.getGlobalRegionScheduler().runNow(this, (e) -\u003e System.out.println(\"PluginServer test\"));\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F404setup%2Fvico","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F404setup%2Fvico","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F404setup%2Fvico/lists"}