The name ‘pistolFire’ does not exist in the current context

The name ‘pistolFire’ does not exist in the current context
The name ‘rifleFire’ does not exist in the current context
3dunity

pistolFirerifleFire 这两个字段没有定义就使用了。

解决方法推荐:

  1. 检测是不是在宏定义中定义了,而使用时为加相同宏定义
  2. 检测是不是字段名字写错了,比如:单词拼错,大小写等
  3. 在适当的位置定义上述两个字段即可解决问题