quakeforge/ruamoko/gui/Pic.r

35 lines
432 B
R
Raw Normal View History

2004-02-13 02:52:14 +00:00
#include "draw.h"
#include "string.h"
#include "gui/Pic.h"
@implementation Pic
-(id)init
{
pic_name = str_new ();
return self;
}
-(void)dealloc
{
str_free (pic_name);
[super dealloc];
2004-02-13 02:52:14 +00:00
}
-(void)setPic:(string)pic
{
str_copy (pic_name, pic);
}
-(void)draw
{
Draw_Pic (xabs, yabs, Draw_CachePic (pic_name, 1));
}
@end
@implementation CenterPic
-(void)draw
{
Draw_CenterPic (xabs, yabs, Draw_CachePic (pic_name, 1));
}
@end