Add files via upload

master
ChristianSoldier 2020-06-10 12:13:00 -04:00 committed by GitHub
parent 6aadc67c5c
commit 2954cddb46
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 23 additions and 0 deletions

7
README.txt Normal file
View File

@ -0,0 +1,7 @@
How to use:
1. Rename vmf to "map.vmf".
2. Place vmf in "vmfFixer" folder.
3. Run "vmfFixer.py".
Congradulations! You just fixed your vmf!

16
vmfFixer.py Normal file
View File

@ -0,0 +1,16 @@
with open("map.vmf", "rt") as fin:
data = fin.read()
datalist = data.split('\n')
for i in range (0,len(datalist)):
newposition = 0
position = 0
data2 = ""
if '"lightmapscale"' in datalist[i]:
temp = datalist[i]
datalist[i] = (temp+'\n "rotation" "0"\n')
with open("map.vmf",'w') as fout:
for i in range (0,len(datalist)):
fout.write(datalist[i]+"\n")
print("Done!")