错误:搜索内容不能为空,请输入英文关键词
错误:关键词超出字数限制,请精简
高级检索

Enemies and Projectiles

  • Casey Hardman

摘要

In this chapter, we’ll set up the basis for both our enemies and the projectiles our towers will fire. We’ll be getting into some inheritance to do this. Since we’ll have ground enemies that move around our towers as well as flying enemies that go right over them in a straight line, we need to make sure we have a base class for our enemies that provides the common functionality that both enemy types will need – notably, taking damage and dying.