[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Stratagus-CVS] stratagus data/ccl/units.ccl data/ccl/orc/units...
From: |
Crestez Leonard |
Subject: |
[Stratagus-CVS] stratagus data/ccl/units.ccl data/ccl/orc/units... |
Date: |
Wed, 24 Sep 2003 12:03:24 -0400 |
CVSROOT: /cvsroot/stratagus
Module name: stratagus
Branch:
Changes by: Crestez Leonard <address@hidden> 03/09/24 12:03:24
Modified files:
data/ccl : units.ccl
data/ccl/orc : units.ccl
src/clone : unit_draw.c
src/include : unittype.h
src/unit : ccl_unittype.c unittype.c
Log message:
Fixed critter stuff.
Patches:
Index: stratagus/data/ccl/orc/units.ccl
diff -u stratagus/data/ccl/orc/units.ccl:1.42
stratagus/data/ccl/orc/units.ccl:1.43
--- stratagus/data/ccl/orc/units.ccl:1.42 Mon Sep 22 06:39:12 2003
+++ stratagus/data/ccl/orc/units.ccl Wed Sep 24 12:03:23 2003
@@ -26,7 +26,7 @@
;; along with this program; if not, write to the Free Software
;; Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
USA
;;
-;; $Id: units.ccl,v 1.42 2003/09/22 10:39:12 n0body Exp $
+;; $Id: units.ccl,v 1.43 2003/09/24 16:03:23 n0body Exp $
;;=============================================================================
;; Define unit-types.
@@ -881,7 +881,6 @@
'can-attack
'can-target-land
'land-unit
- 'critter
'isundead
'organic
'selectable-by-rectangle
Index: stratagus/data/ccl/units.ccl
diff -u stratagus/data/ccl/units.ccl:1.48 stratagus/data/ccl/units.ccl:1.49
--- stratagus/data/ccl/units.ccl:1.48 Mon Sep 22 06:39:11 2003
+++ stratagus/data/ccl/units.ccl Wed Sep 24 12:03:23 2003
@@ -26,7 +26,7 @@
;; along with this program; if not, write to the Free Software
;; Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
USA
;;
-;; $Id: units.ccl,v 1.48 2003/09/22 10:39:11 n0body Exp $
+;; $Id: units.ccl,v 1.49 2003/09/24 16:03:23 n0body Exp $
;; Load the animations for the units.
(ccl:load "ccl/anim.ccl")
@@ -136,7 +136,6 @@
'can-attack
'can-target-land 'can-target-sea 'can-target-air
'air-unit
- 'critter
'detect-cloak
'organic
'selectable-by-rectangle
@@ -169,7 +168,6 @@
'right-move
'can-target-land
'land-unit
- 'critter
'random-movement-probability 100
'clicks-to-explode 10
'organic
@@ -420,7 +418,6 @@
'type-land
'building
'revealer
- 'critter
'detect-cloak
'sounds '())
@@ -436,7 +433,6 @@
'decay-rate 1
'type-land
'building
- 'critter
'sounds '())
;; Load the different races
Index: stratagus/src/clone/unit_draw.c
diff -u stratagus/src/clone/unit_draw.c:1.161
stratagus/src/clone/unit_draw.c:1.162
--- stratagus/src/clone/unit_draw.c:1.161 Sat Sep 20 05:03:40 2003
+++ stratagus/src/clone/unit_draw.c Wed Sep 24 12:03:24 2003
@@ -26,7 +26,7 @@
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
// 02111-1307, USA.
//
-// $Id: unit_draw.c,v 1.161 2003/09/20 09:03:40 mr-russ Exp $
+// $Id: unit_draw.c,v 1.162 2003/09/24 16:03:24 n0body Exp $
//@{
@@ -577,7 +577,7 @@
global void SaveDecorations(CLFile* file)
{
CLprintf(file,"\n;;; -----------------------------------------\n");
- CLprintf(file,";;; MODULE: decorations $Id: unit_draw.c,v 1.161 2003/09/20
09:03:40 mr-russ Exp $\n\n");
+ CLprintf(file,";;; MODULE: decorations $Id: unit_draw.c,v 1.162 2003/09/24
16:03:24 n0body Exp $\n\n");
CLprintf(file,"(mana-sprite \"%s\" %d %d %d %d)\n",
ManaSprite.File,ManaSprite.HotX,ManaSprite.HotY,
@@ -799,7 +799,8 @@
// Health bar on left side of unit.
//
stats=unit->Stats;
- if( (!type->Critter || unit->Player->Type!=PlayerRaceNeutral)
+ // Why remove the neutral race?
+ if( (unit->Player->Type!=PlayerRaceNeutral)
&& ShowHealthBar ) {
if( stats->HitPoints
&& !(ShowNoFull && unit->HP==stats->HitPoints) ) {
@@ -878,8 +879,9 @@
//
// Health dot on left side of unit.
+ // Why skip the neutral units?
//
- if( (!type->Critter || unit->Player->Type!=PlayerRaceNeutral)
+ if( (unit->Player->Type!=PlayerRaceNeutral)
&& ShowHealthDot ) {
if( stats->HitPoints
&& !(ShowNoFull && unit->HP==stats->HitPoints) ) {
Index: stratagus/src/include/unittype.h
diff -u stratagus/src/include/unittype.h:1.113
stratagus/src/include/unittype.h:1.114
--- stratagus/src/include/unittype.h:1.113 Mon Sep 22 06:40:52 2003
+++ stratagus/src/include/unittype.h Wed Sep 24 12:03:24 2003
@@ -26,7 +26,7 @@
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
// 02111-1307, USA.
//
-// $Id: unittype.h,v 1.113 2003/09/22 10:40:52 n0body Exp $
+// $Id: unittype.h,v 1.114 2003/09/24 16:03:24 n0body Exp $
#ifndef __UNITTYPE_H__
#define __UNITTYPE_H__
@@ -302,11 +302,6 @@
**
** Death explosion animated
**
-** UnitType::Critter
-**
-** Unit is marked as critter. The effect of this is that when
-** idle the unit will move around randomly.
-**
** UnitType::RandomMovementProbability
**
** When the unit is idle this is the probability that it will
@@ -759,7 +754,6 @@
unsigned AirUnit : 1; /// Air animated
unsigned SeaUnit : 1; /// Sea animated
unsigned ExplodeWhenKilled : 1; /// Death explosion animated
- unsigned Critter : 1; /// Unit is controlled by nobody
unsigned int RandomMovementProbability;/// Probability to move randomly.
unsigned int ClicksToExplode; /// Number of consecutive clicks until
unit suicides.
unsigned Sniper : 1; /// The unit can only hit organic units.
@@ -845,7 +839,6 @@
// FIXME: this hardcoded unit-types must be removed!!
extern UnitType*UnitTypeHumanWall; /// Human wall
extern UnitType*UnitTypeOrcWall; /// Orc wall
-extern UnitType*UnitTypeCritter; /// Critter unit-type pointer
extern char** UnitTypeWcNames; /// Mapping wc-number 2 symbol
Index: stratagus/src/unit/ccl_unittype.c
diff -u stratagus/src/unit/ccl_unittype.c:1.88
stratagus/src/unit/ccl_unittype.c:1.89
--- stratagus/src/unit/ccl_unittype.c:1.88 Mon Sep 22 06:40:53 2003
+++ stratagus/src/unit/ccl_unittype.c Wed Sep 24 12:03:24 2003
@@ -26,7 +26,7 @@
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
// 02111-1307, USA.
//
-// $Id: ccl_unittype.c,v 1.88 2003/09/22 10:40:53 n0body Exp $
+// $Id: ccl_unittype.c,v 1.89 2003/09/24 16:03:24 n0body Exp $
//@{
@@ -429,8 +429,6 @@
type->AirUnit=1;
} else if( gh_eq_p(value,gh_symbol2scm("sea-unit")) ) {
type->SeaUnit=1;
- } else if( gh_eq_p(value,gh_symbol2scm("critter")) ) {
- type->Critter=1;
} else if( gh_eq_p(value,gh_symbol2scm("random-movement-probability"))
) {
type->RandomMovementProbability=gh_scm2int(gh_car(list));
list=gh_cdr(list);
Index: stratagus/src/unit/unittype.c
diff -u stratagus/src/unit/unittype.c:1.104 stratagus/src/unit/unittype.c:1.105
--- stratagus/src/unit/unittype.c:1.104 Mon Sep 22 06:40:53 2003
+++ stratagus/src/unit/unittype.c Wed Sep 24 12:03:24 2003
@@ -26,7 +26,7 @@
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
// 02111-1307, USA.
//
-// $Id: unittype.c,v 1.104 2003/09/22 10:40:53 n0body Exp $
+// $Id: unittype.c,v 1.105 2003/09/24 16:03:24 n0body Exp $
//@{
@@ -79,7 +79,6 @@
*/
global UnitType*UnitTypeHumanWall; /// Human wall
global UnitType*UnitTypeOrcWall; /// Orc wall
-global UnitType*UnitTypeCritter; /// Critter unit type pointer
/**
** Mapping of W*rCr*ft number to our internal unit-type symbol.
@@ -442,7 +441,9 @@
unittype->AirUnit=BIT(1,v);
unittype->ExplodeWhenKilled=BIT(2,v);
unittype->SeaUnit=BIT(3,v);
- unittype->Critter=BIT(4,v);
+ // BIT(4,v) This makes the unit a critter, true for demons, skeletons
and sheep.
+ // There were some uses for this in code, like removing a health bar
and the like,
+ // but I (n0body) don't think they were usefull. Thus BIT(4,v) is from
now on ignored.
unittype->Building=BIT(5,v);
unittype->PermanentCloak=BIT(6,v);
unittype->DetectCloak=BIT(7,v);
@@ -909,9 +910,6 @@
CLprintf(file," 'sea-unit\n");
}
- if( type->Critter ) {
- CLprintf(file," 'critter\n");
- }
if( type->RandomMovementProbability ) {
CLprintf(file," 'random-movement-probability
%d\n",type->RandomMovementProbability);
}
@@ -1137,7 +1135,7 @@
char **sp;
CLprintf(file,"\n;;; -----------------------------------------\n");
- CLprintf(file,";;; MODULE: unittypes $Id: unittype.c,v 1.104 2003/09/22
10:40:53 n0body Exp $\n\n");
+ CLprintf(file,";;; MODULE: unittypes $Id: unittype.c,v 1.105 2003/09/24
16:03:24 n0body Exp $\n\n");
// Original number to internal unit-type name.
@@ -1288,7 +1286,6 @@
//
UnitTypeHumanWall=UnitTypeByIdent("unit-human-wall");
UnitTypeOrcWall=UnitTypeByIdent("unit-orc-wall");
- UnitTypeCritter=UnitTypeByIdent("unit-critter");
}
/**
@@ -1551,7 +1548,6 @@
//
UnitTypeHumanWall=NULL;
UnitTypeOrcWall=NULL;
- UnitTypeCritter=NULL;
}
//@}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Stratagus-CVS] stratagus data/ccl/units.ccl data/ccl/orc/units...,
Crestez Leonard <=