Machine gun with multiple firing modes I have a class 'M249' it is initiated with 'ammo'
The class has one responsibility(I hope) to expend ammo.
Does there exist a way to increment without accessor or writer?

I am shaky on when I should be using mixins, or inheritance. I think module is best here?

module MG_tools
  Rof = {:sustained =&gt; rand(3..9), :rapid =&gt; rand(5..9), :cyclic =&gt; 
rand(1..200), :cease =&gt; 0}
end

class M249 
include MG_tools
  attr_accessor :ammo
  def initialize( ammo )
    @ammo = ammo
  end

  def fire(command)
    self.ammo -= Rof[command]
    raise ArgumentError.new("Out of Ammo!") if self.ammo &lt; 1 
  end
end
command = :sustained
gunner = M249.new(200)

loop do 
case gunner::ammo
  when (200..1000)
   command = :cyclic
  when (100..199)
   command = :rapid
  when (6..99)
   command = :sustained
  when (1..5)
   command = :cease
end
    puts "#{command.upcase} FIRE"
    break if command == :cease
    gunner.fire(command)
    puts "*MACHINE GUN NOISES*"
    puts "SAW: #{gunner::ammo} rounds left!"

end
Without more code / context it is hard to give much of an answer, but a few comments:


You can make ammo a read only attribute by using attr_reader :ammo then inside the class or module you can access it using @ammo just like you do in your initializer.
Don't over-complicate your code. Given what you have now there is no reason to do any of what you want. Wait till your code gets complicated enough that you need to break it up then you won't just be guessing what the best option is.
Consider using delegation rather than inheritance or modules. So your gun could have an ammo_clip attribute referencing an AmmoClip instance.
This code:

Rof = {:sustained =&gt; rand(3..9), :rapid =&gt; rand(5..9), 
       :cyclic =&gt; rand(1..200), :cease =&gt; 0}



probably doesn't do what you expect. Those random numbers will be calculated once at program startup, not each time a gun is fired.