K
Kord8mo ago
Ray

`Unresolved reference: int` when creating input command

I'm following the example in the very sparse wiki, but it doesn't seem to be valid anymore (it was last updated over 2 years ago). I get the error Unresolved reference: int, string seems to not show errors though. Any ideas on how to fix this? Or are there any more complex sample projects I could look at?
kord.createGuildChatInputCommand(
Snowflake(556525343595298817),
"sum",
"A slash command that sums two numbers"
) {
string("first_number", "The first operand") {
required = true
}
int("second_number", "The second operand") {
required = true
}
}
kord.createGuildChatInputCommand(
Snowflake(556525343595298817),
"sum",
"A slash command that sums two numbers"
) {
string("first_number", "The first operand") {
required = true
}
int("second_number", "The second operand") {
required = true
}
}
GitHub
Home
Idiomatic Kotlin Wrapper for The Discord API. Contribute to kordlib/kord development by creating an account on GitHub.
33 Replies
gdude
gdude8mo ago
I think it's number now, but use your IDE's autocomplete Eg by typing this. and seeing what you get Alternatively maybe you need to import the functions Again, your IDE can help with that
Ray
RayOP8mo ago
Thanks, number worked. The IDE hinting wasn't that helpful :sweat:
No description
Tic
Tic8mo ago
integer function exists
Ray
RayOP8mo ago
:PatrickThink: Oh it's the full word
LustigerLurch
LustigerLurch8mo ago
it was renamed to integer, the wiki isn't really up to date :pained_smile:
Tic
Tic8mo ago
Yes I would like to update it .. but we don't have the possibility to do that
matytyma
matytyma8mo ago
yeah...
Tic
Tic8mo ago
Is there a way to .. authorize people to modify the wiki and create PR (I think there is no PR on wiki but maybe)
matytyma
matytyma8mo ago
You can't even set like access roles? Poor GitHub
No description
gdude
gdude8mo ago
That's an Enterprise feature I've been thinking about moving off of GH someday for a bunch of reasons, and that's one of them
Tic
Tic8mo ago
And gitbook is not free?
gdude
gdude8mo ago
use writerside, or mkdocs with material for mkdocs
Tic
Tic8mo ago
Never tried but why not if it's readable directly on github for the user
gdude
gdude8mo ago
you'd publish it to a site anyway
matytyma
matytyma8mo ago
we've got GH pages, so... we could even go with pure Markdown
gdude
gdude8mo ago
pure markdown is a bad UX
Tic
Tic8mo ago
Yes but commonly used so the user is habit to use it
matytyma
matytyma8mo ago
writerside sounds like the best option to me then
gdude
gdude8mo ago
writerside search requires an algolia account right now for some reason mkdocs-material has search built in
matytyma
matytyma8mo ago
gdude
gdude8mo ago
JB has official docs on uploading the algolia indexes now at least that was pain before
matytyma
matytyma8mo ago
we might go without search at first
gdude
gdude8mo ago
it's relatively easy just annoying algolia has a free tier too
matytyma
matytyma8mo ago
ik
gdude
gdude8mo ago
PRs are kinda the way to go for collaborative editing
gdude
gdude8mo ago
ok nice I fixed the kordex one
No description
Ray
RayOP8mo ago
I can create updates as I go, though usually I prefer to making bigger commits if I'm only making small changes to docs. Are there commit style guidelines for the repo? Or I guess that can be discussed in the PR
LustigerLurch
LustigerLurch8mo ago
i don't think there are any guidelines for the wiki repo, i basically haven't touched it
Ray
RayOP8mo ago
Too lazy to fork and PR properly, so here's a minor update
LustigerLurch
LustigerLurch8mo ago
thanks a lot, do you have a github account that i can set as the author for the commit?
Ray
RayOP8mo ago
GitHub
RaymondLWong - Overview
RaymondLWong has 9 repositories available. Follow their code on GitHub.
LustigerLurch
LustigerLurch8mo ago
applied it 👍

Did you find this page helpful?