opposite_ai.py
import math
#AI for the opposite
class Oppai:
#processing
pass
hent_ai.py
#Grab motion AI
class Hentai:
#processing
pass
app.json.py
import hent_ai
from hent_ai import Hentai #Hentai()Can be instantiated with
import opposite_ai as oppai #opposite at oppai_You can use ai.
import opposite_ai.math #oppai.You don't have to write math.
try:
setai=__import__("set_ai")#Advanced Setting. With or without
except Exception as e:
print(e)
class classproperty(property):
pass
class PropertyMeta(type):
def __new__(cls, name, bases, namespace):
props = [(k, v) for k, v in namespace.items() if type(v) == classproperty]
for k, v in props:
setattr(cls, k, v)
del namespace[k]
return type.__new__(cls, name, bases, namespace)
class StartUp(metaclass=PropertyMeta):
__this = None
def __init__(self):
self.hentai = Hentai()
self.oppai = oppai.Oppai()
pass
@classproperty
def value(cls):
if cls.__this is not None:
return cls.__this
cls.__this = StartUp()
return cls.__this
@classmethod
def main(cls):
cls.value
print("Hello World")
cls.__this.input = input("Enter something")
return
if __name__ == "__main__":
StartUp.main()
Recommended Posts