Comments (24)
Certainly you can add an enum argument
from levilamina.
Maybe #115 can help you
from levilamina.
No, you misunderstood me. I meant no <name: type> argument, just text like "add" and "stop".
from levilamina.
argument <op: string>?
from levilamina.
for example, the camerashake command has two overloads: the first "add" and the second "stop".
"add" and "stop" do not have <op: string>, they are just text without <> and [].
from levilamina.
This may not be possible
from levilamina.
For example, MC's /gametest is the same,
from levilamina.
I hope there is a way, because without this it is impossible to beautifully implement different functionality for one team.
from levilamina.
from levilamina.
You can refer to this paragraph
from levilamina.
yes, thanks! I'll try it now
from levilamina.
seems to work, but very strange.
and whatever I enter, the parser throws me on the inspect overload:
Upd: I guess the parser has priority for short commands ...
from levilamina.
With two String, BDS can't tell if it's the first or the second. This is no longer part of the LL discussion.
from levilamina.
Please use back to enum, this may also be the reason why BDS uses that method internally
Sorry I couldn't help you.
from levilamina.
thanks for trying to help.
I hope that soon it will be possible to add something like "names" to overloads, like add & stop in camerashake, etc.
from levilamina.
No, you misunderstood me. I meant no <name: type> argument, just text like "add" and "stop".
you should call CommandParameterData::addOptions()
for example:
from levilamina.
I'll now try it
from levilamina.
what is the CommandParameterOption? what heading is it in?
from levilamina.
add enum CommandParameterOption in your code
from levilamina.
ok, but it doesn't solve my current parsing problem.
or am I missing something?
from levilamina.
- [TODO] BDS CommandRegistery API Docs
from levilamina.
Sorry i didn't get the gist of addOptions() yesterday.
Today I figured out what you advised me, and everything works, thanks!
I think the question can be closed (but the documentation for the CommandRegistry API will still be useful).
from levilamina.
Thank you for your reply. Documentation will be available as soon as possible
from levilamina.
Thank you for your reply. Documentation will be available as soon as possible
How to make the parser work adequately with different arguments in 2 overloads?
For example:
/cmd
/cmd enum
And if I enter /cmd enum, then it would choose enum, and not the first overload option?
from levilamina.
Related Issues (20)
- [Feature]: Improve Hook Framework
- [Bug]: 修复Dimension类的虚表
- [Feature]: 添加 材质包加密 支持 HOT 1
- -fuse_mimalloc by default
- [Bug]: 无法安装liteloaderBDS HOT 3
- [Bug]: 监听玩家操作方块容器事件刷屏 - legacy-script-engine HOT 10
- [Feature]: 期望可以删除监听事件clearList(id) - legacy-script-engine-quickjs
- [Bug]: Actor::isSimulatedPlayer崩服 HOT 1
- [Bug]: Installing dependencies HOT 1
- [Bug]: Canceling an event
- [Feature]: Addition PlayerMoveEvent HOT 3
- [Bug]: 玩家数据库存入假人数据
- [Bug] Automatic<Dimension, int> hash 计算不正确
- [Feature]: disable color output if the console not support
- [Bug]: build failed HOT 1
- Build HOT 1
- [Bug]: plugin cannot be compiled HOT 1
- [Bug]: #1499再现 HOT 1
- [Proposal]: Rename Plugin to Mod HOT 6
- [Bug]: llse NBT.parseSNBT() 无法正常识别空的ByteArray(SNBT格式: [B;])
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from levilamina.