forked from distok/cutthecord
Deprecate old slashcommand patches
This commit is contained in:
parent
5cca5ef444
commit
5bd99aa8c3
144 changed files with 2 additions and 1 deletions
15
resources/old-patches/slashcommands/textreplacegen.py
Normal file
15
resources/old-patches/slashcommands/textreplacegen.py
Normal file
|
@ -0,0 +1,15 @@
|
|||
fw = dict((chr(i), chr(i + 0xFEE0)) for i in range(0x21, 0x7F))
|
||||
|
||||
code = """
|
||||
const-string v0, "before"
|
||||
|
||||
const-string v1, "after"
|
||||
|
||||
invoke-virtual {p0, v0, v1}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;
|
||||
|
||||
move-result-object p0"""
|
||||
|
||||
for entry in fw:
|
||||
if entry in ["\\", "\""]:
|
||||
continue
|
||||
print(code.replace("before", entry).replace("after", fw[entry]))
|
Loading…
Add table
Add a link
Reference in a new issue