void Image_file_info::flush ( ) { if (!modified) return; modified = false; int nshapes = ifile->get_num_shapes(); int shnum; Shape **shapes = new Shape *[nshapes]; for (shnum = 0; shnum < nshapes; shnum++) shapes[shnum] = ifile->extract_shape(shnum); string filestr("<PATCH>/"); filestr += basename; write_file(filestr.c_str(), shapes, nshapes, false); delete [] shapes;  unsigned char buf[Exult_server::maxlength]; unsigned char *ptr = &buf[0]; Write2(ptr, ifile->get_u7drag_type()); ExultStudio *studio = ExultStudio::get_instance(); studio->send_to_server(Exult_server::reload_shapes, buf, ptr - buf); }
virtual void flush() { modified = false; }
void Image_file_info::flush	(	)	{	if (!modified)		return;	modified = false;	int nshapes = ifile->get_num_shapes();	int shnum;			// First read all entries.	Shape **shapes = new Shape *[nshapes];	for (shnum = 0; shnum < nshapes; shnum++)		shapes[shnum] = ifile->extract_shape(shnum);	string filestr("<PATCH>/");	// Always write to 'patch'.	filestr += basename;	write_file(filestr.c_str(), shapes, nshapes, false);	delete [] shapes;					// Tell Exult to reload this file.	unsigned char buf[Exult_server::maxlength];	unsigned char *ptr = &buf[0];	Write2(ptr, ifile->get_u7drag_type());	ExultStudio *studio = ExultStudio::get_instance();	studio->send_to_server(Exult_server::reload_shapes, buf, ptr - buf);	}