Index: source/Chunk.h =================================================================== --- source/Chunk.h (révision 1674) +++ source/Chunk.h (copie de travail) @@ -9,8 +9,6 @@ - - #define C_CHUNK_USE_INLINE 1 // Do not touch @@ -49,7 +47,9 @@ class cChunkDataSerializer; class cBlockArea; class cFluidSimulatorData; +class cMobInventory; + typedef std::list cClientHandleList; typedef cItemCallback cEntityCallback; typedef cItemCallback cChestCallback; @@ -123,6 +123,13 @@ /// Sets or resets the internal flag that prevents chunk from being unloaded void Stay(bool a_Stay = true); + + /// Recence all mobs proximities to players in order to know what to do with them + void RegisterMobs(cMobInventory& toFill); + + /// Try to Spawn Monsters inside chunk + void SpawnMobs(cMobSpawner& a_MobSpawner); + void Tick(float a_Dt); @@ -364,6 +371,9 @@ cFluidSimulatorData * m_LavaSimulatorData; cSandSimulatorChunkData m_SandSimulatorData; + // pick up a random block of this chunk + void getRandomBlock(int& a_X, int& a_Y, int& a_Z); + void getThreeRandomNumber(int& a_X, int& a_Y, int& a_Z,int a_MaxX, int a_MaxY, int a_MaxZ); void RemoveBlockEntity(cBlockEntity * a_BlockEntity); void AddBlockEntity (cBlockEntity * a_BlockEntity); Index: source/ChunkMap.cpp =================================================================== --- source/ChunkMap.cpp (révision 1674) +++ source/ChunkMap.cpp (copie de travail) @@ -13,6 +13,8 @@ #include "BlockArea.h" #include "PluginManager.h" #include "TNTEntity.h" +#include "MobInventory.h" +#include "MobSpawner.h" #ifndef _WIN32 #include // abs @@ -2117,8 +2119,28 @@ +void cChunkMap::RegisterMobs(cMobInventory& a_ToFill) +{ + cCSLock Lock(m_CSLayers); + for (cChunkLayerList::iterator itr = m_Layers.begin(); itr != m_Layers.end(); ++itr) + { + (*itr)->RegisterMobs(a_ToFill); + } // for itr - m_Layers +} +void cChunkMap::SpawnMobs(cMobSpawner& a_MobSpawner) +{ + cCSLock Lock(m_CSLayers); + for (cChunkLayerList::iterator itr = m_Layers.begin(); itr != m_Layers.end(); ++itr) + { + (*itr)->SpawnMobs(a_MobSpawner); + } // for itr - m_Layers +} + + + + void cChunkMap::Tick(float a_Dt) { cCSLock Lock(m_CSLayers); @@ -2276,7 +2298,35 @@ +void cChunkMap::cChunkLayer::RegisterMobs(cMobInventory& a_ToFill) +{ + for (int i = 0; i < ARRAYCOUNT(m_Chunks); i++) + { + // We do count every Mobs in the world. But we are assuming that every chunk not loaded by any client + // doesn't affect us. Normally they should not have mobs because every "too far" mob is despawn + // but if they have (f.i. when player disconnect) we don't have to make them live or despawn + if ((m_Chunks[i] != NULL) && m_Chunks[i]->IsValid() && m_Chunks[i]->HasAnyClients()) + { + m_Chunks[i]->RegisterMobs(a_ToFill); + } + } // for i - m_Chunks[] +} + +void cChunkMap::cChunkLayer::SpawnMobs(cMobSpawner& a_MobSpawner) +{ + for (int i = 0; i < ARRAYCOUNT(m_Chunks); i++) + { + // We only spawn close to players + if ((m_Chunks[i] != NULL) && m_Chunks[i]->IsValid() && m_Chunks[i]->HasAnyClients()) + { + m_Chunks[i]->SpawnMobs(a_MobSpawner); + } + } // for i - m_Chunks[] +} + + + void cChunkMap::cChunkLayer::Tick(float a_Dt) { for (int i = 0; i < ARRAYCOUNT(m_Chunks); i++) Index: source/BlockID.h =================================================================== --- source/BlockID.h (révision 1674) +++ source/BlockID.h (copie de travail) @@ -570,7 +570,7 @@ -enum +enum eMobType { // See also E_META_SPAWN_EGG_XXX, since entity type and spawn egg meta are the same E_ENTITY_TYPE_CREEPER = 50, @@ -601,8 +601,19 @@ E_ENTITY_TYPE_OCELOT = 98, E_ENTITY_TYPE_IRON_GOLEM = 99, E_ENTITY_TYPE_VILLAGER = 120, + + E_ENTITY_TYPE_DONOTUSE = 121, } ; +// "Families" of Monsters. First used for spawning +enum eMobMegaType +{ + E_MOB_MEGA_TYPE_HOSTILE = 0, // Spider, Zombies ... + E_MOB_MEGA_TYPE_PASSIVE = 1, // Cows, Pigs + E_MOB_MEGA_TYPE_AMBIENT = 2, // Bats + E_MOB_MEGA_TYPE_WATER = 3, // Squid + E_MOB_MEGA_TYPE_DONOTUSE = 4, // Nothing +}; Index: source/BlockID.cpp =================================================================== --- source/BlockID.cpp (révision 1674) +++ source/BlockID.cpp (copie de travail) @@ -616,6 +616,10 @@ g_BlockTransparent[E_BLOCK_WOODEN_DOOR] = true; g_BlockTransparent[E_BLOCK_WOODEN_PRESSURE_PLATE] = true; g_BlockTransparent[E_BLOCK_YELLOW_FLOWER] = true; + g_BlockTransparent[E_BLOCK_WATER] = true; + g_BlockTransparent[E_BLOCK_LAVA] = true; + g_BlockTransparent[E_BLOCK_STATIONARY_WATER] = true; + g_BlockTransparent[E_BLOCK_STATIONARY_LAVA] = true; // TODO: Any other transparent blocks? Index: source/Chunk.cpp =================================================================== --- source/Chunk.cpp (révision 1674) +++ source/Chunk.cpp (copie de travail) @@ -30,7 +30,10 @@ #include "PluginManager.h" #include "Blocks/BlockHandler.h" #include "Simulator/FluidSimulator.h" +#include "MobInventory.h" +#include "MobSpawner.h" + #include @@ -427,9 +430,123 @@ } +void cChunk::RegisterMobs(cMobInventory& toFill) +{ + toFill.RegisterSpawnableChunck(*this); + std::list playerPositions; + cPlayer* currentPlayer; + for (cClientHandleList::iterator itr = m_LoadedByClient.begin(), end = m_LoadedByClient.end(); itr != end; ++itr) + { + currentPlayer = (*itr)->GetPlayer(); + playerPositions.push_back(&(currentPlayer->GetPosition())); + } + + Vector3d currentPosition; + for (cEntityList::iterator itr = m_Entities.begin(); itr != m_Entities.end(); ++itr) + { + //LOGD("Counting entity #%i (%s)", (*itr)->GetUniqueID(), (*itr)->GetClass()); + if ((*itr)->IsMob()) + { + currentPosition = (*itr)->GetPosition(); + for (std::list::const_iterator itr2 = playerPositions.begin(); itr2 != playerPositions.end(); itr2 ++) + { + toFill.RegisterMob(**itr,*this,(currentPosition-**itr2).SqrLength()); + } + + } + } // for itr - m_Entitites[] +} + +void cChunk::getRandomBlock(int& a_X, int& a_Y, int& a_Z) +{ + // MG TODO : check if this kind of optimization (only one random call) is still needed + // MG TODO : if so propagate it + + getThreeRandomNumber(a_X, a_Y, a_Z, Width, Height-2, Width); + a_Y++; +} + +void cChunk::getThreeRandomNumber(int& a_X, int& a_Y, int& a_Z,int a_MaxX, int a_MaxY, int a_MaxZ) +{ + assert(a_MaxX * a_MaxY * a_MaxZ * 8 < 0x00ffffff); + int Random = m_World->GetTickRandomNumber(0x00ffffff); + a_X = Random % (a_MaxX * 2); + a_Y = (Random / (a_MaxX * 2)) % (a_MaxY * 2); + a_Z = ((Random / (a_MaxX * 2)) / (a_MaxY * 2)) % (a_MaxZ * 2); + a_X /= 2; + a_Y /= 2; + a_Z /= 2; +} + +void cChunk::SpawnMobs(cMobSpawner& a_MobSpawner) +{ + int Center_X,Center_Y,Center_Z; + getRandomBlock(Center_X,Center_Y,Center_Z); + + BLOCKTYPE PackCenterBlock = GetBlock(Center_X, Center_Y, Center_Z); + if (a_MobSpawner.CheckPackCenter(PackCenterBlock)) + { + a_MobSpawner.NewPack(); + int NumberOfTries = 0; + int NumberOfSuccess = 0; + int MaxNbOfSuccess = 4; // this can be changed during the process for Wolves and Ghasts + while (NumberOfTries < 12 && NumberOfSuccess < MaxNbOfSuccess) + { + const int HorizontalRange = 20; // MG TODO : relocate + const int VerticalRange = 0; // MG TODO : relocate + int Try_X, Try_Y, Try_Z; + getThreeRandomNumber(Try_X, Try_Y, Try_Z, 2*HorizontalRange+1 , 2*VerticalRange+1, 2*HorizontalRange+1); + Try_X -= HorizontalRange; + Try_Y -= VerticalRange; + Try_Z -= HorizontalRange; + Try_X += Center_X; + Try_Y += Center_Y; + Try_Z += Center_Z; + + assert(Try_Y > 0); + assert(Try_Y < cChunkDef::Height-1); + + BLOCKTYPE BlockType; + NIBBLETYPE BlockMeta; + BLOCKTYPE BlockType_below; + NIBBLETYPE BlockMeta_below; + BLOCKTYPE BlockType_above; + NIBBLETYPE BlockMeta_above; + if (UnboundedRelGetBlock(Try_X, Try_Y , Try_Z, BlockType, BlockMeta) && + UnboundedRelGetBlock(Try_X, Try_Y-1, Try_Z, BlockType_below, BlockMeta_below) && + UnboundedRelGetBlock(Try_X, Try_Y+1, Try_Z, BlockType_above, BlockMeta_above) + ) + { + EMCSBiome Biome = m_ChunkMap->GetBiomeAt (Try_X, Try_Z); + // MG TODO : + // Moon cycle (for slime) + // check player and playerspawn presence < 24 blocks + // check mobs presence on the block + + // MG TODO: fix the "light" thing, I'm pretty sure that UnboundedRelGetBlock is not returning the right thing + + // MG TODO : check that "Level" really means Y + cEntity* newMob = a_MobSpawner.TryToSpawnHere(BlockType, BlockMeta, BlockType_below, BlockMeta_below, BlockType_above, BlockMeta_above, Biome, Try_Y, MaxNbOfSuccess); + if (newMob) + { + int WorldX, WorldY, WorldZ; + PositionToWorldPosition(Try_X, Try_Y, Try_Z, WorldX, WorldY, WorldZ); + newMob->SetPosition(WorldX, WorldY, WorldZ); + LOGD("Spawning %s #%i at %d,%d,%d",newMob->GetClass(),newMob->GetUniqueID(),WorldX, WorldY, WorldZ); + NumberOfSuccess++; + } + } + + NumberOfTries++; + } + } +} + + + void cChunk::Tick(float a_Dt) { BroadcastPendingBlockChanges(); @@ -457,7 +574,11 @@ // Tick all entities in this chunk: for (cEntityList::iterator itr = m_Entities.begin(); itr != m_Entities.end(); ++itr) { - (*itr)->Tick(a_Dt, *this); + // Mobs are tickes inside MobTick (as we don't have to tick them if they are far away from players) + if (!((*itr)->IsMob())) + { + (*itr)->Tick(a_Dt, *this); + } } // for itr - m_Entitites[] // Remove all entities that were scheduled for removal: Index: source/ChunkMap.h =================================================================== --- source/ChunkMap.h (révision 1674) +++ source/ChunkMap.h (copie de travail) @@ -26,6 +26,8 @@ class cPickup; class cChunkDataSerializer; class cBlockArea; +class cMobInventory; +class cMobSpawner; typedef std::list cClientHandleList; typedef cChunk * cChunkPtr; @@ -258,9 +260,15 @@ /// Grows a cactus present at the block specified by the amount of blocks specified, up to the max height specified in the config void GrowCactus(int a_BlockX, int a_BlockY, int a_BlockZ, int a_NumBlocksToGrow); - /// Sets the blockticking to start at the specified block. Only one blocktick per chunk may be set, second call overwrites the first call + /// Sets the blockticking to start at the specified block. Only one blocktick per chunk may be set, second call overwrites the first call void SetNextBlockTick(int a_BlockX, int a_BlockY, int a_BlockZ); + /// Make a MobInventory, of all mobs, their megatype, their chunk and theyr distance to closest player + void RegisterMobs(cMobInventory& a_ToFill); + + /// Try to Spawn Monsters inside all Chunks + void SpawnMobs(cMobSpawner& a_MobSpawner); + void Tick(float a_Dt); void UnloadUnusedChunks(void); @@ -304,6 +312,13 @@ void Save(void); void UnloadUnusedChunks(void); + + /// Make a MobInventory, of all mobs, their megatype, their chunk and their distance to closest player + void RegisterMobs(cMobInventory& a_ToFill); + + /// Try to Spawn Monsters inside all Chunks + void SpawnMobs(cMobSpawner& a_MobSpawner); + void Tick(float a_Dt); void RemoveClient(cClientHandle * a_Client); Index: source/Mobs/Monster.h =================================================================== --- source/Mobs/Monster.h (révision 1674) +++ source/Mobs/Monster.h (copie de travail) @@ -16,7 +16,6 @@ - // tolua_begin class cMonster : public cPawn @@ -66,6 +65,7 @@ virtual void InStateEscaping(float a_Dt); virtual void Attack(float a_Dt); + int GetMobType() {return m_MobType;} int GetAttackRate(){return (int)m_AttackRate;} void SetAttackRate(int ar); Index: source/Mobs/AggressiveMonster.h =================================================================== --- source/Mobs/AggressiveMonster.h (révision 1674) +++ source/Mobs/AggressiveMonster.h (copie de travail) @@ -19,6 +19,7 @@ virtual void InStateChasing(float a_Dt) override; virtual void EventSeePlayer(cEntity *) override; + protected: float m_ChaseTime; Index: source/Mobs/Monster.cpp =================================================================== --- source/Mobs/Monster.cpp (révision 1674) +++ source/Mobs/Monster.cpp (copie de travail) @@ -122,6 +122,7 @@ SetSpeedX (GetSpeedX() * 2.f); SetSpeedZ (GetSpeedZ() * 2.f); } +// LOGD("%f %f", GetSpeedX(), GetSpeedZ()); } else { Index: source/Mobs/Bat.h =================================================================== --- source/Mobs/Bat.h (révision 1674) +++ source/Mobs/Bat.h (copie de travail) @@ -19,6 +19,7 @@ { } + CLASS_PROTODEF(cBat); } ; Index: source/Mobs/PassiveMonster.h =================================================================== --- source/Mobs/PassiveMonster.h (révision 1674) +++ source/Mobs/PassiveMonster.h (copie de travail) @@ -19,6 +19,7 @@ /// When hit by someone, run away virtual void DoTakeDamage(TakeDamageInfo & a_TDI) override; + } ; Index: source/Mobs/Squid.h =================================================================== --- source/Mobs/Squid.h (révision 1674) +++ source/Mobs/Squid.h (copie de travail) @@ -20,6 +20,7 @@ CLASS_PROTODEF(cSquid); virtual void GetDrops(cItems & a_Drops, cEntity * a_Killer = NULL) override; + } ; Index: source/World.h =================================================================== --- source/World.h (révision 1674) +++ source/World.h (copie de travail) @@ -9,6 +9,8 @@ #define MAX_PLAYERS 65535 +#include + #include "Simulator/SimulatorManager.h" #include "MersenneTwister.h" #include "ChunkMap.h" @@ -40,6 +42,7 @@ class cChestEntity; class cDispenserEntity; class cFurnaceEntity; +class cMobInventory; typedef std::list< cPlayer * > cPlayerList; @@ -458,6 +461,9 @@ inline int GetStorageLoadQueueLength(void) { return m_Storage.GetLoadQueueLength(); } // tolua_export inline int GetStorageSaveQueueLength(void) { return m_Storage.GetSaveQueueLength(); } // tolua_export + /// Deal with the mobs for each tick : spawn, despawn, IA ... + void TickMobs(float a_Dt); + void Tick(float a_Dt); void InitializeSpawn(void); @@ -529,7 +535,7 @@ Int64 m_LastTimeUpdate; // The tick in which the last time update has been sent. Int64 m_LastUnload; // The last WorldAge (in ticks) in which unloading was triggerred Int64 m_LastSave; // The last WorldAge (in ticks) in which save-all was triggerred - Int64 m_LastSpawnMonster; // The last WorldAge (in ticks) in which a monster was spawned + std::map m_LastSpawnMonster; // The last WorldAge (in ticks) in which a monster was spawned (for each megatype of monster) eGameMode m_GameMode; bool m_bEnabledPVP; @@ -561,7 +567,8 @@ cChunkMap * m_ChunkMap; bool m_bAnimals; - Int64 m_SpawnMonsterRate; + std::set m_AllowedMobs; + eWeather m_Weather; int m_WeatherInterval; Index: source/World.cpp =================================================================== --- source/World.cpp (révision 1674) +++ source/World.cpp (copie de travail) @@ -24,29 +24,7 @@ #include "Simulator/VaporizeFluidSimulator.h" // Mobs: -#include "Mobs/Bat.h" -#include "Mobs/Blaze.h" -#include "Mobs/Cavespider.h" -#include "Mobs/Chicken.h" -#include "Mobs/Cow.h" -#include "Mobs/Creeper.h" -#include "Mobs/Enderman.h" -#include "Mobs/Ghast.h" -#include "Mobs/Magmacube.h" -#include "Mobs/Mooshroom.h" -#include "Mobs/Ocelot.h" -#include "Mobs/Pig.h" -#include "Mobs/Sheep.h" -#include "Mobs/Silverfish.h" -#include "Mobs/Skeleton.h" -#include "Mobs/Slime.h" -#include "Mobs/Spider.h" -#include "Mobs/Squid.h" -#include "Mobs/Villager.h" -#include "Mobs/Witch.h" -#include "Mobs/Wolf.h" -#include "Mobs/Zombie.h" -#include "Mobs/Zombiepigman.h" +#include "Mobs/IncludeAllMobs.h" #include "OSSupport/MakeDir.h" #include "MersenneTwister.h" @@ -57,6 +35,11 @@ #include "Vector3d.h" #include "TNTEntity.h" +#include "MobInventory.h" +#include "MobMegaTypeRegister.h" +#include "MobSpawner.h" +#include "EntityManager.h" + #include "tolua++.h" #ifndef _WIN32 @@ -194,7 +177,6 @@ m_WorldAge(0), m_TimeOfDay(0), m_LastTimeUpdate(0), - m_LastSpawnMonster(0), m_RSList(0), m_Weather(eWeather_Sunny), m_WeatherInterval(24000) // Guaranteed 1 day of sunshine at server start :) @@ -258,14 +240,23 @@ m_Storage.Start(this, StorageSchema); m_Generator.Start(this, IniFile); - m_bAnimals = true; - m_SpawnMonsterRate = 200; // 1 mob each 10 seconds + m_bAnimals = IniFile.GetValueB("Monsters", "AnimalsOn", true); + AString sAllMonsters = IniFile.GetValue("Monsters", "Types"); + AStringVector SplitList = StringSplit(sAllMonsters, ","); + for (unsigned int i = 0; i < SplitList.size(); ++i) + { + eMobType ToAdd = cEntityManager::fromStringToEntity(SplitList[i]); + if (ToAdd != E_ENTITY_TYPE_DONOTUSE) + { + m_AllowedMobs.insert(ToAdd); + LOGD("Allowed mob: %s",cEntityManager::fromEntityToString(ToAdd).c_str()); // a bit reverse working, but very few ressources wasted + } + }; + + cIniFile IniFile2("settings.ini"); if (IniFile2.ReadFile()) - { - m_bAnimals = IniFile2.GetValueB("Monsters", "AnimalsOn", true); - m_SpawnMonsterRate = (Int64)(IniFile2.GetValueF("Monsters", "AnimalSpawnInterval", 10) * 20); // Convert from secs to ticks - + { // TODO: Move this into cServer instead: SetMaxPlayers(IniFile2.GetValueI("Server", "MaxPlayers", 100)); m_Description = IniFile2.GetValue("Server", "Description", "MCServer! - In C++!").c_str(); @@ -295,6 +286,12 @@ m_SimulatorManager->RegisterSimulator(m_FireSimulator, 1); m_SimulatorManager->RegisterSimulator(m_RedstoneSimulator, 1); + // Init of the spawn monster time (as they are supposed to have different spawn rate) + m_LastSpawnMonster.insert(std::map::value_type(E_MOB_MEGA_TYPE_HOSTILE,0)); + m_LastSpawnMonster.insert(std::map::value_type(E_MOB_MEGA_TYPE_PASSIVE,0)); + m_LastSpawnMonster.insert(std::map::value_type(E_MOB_MEGA_TYPE_AMBIENT,0)); + m_LastSpawnMonster.insert(std::map::value_type(E_MOB_MEGA_TYPE_WATER,0)); + // Save any changes that the defaults may have done to the ini file: if (!IniFile.WriteFile()) { @@ -454,10 +451,61 @@ m_ChunkSender.Stop(); } +void cWorld::TickMobs(float a_Dt) +{ + // before every Mob action, we have to "counts" them depending on the distance to players, on their megatype ... + cMobInventory MobsInventory; + m_ChunkMap->RegisterMobs(MobsInventory); + for(cMobMegaTypeRegister::tMobMegaTypeList::const_iterator itr = cMobMegaTypeRegister::m_AllMegaTypes().begin(); itr != cMobMegaTypeRegister::m_AllMegaTypes().end(); itr++) + { + cMobInventory::tMobSpawnRate::const_iterator spawnrate = cMobInventory::m_SpawnRate().find(*itr); + // hostile mobs are spawned more often + if (spawnrate != cMobInventory::m_SpawnRate().end() && m_LastSpawnMonster[*itr] < m_WorldAge - spawnrate->second) + { + if ((*itr)==E_MOB_MEGA_TYPE_AMBIENT) + { + MobsInventory.logd(); // MG TODO : remove + } + m_LastSpawnMonster[*itr] = m_WorldAge; + // each megatype of mob has it's own cap + if (!(MobsInventory.isCaped(*itr))) + { + if (m_bAnimals) + { + cMobSpawner Spawner(*itr,m_AllowedMobs); + if (Spawner.CanSpawnSomething()) + { + m_ChunkMap->SpawnMobs(Spawner); + // do the spawn + + for(cMobSpawner::tSpawnedContainer::const_iterator itr2 = Spawner.getSpawned().begin(); itr2 != Spawner.getSpawned().end(); itr2++) + { + (*itr2)->Initialize(this); + BroadcastSpawnEntity(**itr2); + } + } + } + } + } + } + // move close mobs + cMobProximityCounter::sIterablePair allCloseEnoughToMoveMobs = MobsInventory.getProximityCounter().getMobWithinThosesDistances(-1,64*16);// MG TODO : deal with this magic number (the 16 is the size of a block) + for(cMobProximityCounter::tDistanceToMonster::const_iterator itr = allCloseEnoughToMoveMobs.m_Begin; itr != allCloseEnoughToMoveMobs.m_End; itr++) + { + itr->second.m_Monster.Tick(a_Dt,itr->second.m_Chunk); + } + // remove too far mobs + cMobProximityCounter::sIterablePair allTooFarMobs = MobsInventory.getProximityCounter().getMobWithinThosesDistances(128*16,-1);// MG TODO : deal with this magic number (the 16 is the size of a block) + for(cMobProximityCounter::tDistanceToMonster::const_iterator itr = allTooFarMobs.m_Begin; itr != allTooFarMobs.m_End; itr++) + { + itr->second.m_Monster.Destroy(true); + } +} + void cWorld::Tick(float a_Dt) { // We need sub-tick precision here, that's why we store the time in seconds and calculate ticks off of it @@ -480,6 +528,8 @@ m_LastTimeUpdate = m_WorldAge; } + TickMobs(a_Dt); + m_ChunkMap->Tick(a_Dt); TickQueuedBlocks(a_Dt); @@ -594,12 +644,9 @@ } - - - void cWorld::TickSpawnMobs(float a_Dt) { - if (!m_bAnimals || (m_WorldAge - m_LastSpawnMonster <= m_SpawnMonsterRate)) +/* if (!m_bAnimals || (m_WorldAge - m_LastSpawnMonster <= m_SpawnMonsterRate)) { return; } @@ -671,6 +718,7 @@ // A proper mob type was selected, now spawn the mob: SpawnMob(SpawnPos.x, SpawnPos.y, SpawnPos.z, MobType); } +*/ } Index: MCServer/settings.ini =================================================================== --- MCServer/settings.ini (révision 1672) +++ MCServer/settings.ini (copie de travail) @@ -7,9 +7,11 @@ MaxPlayers=100 Description=MCServer - in C++ DefaultViewDistance=9 +PortsIPv6=25565 [Worlds] DefaultWorld=world +World=world_nether [Plugins] ; Plugin=Debuggers @@ -22,13 +24,11 @@ [HelpPlugin] ShowPluginNames=1 -[Monsters] -AnimalsOn=0 -AnimalSpawnInterval=10 -Types=Spider,Chicken,Cow,Pig,Sheep,Squid,Enderman,Zombiepigman,Cavespider,Creeper,Ghast,Silverfish,Skeleton,Slime,Spider,Zombie - [Authentication] Server=session.minecraft.net Address=/game/checkserver.jsp?user=%USERNAME%&serverId=%SERVERID% Authenticate=0 +[RCON] +Enabled=0 + Index: MCServer/users.ini =================================================================== --- MCServer/users.ini (révision 1672) +++ MCServer/users.ini (copie de travail) @@ -1,23 +1,2 @@ -[FakeTruth] +[Feriaman] Groups=Admins - -[Duralex] -Groups=Admins - -[Luthrandel] -Groups=Admins - -[cruisecho] -Groups=Admins - -[Kwen] -Groups=Admins - -[aloe_vera] -Groups=Admins - -[xoft] -Groups=Admins - -[Player] -Groups=Admins \ No newline at end of file