8000 GitHub - mooner1022/Laika: Remote-Kakao compatible Kotlin-coroutines based client (WIP)
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

mooner1022/Laika

Repository files navigation


Laika

!! Laika is still in early development stage, any structure or usage can be changed !!

`Laika 🐕` is a Remote-Kakao compatible Kotlin-coroutines based server (WIP)

✔ Any PRs are welcome!

Installation (build.gradle.kts)

  • Add jitpack url
repositories {
    /* ... */
    maven(url = "https://jitpack.io")
}
  • Add Laika dependency
dependencies {
    implementation("com.github.mooner1022:Laika:V0.0.1-A1")
}

Usage

  • Create Laika instance
val laika = Laika {
    hostname = "192.168.0.11" // Replace with your server's IP
    port = 2323               // Server port
    maxRetryAttempt = 3
}
  • Set client event listener and create reply message
laika.on<MessageReceiveEvent> {
    if (message.content == "!hello") {
        message.room.send("Hello, ${message.sender.name} on ${message.room.name}!")
    }
}
  • Start server
laika.start()

Full example code

suspend fun main() {
    val laika = Laika {
        hostname = "192.168.0.11" // Replace with your server's IP
        port = 2323               // Server port
        maxRetryAttempt = 3
    }

    laika.on<MessageReceiveEvent> {
        if (message.content == "!hello") {
            message.room.send("Hello, ${message.sender.name} on ${message.room.name}!")
        }
    }

    laika.start()
}

License

Designed and developed by 2022 mooner1022 (Minki Moon)

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/>.

About

Remote-Kakao compatible Kotlin-coroutines based client (WIP)

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

0