-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
how to cast skill? #39
Comments
I dont know! :) I also dont know how i get the info whether or not they can
actually skill something..
…On Tue, Jan 15, 2019, 00:13 sijia xu ***@***.*** wrote:
I look the dotaclient code, it seems right now it can only use three types
of actions: move, attack and do nothing.
I want to cast the q,w,e,r skills in NeverMore, so is there a way to do
that?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#39>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AHXSRNX2GRaMQ2QWbND_0JLyZ8GVTKy-ks5vDY2kgaJpZM4aAcOZ>
.
|
Oh, sad info.. |
I will implement this today if I have time in my code branch. |
In my code I currently return the following at level 1 with no abilities selected:
That was printed by this: I need to next implement the action selection, but this begs a question since certain actions are "atomic" and thus don't prevent other actions from being taken at the same time. How do we want to model that? |
I think it needs hard code some rules, like if I cast q skill of NeverMore, then in the following 1 second cannot execute other actions. but how do you plan to transfer this action info to Lua sides? another problem, it also needs to check whether the skill is ready to cast right now, like check the mana, cooldown and casting distance. I look at the message Ability, maybe can get something from that. |
That part is easy and learnable with delays as well as hard-coded cast points if we want to be more modeled vs model-free. Honestly, hard coding "don't do anything for next 1 second" is bad, as there will be times where it is better to cancel a cast then die trying to execute it. All the info you ask for: 'mana, cd, distance, fully castable' I can get already |
Dota as a game doesnt support multiple actions per tick though afaik.
Leveling would be one action
…On Tue, Jan 15, 2019, 18:59 sijia xu ***@***.*** wrote:
I think it needs hard code some rules, like if I cast q skill of
NeverMore, then in the following 1 second cannot execute other actions. but
how do you plan to transfer this action info to Lua sides?
another problem, it also needs to check whether the skill is ready to cast
right now, like check the mana, cooldown and casting distance. I look at
the message Ability, maybe can get something from that.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#39 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AHXSRJeEqyEbvRXCUch-L8LD3AOIG6mlks5vDpWQgaJpZM4aAcOZ>
.
|
It does via a queue trick I believe... hm... maybe not. Perhaps we should implement a way for sending a "queue" of "atomic" actions and they get executed 1 per frame ? |
All of these can be done while doing other things. I agree, not "at the same time", but sequentially 1 per frame.
|
Nostradaemous, do you know if theres a protobuf for leveling and buying
items and such? Im pretty sure there must be one
…On Tue, Jan 15, 2019, 19:15 Nostrademous ***@***.*** wrote:
All of these can be done while doing other things. I agree, not "at the
same time", but sequentially 1 per frame.
int ActionImmediate_PurchaseItem ( sItemName )
Command a bot to purchase the specified item. Item names can be found here.
ActionImmediate_SellItem( hItem )
Command a bot to sell the specified item
ActionImmediate_DisassembleItem( hItem )
Command a bot to disassemble the specified item
ActionImmediate_SetItemCombineLock( hItem, bLocked )
Command a bot to lock or unlock combining of the specified item
ActionImmediate_SwapItems( index1, index2 )
Command a bot to swap the items in index1 and index2 in their inventory. Indices are zero based with 0-5 corresponding to inventory, 6-8 are backpack and 9-15 are stash
ActionImmediate_Courier( hCourier, nAction )
Command the courier specified by hCourier to perform one of the courier Actions.
ActionImmediate_Buyback()
Tell a hero to buy back from death.
ActionImmediate_Glyph()
Tell a hero to use Glyph.
ActionImmediate_LevelAbility ( sAbilityName )
Command a bot to level an ability or a talent. Ability and talent names can be found here
ActionImmediate_Chat( sMessage, bAllChat )
Have a bot say something in team chat, bAllChat true to say to all chat instead
ActionImmediate_Ping( fXCoord, fYCoord, bNormalPing )
Command a bot to ping the specified coordinates with bNormalPing setting the ping type
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#39 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AHXSRDG-YxsjZB-QbDSk7ZtdLXttJYxOks5vDplegaJpZM4aAcOZ>
.
|
If not, I'm not sure what you mean.... |
Are those official?
…On Tue, Jan 15, 2019, 19:21 Nostrademous ***@***.*** wrote:
You mean like:
https://github.com/Nostrademous/dotaservice/blob/526df38ff4b69c62d61f9e011c470de1adff73f5/dotaservice/protos/dota_gcmessages_common_bot_script.proto#L332
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#39 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AHXSRH3Hm4nmbWRT8G8nKCywihUfhrEFks5vDprDgaJpZM4aAcOZ>
.
|
I have a question, after we fill the protobuf message of skills/leveling/buy items, it also need to hard code the corresponding Lua execution code, is that right? |
I'm not sure I understand what you are asking or trying to do. I would think that if our agent decides it wants to level an ability it would just send a message to the Lua side of our bot to do so. |
Yes, per my above message. Also, I swear, I think for "atomic" action you can just execute them one after the other in the same frame and the will all get done. |
@TimZaman do you mind if we mod the "lua" code to use the old command processor I wrote to work with the file throughput method? We could then easily add all the previous functions I implemented (with some minor tweaks for debug print) |
What would that look like? The constraints I feel we have are:
- Everything should be fast, only add lua code if we use it (invoking lua
code was slow for me, even a no-op [mind you i am running at 10x
host_timescale!)
- Everything should be conform protobuf: if its not in the proto, we can't
do it
WDYT?
…On Tue, Jan 15, 2019 at 7:46 PM Nostrademous ***@***.***> wrote:
@TimZaman <https://github.com/TimZaman> do you mind if we mod the "lua"
code to use the old command processor I wrote to work with the file
throughput method?
https://github.com/pydota2/pydota2_archive/blob/master/pydota2/bot_code/bots/actions/cmd_processor.lua
We could then easily add all the previous functions I implemented (with
some minor tweaks for debug print)
https://github.com/pydota2/pydota2_archive/tree/master/pydota2/bot_code/bots/actions
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#39 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AHXSRAv-gFV0WqIYuvzstt4gXvb2e04zks5vDqCmgaJpZM4aAcOZ>
.
|
I would like one exception to be made for a custom protobuf class called "CustomAction" or something. This is to enable people that are writing ML-agents using DotaService to have the flexibility of implementing their own "non-primitive" actions. What I mean is this: |
Hmmmmmmm... Im slightly hesitant. What would that look like?
…On Wed, Jan 16, 2019, 09:14 Nostrademous ***@***.*** wrote:
Everything should be conform protobuf: if its not in the proto, we can't
do it WDYT?
I would like one exception to be made for a custom protobuf class called
"CustomAction" or something. This is to enable people that are writing
ML-agents using DotaService to have the flexibility of implementing their
own "non-primitive" actions.
What I mean is this:
Currently we are supporting actions like DOTA_UNIT_ORDER_MOVE_TO_POSITION
and DOTA_UNIT_ORDER_ATTACK_TARGET but what if someone wanted to "script"
a whole mode like "lane_farming" which they hard-coded scripted in lua as a
function that does appropriate movements, attacks, ability usage, etc.
where the ML-agent only controls switching between "modes" rather than
making each and every individual primitive action.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#39 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AHXSRMP4qnh1QsOuL1iHfZstnXm_lI_sks5vD13kgaJpZM4aAcOZ>
.
|
Haven't given it too much deep thought. On the surface probably simply:
Then in the action processor the person could add a stub for "elseif action == 'DOTA_UNIT_ORDER_CUSTOM'" and map the action_name to the predefined lua behavior for supplied units. |
I look the dotaclient code, it seems right now it can only use three types of actions: move, attack and do nothing.
I want to cast the q,w,e,r skills in NeverMore, so is there a way to do that?
The text was updated successfully, but these errors were encountered: