seeded random generation of weapons and items in ruby
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
README.md
WeaponBreeder.rb
entity.rb
type.rb

README.md

WeaponBreeder

A customizable Weapon, Item, Armor, or Anything breeding system.

Each attribute (or allele) of the customizable entity types are genetically transferrable, allowing for the seeded random generation of weapons and items

Usage :

Ruby WeaponBreeder.rb {int:generations} {int:children} {int:generation_delay}
  • generations - int - How many generations to iterate through
  • children - int - How many entities each generation will have
  • generation_delay - float - How long to sleep between generations (seconds)

Customization:

Seed values are all managed by their respective Type object. All values for all types are merged into the probability cloud to ensure genetic compatability with one another.

You can easily add a new type by adding a new Type object to the $probability_cloud array.

$probability_cloud = generate_probability_cloud([
	Type.new("daisies", {
		:color => ["red","blue","green","white"], #strings
		:height => [1,4], #integer min/max range
		:is_awesome => [true,false] #booleans
	})
])