Blender とそのスクリプトの学習を始めたばかりで、そのサンプル コードを実行しようとしました
import bge
def main():
cont = bge.logic.getCurrentController()
own = cont.owner
sens = cont.sensors['mySensor']
actu = cont.actuators['myActuator']
if sens.positive:
cont.activate(actu)
else:
cont.deactivate(actu)
main()
次のエラーが表示されます: ImportError: 'bge' という名前のモジュールはありません。解決策を探しましたが、何も見つかりませんでした。ブレンダー2.65を使用しています