https://github.com/perryvw/customheroselection
Custom hero selection in Panorama/Lua for Dota 2 custom games
https://github.com/perryvw/customheroselection
Last synced: about 1 year ago
JSON representation
Custom hero selection in Panorama/Lua for Dota 2 custom games
- Host: GitHub
- URL: https://github.com/perryvw/customheroselection
- Owner: Perryvw
- License: mit
- Created: 2015-07-24T17:33:04.000Z (almost 11 years ago)
- Default Branch: master
- Last Pushed: 2016-07-09T17:44:02.000Z (almost 10 years ago)
- Last Synced: 2025-03-26T07:36:37.976Z (about 1 year ago)
- Language: JavaScript
- Size: 10.7 KB
- Stars: 26
- Watchers: 7
- Forks: 13
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# CustomHeroSelection
Custom hero selection in Panorama/Lua for Dota 2 custom games
Gif video of the result: http://gfycat.com/SelfishGrippingIlladopsis
The screen is visible by default as soon as the player gets ingame. To use this successfully use this first force a default hero:
```lua
GameRules:GetGameModeEntity():SetCustomGameForceHero( "npc_dota_hero_jakiro" )
```
Then listen for the game_rules_state_change event and to the handler add:
```lua
if GameRules:State_Get() == DOTA_GAMERULES_STATE_HERO_SELECTION then
HeroSelection:Start()
```