1 // NeL - MMORPG Framework <http://dev.ryzom.com/projects/nel/>
2 // Copyright (C) 2010 Winch Gate Property Limited
4 // This program is free software: you can redistribute it and/or modify
5 // it under the terms of the GNU Affero General Public License as
6 // published by the Free Software Foundation, either version 3 of the
7 // License, or (at your option) any later version.
9 // This program is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 // GNU Affero General Public License for more details.
14 // You should have received a copy of the GNU Affero General Public License
15 // along with this program. If not, see <http://www.gnu.org/licenses/>.
19 #include "nel/pacs/retrievable_surface.h"
22 using namespace NLMISC
;
25 float NLPACS::Models[NumCreatureModels][NumModelCharacteristics] =
27 { 0.5f, 1.0f, -1.0f },
28 { 0.8f, 2.0f, -0.5f },
29 { 2.0f, 4.0f, +0.5f },
30 { 4.0f, 8.0f, +0.707f }
34 float NLPACS::Models
[NumMaxCreatureModels
][NumModelCharacteristics
] =
36 { 0.5f
, 1.0f
, -1.0f
},
37 { 4.0f
, 8.0f
, +0.5f
},
38 { 0.0f
, 0.0f
, -1.0f
},
39 { 0.0f
, 0.0f
, -1.0f
},
42 void NLPACS::CRetrievableSurface::serial(NLMISC::IStream
&f
)
48 - absolute water height and flag
50 - no more topologies in stream (obsolete)
52 - quantized height (_QuantHeight)
54 sint ver
= f
.serialVersion(2);
60 f
.serial(_NormalQuanta
);
61 f
.serial(_OrientationQuanta
);
65 f
.serialCont(_Chains
);
70 for (i
=0; i
<NumMaxCreatureModels
; ++i
)
71 f
.serial(_Topologies
[i
]);
74 f
.serial(_IsFloor
, _IsCeiling
);
79 f
.serial(_WaterHeight
);
84 f
.serial(_QuantHeight
);
88 void NLPACS::CRetrievableSurface::TLoop::serial(NLMISC::IStream
&f
)