Page 1 of 3 1 2 3 LastLast
Results 1 to 10 of 25

Thread: February 27 Bot Update

  1. #1
    Valve Developer
    Join Date
    Sep 2011
    Posts
    1,646

    February 27 Bot Update

    • Bot scripts now have Workshop pages, and the in-game selector links to those pages.
    • Added dump_modifier_list which dumps the name of every modifier to the console.
    • Added GetAttackCombatProficiency( hTarget ) and GetDefendCombatProficiency( hAttacker ) functions to the unit bot script API.
    • Fixed how how handles are cleaned up when entities are deleted, scripts should more accurately see handles becoming nil.

  2. #2
    Basic Member
    Join Date
    Dec 2016
    Posts
    598
    Quote Originally Posted by ChrisC View Post
    • Added GetAttackCombatProficiency( hTarget ) and GetDefendCombatProficiency( hAttacker ) functions to the unit bot script API.
    Can you provide information regarding what information they provide? I checked the wiki and didn't see them there.

  3. #3
    Valve Developer
    Join Date
    Sep 2011
    Posts
    1,646
    Oh yeah I should update the wiki -- they basically provide a straight damage multiplier between the two units. Mostly useful when attacking things like towers and siege units.

    Also, I updated the Workshop Tools to support specifying a preview image for the Workshop page for your scripts.

  4. #4
    Basic Member
    Join Date
    Dec 2016
    Posts
    598
    Quote Originally Posted by ChrisC View Post
    Oh yeah I should update the wiki -- they basically provide a straight damage multiplier between the two units. Mostly useful when attacking things like towers and siege units.
    I assume the multiplier only really affects right-click damage on said units and not useful for abilities like Jakiro's Liquid Fire being used on Tower.

    Offhand I'm not sure where Brewmaster in his Ult form with Earth Spirit getting a 300% damage multiplier would fall either.

  5. #5
    When I select a script, it just says browse workshop.

  6. #6
    Valve Developer
    Join Date
    Sep 2011
    Posts
    1,646
    Quote Originally Posted by DreadedGhoul575 View Post
    When I select a script, it just says browse workshop.
    Hm, probably something related to changing the workshop item type. I'll take a look.

  7. #7
    Valve Developer
    Join Date
    Sep 2011
    Posts
    1,646
    Quote Originally Posted by nostrademous View Post
    I assume the multiplier only really affects right-click damage on said units and not useful for abilities like Jakiro's Liquid Fire being used on Tower.

    Offhand I'm not sure where Brewmaster in his Ult form with Earth Spirit getting a 300% damage multiplier would fall either.
    Sorry yeah, it's strictly for attack damage.

  8. #8
    Basic Member
    Join Date
    May 2014
    Posts
    226
    Quote Originally Posted by ChrisC View Post
    • Fixed how how handles are cleaned up when entities are deleted, scripts should more accurately see handles becoming nil.
    Thank you ChrisC, now my game doesn't crash anymore when I made Chen and Enchantress control all the neutrals. But I have some questions
    1. I have this error
    Code:
    [VScript] Script Runtime Error: ...a 2 beta\game\dota\scripts\vscripts\bots\bot_generic.lua:460: This object has been deleted from C++ and no longer exists. (Use :IsNull() to detect this.)
    stack traceback:
    	[C]: in function 'IsFullyCastable'
    	...a 2 beta\game\dota\scripts\vscripts\bots\bot_generic.lua:460: in function 'ConsiderShockWave'
    	...a 2 beta\game\dota\scripts\vscripts\bots\bot_generic.lua:97: in function 'MinionThink'
    	...beta\game\dota\scripts\vscripts\bots\bot_enchantress.lua:7: in function <...beta\game\dota\scripts\vscripts\bots\bot_enchantress.lua:5>
    And this is the line
    Code:
    function ConsiderShockWave(hMinionUnit)
    
    	local npcBot = GetBot();
    	
    	-- Make sure it's castable
    	if ( not abilitySW:IsFullyCastable() )  <========== Line 460 
    	then 
    		return BOT_ACTION_DESIRE_NONE, 0;
    	end
    ...
    This error doesn't caused any crash, but what should I add to check in order to make that error disappear? Can I use IsNull() like "... not abilitySW:IsNull() ..." ? BTW, that ability is this "satyr_hellcaller_shockwave" owned by "npc_dota_neutral_satyr_hellcaller".
    2. What does it means?
    Code:
    1336(1645.852402):  Failed to run script 'C:\Program Files (x86)\Steam\steamapps\common\dota 2 beta\game\dota\scripts\vscripts\bots\bot_enchantress.lua'!
    1335(1645.852378):  Script Runtime Error: ...beta\game\dota\scripts\vscripts\bots\bot_enchantress.lua:1: attempt to call global 'GetScriptDirectory' (a nil value)
    stack traceback:
    	...beta\game\dota\scripts\vscripts\bots\bot_enchantress.lua:1: in main chunk
    It makes my game crash in one game, but in another game it works fine even though there is Enchantress in the game. Here is the link to my complete code http://dev.dota2.com/showthread.php?...=1#post1421527. This is line 1 in bot_enchantress.lua
    Code:
    local minion = dofile( GetScriptDirectory().."/MinionUtility" )
    and here is the dump file
    Last edited by arz_on4dt; 02-27-2017 at 09:43 PM.

  9. #9
    Basic Member
    Join Date
    Dec 2016
    Posts
    26
    After today's update, players can not use custom scripts in games.Also we can subscribe it,but it doesn't appear in the drop-down menu.And I can not update my script in the workshop tools.

  10. #10
    Basic Member
    Join Date
    Jan 2016
    Posts
    7
    Quote Originally Posted by adamqqq View Post
    After today's update, players can not use custom scripts in games.Also we can subscribe it,but it doesn't appear in the drop-down menu.And I can not update my script in the workshop tools.
    yes, thats right, after selecting "use" on certain script that is available, the dropdown button stays on "browse ..."

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •