Toggle navigation
Toggle navigation
This project
Loading...
Sign in
유병우
/
lostark-discord-bot
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
유병우
2022-05-09 21:18:05 +0900
Browse Files
Options
Browse Files
Download
Plain Diff
Commit
f1c1e0fae95d5e1e5453deed978d44ee31d49cac
f1c1e0fa
2 parents
644a4bdc
4f3079fe
Merge branch 'feature/help' into develop
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
54 additions
and
0 deletions
commands/help.js
commands/help.js
View file @
f1c1e0f
const
{
SlashCommandBuilder
}
=
require
(
'@discordjs/builders'
);
const
{
MessageEmbed
}
=
require
(
'discord.js'
);
module
.
exports
=
{
data
:
new
SlashCommandBuilder
()
.
setName
(
'도움'
)
.
setDescription
(
'롸!봇의 명령어에 대한 설명입니다.'
)
.
addStringOption
((
option
)
=>
option
.
setName
(
"명령어"
)
.
setDescription
(
"명령어의 설명 조회"
)
.
setRequired
(
false
)
),
async
execute
(
interaction
)
{
const
helpCommand
=
interaction
.
options
.
getString
(
"명령어"
);
if
(
helpCommand
===
null
)
{
const
helpEmbed
=
new
MessageEmbed
()
.
setColor
(
'#0099ff'
)
.
setTitle
(
'롸!봇 사용법'
)
.
addField
(
'/도움'
,
'명령어 설명 및 목록'
,
true
)
.
addField
(
'/도움 <명령어>'
,
'명령어 상세 설명'
,
true
)
.
addField
(
'/마리샵'
,
'마리샵 정보 조회'
,
true
)
.
addField
(
'/정보 <닉네임>'
,
'전투정보실 조회'
,
true
)
.
addField
(
'/로아와 <닉네임>'
,
'로아와 조회'
,
true
);
await
interaction
.
reply
({
embeds
:
[
helpEmbed
],
allowedMentions
:
{
repliedUser
:
false
}});
}
else
if
(
helpCommand
===
"도움"
)
{
const
helpEmbed
=
new
MessageEmbed
()
.
setColor
(
'#0099ff'
)
.
setTitle
(
`/도움 <명령어> 사용방법`
)
.
setDescription
(
`<명령어>에 해당하는 명령어의 사용법을 알 수 있습니다.`
);
await
interaction
.
reply
({
embeds
:
[
helpEmbed
],
allowedMentions
:
{
repliedUser
:
false
}});
}
else
if
(
helpCommand
===
"마리샵"
)
{
const
helpEmbed
=
new
MessageEmbed
()
.
setColor
(
'#0099ff'
)
.
setTitle
(
`/마리샵 사용방법`
)
.
setDescription
(
`현재 마리샵과 이전, 전전의 마리샵의 정보를 조회합니다.`
);
await
interaction
.
reply
({
embeds
:
[
helpEmbed
],
allowedMentions
:
{
repliedUser
:
false
}});
}
else
if
(
helpCommand
===
"정보"
)
{
const
helpEmbed
=
new
MessageEmbed
()
.
setColor
(
'#0099ff'
)
.
setTitle
(
`/정보 <닉네임> 사용방법`
)
.
setDescription
(
`<닉네임>에 해당하는 캐릭터의 전투정보실 정보를 임베드로 출력합니다.`
);
await
interaction
.
reply
({
embeds
:
[
helpEmbed
],
allowedMentions
:
{
repliedUser
:
false
}});
}
else
if
(
helpCommand
===
"로아와"
)
{
const
helpEmbed
=
new
MessageEmbed
()
.
setColor
(
'#0099ff'
)
.
setTitle
(
`/로아와 <닉네임> 사용방법`
)
.
setDescription
(
`<닉네임>에 해당하는 캐릭터의 로아와 정보를 브라우저로 엽니다.`
);
await
interaction
.
reply
({
embeds
:
[
helpEmbed
],
allowedMentions
:
{
repliedUser
:
false
}});
}
else
{
await
interaction
.
reply
(
"해당 명령어는 없습니다."
);
}
},
};
\ No newline at end of file
...
...
Please
register
or
login
to post a comment