From: Ilan Berci Date: 2006-12-20T04:17:14+09:00 Subject: Re: compare two objects without take its ID in consideration Ilan Berci wrote: > > class Game_Esper > def ==(other) > @str==other.str && @mdfel==other.mdfel && @name==other.name > end > end > > If you have more state than this, I would suggest a looping construct > instead.. > > hope this helps > > ilan Actually, after submitting this, I realized that if 2 objects are equal they should return the same hash, adjust accordingly :) -- Posted via http://www.ruby-forum.com/.