Added replacement ability and initial sending code