mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-10 15:22:04 +00:00
update for recent changes to Object
This commit is contained in:
parent
5c1875ba28
commit
da86367824
8 changed files with 30 additions and 30 deletions
|
@ -7,7 +7,7 @@
|
|||
float duration;
|
||||
}
|
||||
- (id) initWithFile: (string) file duration: (float) time;
|
||||
- (void) free;
|
||||
- (void) dealloc;
|
||||
- (Point) size;
|
||||
- (float) duration;
|
||||
- (void) draw: (integer) x :(integer) y;
|
||||
|
|
|
@ -11,10 +11,10 @@
|
|||
return self;
|
||||
}
|
||||
|
||||
- (void) free
|
||||
- (void) dealloc
|
||||
{
|
||||
[picture free];
|
||||
[super free];
|
||||
[picture dealloc];
|
||||
[super dealloc];
|
||||
}
|
||||
|
||||
- (Point) size
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
+ (void) initClass;
|
||||
- (id) initWithComponents: (integer) x : (integer) y;
|
||||
- (void) free;
|
||||
- (void) dealloc;
|
||||
- (integer) handle;
|
||||
- (Point) origin;
|
||||
- (Point) size;
|
||||
|
@ -40,7 +40,7 @@
|
|||
}
|
||||
|
||||
- (id) initWithComponents: (integer)x :(integer)y :(string) _file;
|
||||
- (void) free;
|
||||
- (void) dealloc;
|
||||
- (Point) size;
|
||||
- (void) setFile: (string) _file;
|
||||
- (void) display;
|
||||
|
@ -57,7 +57,7 @@
|
|||
BOOL looping;
|
||||
}
|
||||
- (id) initWithComponents: (integer) x :(integer) y;
|
||||
- (void) free;
|
||||
- (void) dealloc;
|
||||
- (Point) size;
|
||||
- (void) addFrame: (Frame) frame;
|
||||
- (void) changeFrame;
|
||||
|
|
|
@ -23,11 +23,11 @@ integer HUDHandleClass;
|
|||
return self;
|
||||
}
|
||||
|
||||
- (void) free
|
||||
- (void) dealloc
|
||||
{
|
||||
[origin free];
|
||||
[origin dealloc];
|
||||
GIB_Handle_Free (handle, HUDHandleClass);
|
||||
[super free];
|
||||
[super dealloc];
|
||||
}
|
||||
|
||||
- (integer) handle
|
||||
|
@ -110,10 +110,10 @@ integer HUDHandleClass;
|
|||
return self;
|
||||
}
|
||||
|
||||
- (void) free
|
||||
- (void) dealloc
|
||||
{
|
||||
[picture free];
|
||||
[super free];
|
||||
[picture dealloc];
|
||||
[super dealloc];
|
||||
}
|
||||
|
||||
- (Point) size
|
||||
|
@ -123,7 +123,7 @@ integer HUDHandleClass;
|
|||
|
||||
- (void) setFile: (string) _file
|
||||
{
|
||||
[picture free];
|
||||
[picture dealloc];
|
||||
picture = [[QPic alloc] initName :_file];
|
||||
}
|
||||
|
||||
|
@ -147,10 +147,10 @@ integer HUDHandleClass;
|
|||
return self;
|
||||
}
|
||||
|
||||
- (void) free
|
||||
- (void) dealloc
|
||||
{
|
||||
[frames free];
|
||||
[super free];
|
||||
[frames dealloc];
|
||||
[super dealloc];
|
||||
}
|
||||
|
||||
- (Point) size
|
||||
|
|
|
@ -76,7 +76,7 @@ void (integer argc, string [] argv) gib_hud_start_anim_f =
|
|||
|
||||
for (i = 1; i < argc; i++) {
|
||||
anim = GIB_Handle_Get (stoi (argv[i]), HUDHandleClass);
|
||||
if (anim && [anim isKindOf :[HUDAnimation class]])
|
||||
if (anim && [anim isKindOfClass :[HUDAnimation class]])
|
||||
[anim start];
|
||||
}
|
||||
};
|
||||
|
@ -91,7 +91,7 @@ void (integer argc, string [] argv) gib_hud_stop_anim_f =
|
|||
|
||||
for (i = 1; i < argc; i++) {
|
||||
anim = GIB_Handle_Get (stoi (argv[i]), HUDHandleClass);
|
||||
if (anim && [anim isKindOf :[HUDAnimation class]])
|
||||
if (anim && [anim isKindOfClass :[HUDAnimation class]])
|
||||
[anim stop];
|
||||
}
|
||||
};
|
||||
|
@ -104,7 +104,7 @@ void (integer argc, string [] argv) gib_hud_set_looping_f =
|
|||
return;
|
||||
|
||||
anim = GIB_Handle_Get (stoi (argv[1]), HUDHandleClass);
|
||||
if (anim && [anim isKindOf :[HUDAnimation class]]) {
|
||||
if (anim && [anim isKindOfClass :[HUDAnimation class]]) {
|
||||
switch (argv[2]) {
|
||||
case "yes":
|
||||
case "true":
|
||||
|
@ -132,7 +132,7 @@ void (integer argc, string [] argv) gib_hud_delete_f =
|
|||
trashObject = GIB_Handle_Get (stoi (argv[i]), HUDHandleClass);
|
||||
if (trashObject) {
|
||||
[HUDObjects removeItem :trashObject];
|
||||
[trashObject free];
|
||||
[trashObject dealloc];
|
||||
} else
|
||||
dprint (sprintf ("Warning: no HUD object associated with handle %i\n", stoi (argv[i])));
|
||||
}
|
||||
|
@ -156,7 +156,7 @@ void (integer argc, string [] argv) gib_hud_get_rect_f =
|
|||
myPoint = [myObject size];
|
||||
GIB_Return (itos ([myPoint x]));
|
||||
GIB_Return (itos ([myPoint y]));
|
||||
[myPoint free];
|
||||
[myPoint dealloc];
|
||||
};
|
||||
|
||||
|
||||
|
@ -176,7 +176,7 @@ void (integer argc, string [] argv) gib_hud_set_translate_f =
|
|||
else
|
||||
for (i = 1; i < argc - 2; i++)
|
||||
[(HUDObject) GIB_Handle_Get (stoi (argv[i]), HUDHandleClass) setOrigin :p];
|
||||
[p free];
|
||||
[p dealloc];
|
||||
};
|
||||
|
||||
void (integer argc, string [] argv) gib_hud_set_text_f =
|
||||
|
@ -187,7 +187,7 @@ void (integer argc, string [] argv) gib_hud_set_text_f =
|
|||
return;
|
||||
|
||||
myObject = GIB_Handle_Get (stoi (argv[1]), HUDHandleClass);
|
||||
if (!myObject || ![myObject isKindOf :[HUDText class]])
|
||||
if (!myObject || ![myObject isKindOfClass :[HUDText class]])
|
||||
return;
|
||||
[myObject setText :argv[2]];
|
||||
};
|
||||
|
@ -200,7 +200,7 @@ void (integer argc, string [] argv) gib_hud_set_file_f =
|
|||
return;
|
||||
|
||||
myObject = GIB_Handle_Get (stoi (argv[1]), HUDHandleClass);
|
||||
if (!myObject || ![myObject isKindOf :[HUDGraphic class]])
|
||||
if (!myObject || ![myObject isKindOfClass :[HUDGraphic class]])
|
||||
return;
|
||||
[myObject setFile :argv[2]];
|
||||
};
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
|
||||
org = trace_endpos - v_forward * 4;
|
||||
|
||||
if ([trace_ent.@this takeDamage: self inflictor: s attacker: s : damage])
|
||||
if ([trace_ent.@this takeDamage:self :s :s :damage])
|
||||
SpawnBlood (org, 20);
|
||||
else {
|
||||
sound (s, CHAN_WEAPON, "player/axhit2.wav", 1, ATTN_NORM);
|
||||
|
|
|
@ -110,14 +110,14 @@
|
|||
{
|
||||
local integer i;
|
||||
for (i = 0; i < count; i++)
|
||||
[array[i] perform:selector];
|
||||
[array[i] performSelector:selector];
|
||||
}
|
||||
|
||||
-(void)makeObjectsPerformSelector:(SEL)selector withObject:(id)arg
|
||||
{
|
||||
local integer i;
|
||||
for (i = 0; i < count; i++)
|
||||
[array[i] perform:selector withObject:arg];
|
||||
[array[i] performSelector:selector withObject:arg];
|
||||
}
|
||||
|
||||
@end
|
||||
|
|
|
@ -125,14 +125,14 @@
|
|||
{
|
||||
local list_bucket_t [] e;
|
||||
for (e = head; e; e = e.next)
|
||||
[e.obj perform:selector];
|
||||
[e.obj performSelector:selector];
|
||||
}
|
||||
|
||||
-(void)makeObjectsPerformSelector:(SEL)selector withObject:(id)arg
|
||||
{
|
||||
local list_bucket_t [] e;
|
||||
for (e = head; e; e = e.next)
|
||||
[e.obj perform:selector withObject:arg];
|
||||
[e.obj performSelector:selector withObject:arg];
|
||||
}
|
||||
|
||||
@end
|
||||
|
|
Loading…
Reference in a new issue