[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Wesnoth-cvs-commits] wesnoth/src unit_types.cpp
From: |
David White |
Subject: |
[Wesnoth-cvs-commits] wesnoth/src unit_types.cpp |
Date: |
Sun, 27 Feb 2005 23:27:54 -0500 |
CVSROOT: /cvsroot/wesnoth
Module name: wesnoth
Branch:
Changes by: David White <address@hidden> 05/02/28 04:27:54
Modified files:
src : unit_types.cpp
Log message:
allow a [unit] tag to contain [trait] tags specifying traits that may
only be applicable for this unit type
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/wesnoth/wesnoth/src/unit_types.cpp.diff?tr1=1.83&tr2=1.84&r1=text&r2=text
Patches:
Index: wesnoth/src/unit_types.cpp
diff -u wesnoth/src/unit_types.cpp:1.83 wesnoth/src/unit_types.cpp:1.84
--- wesnoth/src/unit_types.cpp:1.83 Mon Feb 28 03:44:44 2005
+++ wesnoth/src/unit_types.cpp Mon Feb 28 04:27:54 2005
@@ -1,4 +1,4 @@
-/* $Id: unit_types.cpp,v 1.83 2005/02/28 03:44:44 Sirp Exp $ */
+/* $Id: unit_types.cpp,v 1.84 2005/02/28 04:27:54 Sirp Exp $ */
/*
Copyright (C) 2003 by David White <address@hidden>
Part of the Battle for Wesnoth Project http://wesnoth.whitevine.net
@@ -587,7 +587,11 @@
} else {
static const unit_race dummy_race;
race_ = &dummy_race;
- }
+ }
+
+ //insert any traits that are just for this unit type
+ const config::child_list& unit_traits = cfg.get_children("trait");
+
possibleTraits_.insert(possibleTraits_.end(),traits.begin(),traits.end());
abilities_ = utils::split(cfg_["ability"]);
- [Wesnoth-cvs-commits] wesnoth/src unit_types.cpp,
David White <=