mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-12-16 06:18:43 +00:00
Changed: #878 Fix typos in comments/code
This commit is contained in:
parent
eee29b5b23
commit
d0f38dfc6e
18 changed files with 50 additions and 35 deletions
|
@ -183,7 +183,7 @@ private:
|
|||
);
|
||||
|
||||
/** Compute the ribbon points using hermitte splines between each sampling point,
|
||||
* and make a rough approximation to get a constant lenght
|
||||
* and make a rough approximation to get a constant length
|
||||
*/
|
||||
void computeHermitteCstSizeRibbon( uint index,
|
||||
NLMISC::CVector *dest,
|
||||
|
|
|
@ -49,7 +49,7 @@ public:
|
|||
|
||||
/**
|
||||
* Set the blend shape factor for this instance
|
||||
* blenShapeName is the name of the blendshape we want to set
|
||||
* blendShapeName is the name of the blendshape we want to set
|
||||
* factor the blendshape percentage from -100.0 to 100.0
|
||||
* dynamic tells the optimizer if the blendshape have to change in real time
|
||||
*/
|
||||
|
|
|
@ -55,7 +55,7 @@ public:
|
|||
NLMISC::TStringId getSound(uint index) const { return !_Sounds.empty() ? _Sounds[index%_Sounds.size()]:0;}
|
||||
const std::vector<NLMISC::TStringId> &getSounds() const { return _Sounds;}
|
||||
|
||||
uint32 getFadeLenght() const { return _XFadeLenght;}
|
||||
uint32 getFadeLength() const { return _XFadeLength;}
|
||||
|
||||
/** Constructor */
|
||||
CComplexSound();
|
||||
|
@ -94,7 +94,7 @@ private:
|
|||
std::vector<uint32> _DelaySeq;
|
||||
|
||||
/// Duration of xfade in millisec.
|
||||
uint32 _XFadeLenght;
|
||||
uint32 _XFadeLength;
|
||||
/// Flag for fade in
|
||||
bool _DoFadeIn;
|
||||
/// Flag for fade out (only on normal termination, not explicit stop).
|
||||
|
|
|
@ -129,8 +129,8 @@ private:
|
|||
*/
|
||||
bool _Muted;
|
||||
|
||||
// NLMISC::TTime _Lenght1;
|
||||
// NLMISC::TTime _Lenght2;
|
||||
// NLMISC::TTime _Length1;
|
||||
// NLMISC::TTime _Length2;
|
||||
|
||||
NLMISC::TTime _StartTime1;
|
||||
NLMISC::TTime _StartTime2;
|
||||
|
|
|
@ -298,7 +298,7 @@ private:
|
|||
/// The base name, that is the constante part of the name (before the first joker).
|
||||
std::string _BaseName;
|
||||
|
||||
/// The random lenght (0 mean no random)
|
||||
/// The random length (0 mean no random)
|
||||
uint32 _Random;
|
||||
|
||||
|
||||
|
|
|
@ -180,11 +180,11 @@ void CMeshBaseInstance::traverseHrc()
|
|||
if (anim)
|
||||
{
|
||||
// Animation offset are setuped before clipping, they will be used for detail too.
|
||||
float animLenght = anim->getEndTime() - anim->getBeginTime();
|
||||
if (animLenght > 0)
|
||||
float animLength = anim->getEndTime() - anim->getBeginTime();
|
||||
if (animLength > 0)
|
||||
{
|
||||
float currTime = (TAnimationTime) getOwnerScene()->getCurrentTime();
|
||||
float startTime = (uint) (currTime / animLenght) * animLenght;
|
||||
float startTime = (uint) (currTime / animLength) * animLength;
|
||||
// Set the channel mixer date using the global date of the scene
|
||||
chanMix->setSlotTime(0, anim->getBeginTime() + currTime - startTime);
|
||||
}
|
||||
|
|
|
@ -316,7 +316,7 @@ uint CMeshMRMGeom::NumCacheVertexNormal4= NL_BlockByteL1 / sizeof(CRawVertexNorm
|
|||
|
||||
/* Old School template: include the same file with define switching,
|
||||
Was used before to reuse same code for and without SSE.
|
||||
useless now because SSE removed, but keep it for possible future work on it.
|
||||
Useless now because SSE removed, but keep it for possible future work on it.
|
||||
*/
|
||||
#define ADD_MESH_MRM_SKIN_TEMPLATE
|
||||
#include "mesh_mrm_skin_template.cpp"
|
||||
|
|
|
@ -51,7 +51,7 @@ void CQuatPack::pack(const CQuat &quat)
|
|||
- The same than above, but encode the axis as X/Y only, and deduce Z from
|
||||
them, is possible but precision problems arise.
|
||||
|
||||
You can see that the operation "deduce a 3/4 member from unit lenght rule" is definetly not precise.
|
||||
You can see that the operation "deduce a 3/4 member from unit length rule" is definetly not precise.
|
||||
|
||||
Hence this simpler but workable way.
|
||||
*/
|
||||
|
|
|
@ -337,15 +337,15 @@ void CHTimer::display(CLog *log, TSortCriterion criterion, bool displayInline /*
|
|||
rootStats.buildFromNode( &_RootNode, _MsPerTick);
|
||||
|
||||
// 5 ) display statistics
|
||||
uint maxNodeLenght = 0;
|
||||
uint maxNodeLength = 0;
|
||||
std::string format;
|
||||
if (displayInline)
|
||||
{
|
||||
for(TTimerStatPtrVect::iterator statIt = statsPtr.begin(); statIt != statsPtr.end(); ++statIt)
|
||||
{
|
||||
maxNodeLenght = std::max(maxNodeLenght, (uint)strlen((*statIt)->Timer->_Name));
|
||||
maxNodeLength = std::max(maxNodeLength, (uint)strlen((*statIt)->Timer->_Name));
|
||||
}
|
||||
format = "HTIMER: %-" + NLMISC::toString(maxNodeLenght + 1) + "s %s";
|
||||
format = "HTIMER: %-" + NLMISC::toString(maxNodeLength + 1) + "s %s";
|
||||
}
|
||||
std::string statsInline;
|
||||
|
||||
|
|
|
@ -108,13 +108,13 @@ uint32 CComplexSound::getDuration()
|
|||
if (first != _SoundSeq.begin() && !durations.empty())
|
||||
{
|
||||
// remove a xfade value
|
||||
_Duration -= minof<uint32>(uint32(_XFadeLenght / _TicksPerSeconds), durations[*first % durations.size()] / 2, durations[*prev % durations.size()] /2);
|
||||
_Duration -= minof<uint32>(uint32(_XFadeLength / _TicksPerSeconds), durations[*first % durations.size()] / 2, durations[*prev % durations.size()] /2);
|
||||
}
|
||||
if (!durations.empty())
|
||||
_Duration += durations[*first % durations.size()];
|
||||
prev = first;
|
||||
}
|
||||
// _Duration -= max(sint(0), sint(_XFadeLenght * (_SoundSeq.size()-2) ));
|
||||
// _Duration -= max(sint(0), sint(_XFadeLength * (_SoundSeq.size()-2) ));
|
||||
}
|
||||
break;
|
||||
case MODE_SPARSE:
|
||||
|
@ -140,7 +140,7 @@ uint32 CComplexSound::getDuration()
|
|||
++first;
|
||||
for (; first != last; ++first)
|
||||
{
|
||||
// add the sound lenght
|
||||
// add the sound length
|
||||
_Duration += durations[soundIndex++ % durations.size()];
|
||||
// add the delay
|
||||
_Duration += uint32(*first / _TicksPerSeconds);
|
||||
|
@ -170,7 +170,7 @@ uint32 CComplexSound::getDuration()
|
|||
CComplexSound::CComplexSound() :
|
||||
_PatternMode(CComplexSound::MODE_UNDEFINED),
|
||||
_TicksPerSeconds(1.0f),
|
||||
_XFadeLenght(3000), // default to 3000 sec.
|
||||
_XFadeLength(3000), // default to 3000 sec.
|
||||
_MaxDistValid(false),
|
||||
_Duration(0),
|
||||
_DurationValid(false)
|
||||
|
@ -252,7 +252,7 @@ void CComplexSound::serial(NLMISC::IStream &s)
|
|||
s.serial(_TicksPerSeconds);
|
||||
s.serialCont(_SoundSeq);
|
||||
s.serialCont(_DelaySeq);
|
||||
s.serial(_XFadeLenght);
|
||||
s.serial(_XFadeLength);
|
||||
s.serial(_DoFadeIn);
|
||||
s.serial(_DoFadeOut);
|
||||
|
||||
|
@ -313,14 +313,14 @@ void CComplexSound::importForm(const std::string& filename, NLGEORGES::UFormElm&
|
|||
|
||||
if (mode == "Chained" || mode == "Sparse")
|
||||
{
|
||||
// XFade lenght
|
||||
formRoot.getValueByName(_XFadeLenght, ".SoundType.XFadeLenght");
|
||||
// XFade length
|
||||
formRoot.getValueByName(_XFadeLength, ".SoundType.XFadeLength");
|
||||
// Fade in/out flag.
|
||||
formRoot.getValueByName(_DoFadeIn, ".SoundType.DoFadeIn");
|
||||
formRoot.getValueByName(_DoFadeOut, ".SoundType.DoFadeOut");
|
||||
|
||||
// convert xfade to millisec.
|
||||
_XFadeLenght *= 1000;
|
||||
_XFadeLength *= 1000;
|
||||
_PatternMode = MODE_CHAINED;
|
||||
// just read the sequence
|
||||
_SoundSeq.clear();
|
||||
|
|
|
@ -113,7 +113,7 @@ void CComplexSource::playStuf()
|
|||
return;
|
||||
|
||||
if (_PatternSound->doFadeIn())
|
||||
_FadeLength = min(uint32(_PatternSound->getFadeLenght()/_TickPerSecond), sound->getDuration() /2);
|
||||
_FadeLength = min(uint32(_PatternSound->getFadeLength()/_TickPerSecond), sound->getDuration() /2);
|
||||
else
|
||||
_FadeLength = 0;
|
||||
|
||||
|
@ -510,8 +510,8 @@ void CComplexSource::onUpdate()
|
|||
//nldebug("CS : Chaining to sound %s", CStringMapper::unmap(sound2->getName()).c_str());
|
||||
CAudioMixerUser *mixer = CAudioMixerUser::instance();
|
||||
|
||||
// determine the XFade lenght (if next sound is too short.
|
||||
_FadeLength = minof<uint32>(uint32(_PatternSound->getFadeLenght()/_TickPerSecond), (sound2->getDuration()) / 2, (_Source1->getSound()->getDuration())/2);
|
||||
// determine the XFade length (if next sound is too short.
|
||||
_FadeLength = minof<uint32>(uint32(_PatternSound->getFadeLength()/_TickPerSecond), (sound2->getDuration()) / 2, (_Source1->getSound()->getDuration())/2);
|
||||
_Source2 = mixer->createSource(sound2, false, 0, 0, _Cluster);
|
||||
if (_Source2)
|
||||
{
|
||||
|
@ -528,7 +528,7 @@ void CComplexSource::onUpdate()
|
|||
if (_PatternSound->doFadeOut())
|
||||
{
|
||||
// set the event to begin fade out.
|
||||
mixer->addEvent(this, _StartTime1 + _Source1->getSound()->getDuration() - _PatternSound->getFadeLenght());
|
||||
mixer->addEvent(this, _StartTime1 + _Source1->getSound()->getDuration() - _PatternSound->getFadeLength());
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -132,7 +132,7 @@ void CSimpleSource::play()
|
|||
//|| (mixer->getListenPosVector() - _Position).sqrnorm() > _SimpleSound->getMaxDistance() * _SimpleSound->getMaxDistance())
|
||||
|| (_RelativeMode ? getPos().sqrnorm() : (mixer->getListenPosVector() - getPos()).sqrnorm()) > _SimpleSound->getMaxDistance() * _SimpleSound->getMaxDistance())
|
||||
{
|
||||
// The sample buffer is not available, don't play (we don't know the lenght)
|
||||
// The sample buffer is not available, don't play (we don't know the length)
|
||||
if (_Spawn)
|
||||
{
|
||||
if (_SpawnEndCb != 0)
|
||||
|
|
|
@ -15,8 +15,6 @@
|
|||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/*
|
||||
$Id: thread_win32.h,v 1.1 2000/10/19 07:53:33 corvazier Exp $
|
||||
|
||||
------------------------------------------------------------------------
|
||||
ClanLib, the platform independent game SDK.
|
||||
|
||||
|
|
|
@ -59,7 +59,7 @@ afx_msg void CLAEdit::OnKeyDown( UINT nChar, UINT nRepCnt, UINT nFlags )
|
|||
int start, end;
|
||||
GetSel( start, end );
|
||||
str = str.Mid( start, end-start );
|
||||
int lineNum = atoi(str);
|
||||
int lineNum = atoi( str );
|
||||
if ( ! ((lineNum != 0) || (str == "0")) )
|
||||
break;
|
||||
|
||||
|
|
|
@ -1148,7 +1148,7 @@ void computeCurrentFovAspectRatio(float &fov, float &ar)
|
|||
|
||||
// get the screen aspect ratio from CFG
|
||||
ar = ClientCfg.ScreenAspectRatio;
|
||||
//nlinfo("AR: clientcfg ar %f", ar);
|
||||
|
||||
// if Driver is not created, we can't get current screen mode
|
||||
if (!Driver) return;
|
||||
|
||||
|
@ -1167,21 +1167,18 @@ void computeCurrentFovAspectRatio(float &fov, float &ar)
|
|||
{
|
||||
// auto mode, we are using window aspect ratio
|
||||
ar = arWnd;
|
||||
//nlinfo("AR: windowed auto => use window size %d %d => %f", wndW, wndH, arWnd);
|
||||
}
|
||||
else if (mode.Width && mode.Height)
|
||||
{
|
||||
// compute screen aspect ratio
|
||||
float arScreen= float(mode.Width) / float(mode.Height);
|
||||
ar *= arWnd / arScreen;
|
||||
//nlinfo("AR: windowed not auto => monitor size %d %d window size %d %d => arsc %f arwnd %f, ar finale %f", mode.Width, mode.Height, wndW, wndH, arScreen, arWnd, ar);
|
||||
}
|
||||
}
|
||||
}
|
||||
// if fullscreen, must modulate aspect ratio by ScreenResolution
|
||||
else
|
||||
{
|
||||
//nlinfo("AR: fullscreen ratio");
|
||||
if (ar == 0.f)
|
||||
{
|
||||
UDriver::CMode mode;
|
||||
|
|
|
@ -1,3 +1,18 @@
|
|||
// Ryzom - MMORPG Framework <http://dev.ryzom.com/projects/ryzom/>
|
||||
// Copyright (C) 2010 Winch Gate Property Limited
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Affero General Public License as
|
||||
// published by the Free Software Foundation, either version 3 of the
|
||||
// License, or (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU Affero General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Affero General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/////////////////////////////////////////////////////////////////
|
||||
// WARNING : this is a generated file, don't change it !
|
||||
|
|
|
@ -16,6 +16,8 @@
|
|||
|
||||
#include "stdpch.h"
|
||||
#include "player_manager/character.h"
|
||||
#include "player_manager/player_manager.h"
|
||||
#include "player_manager/player.h"
|
||||
#include "guild_leader_module.h"
|
||||
#include "guild_member.h"
|
||||
#include "guild.h"
|
||||
|
@ -48,6 +50,7 @@ void CGuildLeaderModule::setLeader( uint16 index,uint8 session)
|
|||
nlwarning("<GUILD>%s set invalid member idx %u as leader",proxy.getId().toString().c_str(),index );
|
||||
return;
|
||||
}
|
||||
|
||||
_GuildMemberCore->setMemberGrade(memberPD->getGrade());
|
||||
memberPD->setMemberGrade(EGSPD::CGuildGrade::Leader);
|
||||
|
||||
|
@ -99,6 +102,7 @@ void CGuildLeaderModule::quitGuild()
|
|||
// ignore current leader
|
||||
if ( member->getGrade() == EGSPD::CGuildGrade::Leader )
|
||||
continue;
|
||||
|
||||
// check if the current member is the successor
|
||||
if ( successor == NULL ||
|
||||
member->getGrade() < successor->getGrade() ||
|
||||
|
|
|
@ -705,6 +705,7 @@ void CGuildManager::createGuild(CGuildCharProxy & proxy,const ucstring & guildNa
|
|||
nlwarning("<GUILD>%s bot %s is not a guild creator",proxy.getId().toString().c_str(),bot->getId().toString().c_str());
|
||||
return;
|
||||
}
|
||||
|
||||
// player must not have a guild
|
||||
CGuildMemberModule * module = NULL;
|
||||
if ( proxy.getModule( module ) )
|
||||
|
|
Loading…
Reference in a new issue