摘要:
DuChain.py # 责任链模式 Chain of Responsibility import enum # Item Types: # An enum we'll attach to every game object to specify type: # Requires Python 3. 阅读全文
posted @ 2022-10-23 08:22
®Geovin Du Dream Park™
阅读(28)评论(0)推荐(0)
编辑
摘要:
DuFlyweight.py # 享元模式 Flyweight Pattern geovindu,Geovin Du,涂聚文 import time class Arrow: def __init__(self, x, y, z, velocity): self.x = x self.y = y s 阅读全文
posted @ 2022-10-22 11:32
®Geovin Du Dream Park™
阅读(19)评论(0)推荐(0)
编辑
摘要:
DuComposite.py # 组合模式 Composite Pattern from __future__ import annotations from abc import ABC, abstractmethod from typing import List class Component 阅读全文
posted @ 2022-10-21 22:21
®Geovin Du Dream Park™
阅读(16)评论(0)推荐(0)
编辑