-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
14 changed files
with
1,171 additions
and
0 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
MIT License | ||
|
||
Copyright (c) 2018 | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# RLBotPythonExample | ||
Example of a python bot using the RLBot framework | ||
|
||
## Installation | ||
|
||
### Video guide | ||
|
||
https://www.youtube.com/watch?v=UjsQFNN0nSA | ||
|
||
### Plain instructions | ||
|
||
1. Make sure you've installed [Python 3.6 64 bit](https://www.python.org/ftp/python/3.6.5/python-3.6.5-amd64.exe). During installation: | ||
- Select "Add Python to PATH" | ||
- Make sure pip is included in the installation | ||
2. Open Rocket League | ||
3. Download or clone this repository | ||
3. In the files from the previous step, find and double click on run-gui.bat | ||
4. Click the 'Run' button | ||
|
||
## Changing the bot | ||
|
||
- Bot behavior is controlled by `python_example/python_example.py` | ||
- Bot appearance is controlled by `python_example/appearance.cfg` | ||
|
||
See https://github.com/RLBot/RLBotPythonExample/wiki for documentation and tutorials. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
@echo off | ||
:: This file is taken from chocolatey: | ||
:: https://github.com/chocolatey/choco/blob/master/src/chocolatey.resources/redirects/RefreshEnv.cmd | ||
:: | ||
:: RefreshEnv.cmd | ||
:: | ||
:: Batch file to read environment variables from registry and | ||
:: set session variables to these values. | ||
:: | ||
:: With this batch file, there should be no need to reload command | ||
:: environment every time you want environment changes to propagate | ||
|
||
::echo "RefreshEnv.cmd only works from cmd.exe, please install the Chocolatey Profile to take advantage of refreshenv from PowerShell" | ||
echo | set /p dummy="Refreshing environment variables from registry for cmd.exe. Please wait..." | ||
|
||
goto main | ||
|
||
:: Set one environment variable from registry key | ||
:SetFromReg | ||
"%WinDir%\System32\Reg" QUERY "%~1" /v "%~2" > "%TEMP%\_envset.tmp" 2>NUL | ||
for /f "usebackq skip=2 tokens=2,*" %%A IN ("%TEMP%\_envset.tmp") do ( | ||
echo/set "%~3=%%B" | ||
) | ||
goto :EOF | ||
|
||
:: Get a list of environment variables from registry | ||
:GetRegEnv | ||
"%WinDir%\System32\Reg" QUERY "%~1" > "%TEMP%\_envget.tmp" | ||
for /f "usebackq skip=2" %%A IN ("%TEMP%\_envget.tmp") do ( | ||
if /I not "%%~A"=="Path" ( | ||
call :SetFromReg "%~1" "%%~A" "%%~A" | ||
) | ||
) | ||
goto :EOF | ||
|
||
:main | ||
echo/@echo off >"%TEMP%\_env.cmd" | ||
|
||
:: Slowly generating final file | ||
call :GetRegEnv "HKLM\System\CurrentControlSet\Control\Session Manager\Environment" >> "%TEMP%\_env.cmd" | ||
call :GetRegEnv "HKCU\Environment">>"%TEMP%\_env.cmd" >> "%TEMP%\_env.cmd" | ||
|
||
:: Special handling for PATH - mix both User and System | ||
call :SetFromReg "HKLM\System\CurrentControlSet\Control\Session Manager\Environment" Path Path_HKLM >> "%TEMP%\_env.cmd" | ||
call :SetFromReg "HKCU\Environment" Path Path_HKCU >> "%TEMP%\_env.cmd" | ||
|
||
:: Caution: do not insert space-chars before >> redirection sign | ||
echo/set "Path=%%Path_HKLM%%;%%Path_HKCU%%" >> "%TEMP%\_env.cmd" | ||
|
||
:: Cleanup | ||
del /f /q "%TEMP%\_envset.tmp" 2>nul | ||
del /f /q "%TEMP%\_envget.tmp" 2>nul | ||
|
||
:: capture user / architecture | ||
SET "OriginalUserName=%USERNAME%" | ||
SET "OriginalArchitecture=%PROCESSOR_ARCHITECTURE%" | ||
|
||
:: Set these variables | ||
call "%TEMP%\_env.cmd" | ||
|
||
:: reset user / architecture | ||
SET "USERNAME=%OriginalUserName%" | ||
SET "PROCESSOR_ARCHITECTURE=%OriginalArchitecture%" | ||
|
||
echo | set /p dummy="Finished." | ||
echo . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
[Locations] | ||
# Path to loadout config from runner | ||
looks_config = ./Skylooks.cfg | ||
# Bot's python file. | ||
# Only need this if RLBot controlled | ||
python_file = SkyBot.py | ||
# The name that will be displayed in game | ||
name = SkyBot | ||
|
||
[Bot Parameters] |
Oops, something went wrong.