summaryrefslogtreecommitdiffstats
path: root/src/Mobs/Monster.h (unfollow)
Commit message (Collapse)AuthorFilesLines
2015-01-16Converted Monster to std::chronoTycho1-5/+5
2015-01-11Initial convertion of a_Dt to std::chronoTycho1-1/+1
also refactored cWorld::m_WorldAge and cWorld::m_TimeOfDay
2014-12-18Added Entity GuardianMasy981-1/+1
2014-12-01MobSpawner fixes.Howaner1-1/+1
2014-11-29Many api fixes, add vanilla names to mob type -> string functions and mob spawner fixes.Howaner1-4/+7
2014-11-26Merge remote-tracking branch 'origin-master' into c++11Tiger Wang1-3/+5
2014-11-15Mobs: Fixed crash with terrain too high.Mattes D1-3/+5
2014-10-12convert old style casts to fix warningsSteven Riehl1-32/+28
2014-10-05Removed obsolete cMonster::eType.madmaxoft1-3/+0
Has been replaced with global eMonsterType.
2014-09-27Fixed minor style issues.madmaxoft1-1/+1
2014-09-25Fixed styleTycho1-0/+3
2014-09-19Implemented mob spawner.Howaner1-1/+1
2014-09-17Added first test to show the object can be createdTycho1-45/+9
2014-09-02Renamed SetWalkSpeed() to SetRelativeWalkSpeed()Howaner1-3/+3
2014-09-02Added the new functions to APIDump.Howaner1-2/+2
2014-09-02Added SetCustomName() to players.Howaner1-1/+2
2014-09-01Added name tagHowaner1-0/+2
2014-09-01Added CustomName to cMonster.Howaner1-1/+19
2014-08-30Added SetWalkSpeed() to cMonster.Howaner1-0/+5
2014-07-24Removed redundant semicolons and re-added warningarchshift1-1/+1
2014-07-19Monsters: Made IsUndead overridable by the respective mob classesarchshift1-1/+1
2014-07-19Fixed style: spaces after commas.madmaxoft1-1/+1
2014-07-18Monster fixesTiger Wang1-1/+0
* Fixes #1203 * Fixes #627
2014-07-18Fixed spaces before commas.madmaxoft1-3/+3
2014-07-17Basic style fixes.madmaxoft1-4/+4
2014-07-17Normalized comments.madmaxoft1-7/+7
This was mostly done automatically and then visually inspected for obvious errors. All //-style comments should have a 2-space separation from the code, and 1 space after the comment sign.
2014-07-04Tailored death messagesTiger Wang1-1/+1
2014-06-19EntityEffects.x -> EntityEffect.x, Object-Oriented effectsarchshift1-2/+0
Changed effect map to take a pointer of the effect as a result.
2014-06-17Pawn: renamed HandleEntityEffects to HandleEntityEffectarchshift1-1/+1
Exported entity effect functions for ToLua and documented them in APIDesc.lua
2014-06-17Monster: added IsUndead(), undead-specific entity effectsarchshift1-0/+6
2014-04-26Fixed mobs that don't naturally spawn.archshift1-0/+1
2014-04-26Add entity invulnerableHowaner1-1/+1
2014-04-25Giants!archshift1-1/+1
Changed mfMaxplusone to mfUnhandled for readability, and fixed a default case warning.
2014-04-17Added new AI rulesTiger Wang1-2/+2
+ Added new AI rules handling cacti and large heights * Fixed cIniFile not recognising comments in cIniFile::ReadFile() * Fixed users.ini not being properly generated * Changed all instances of (int)floor(GetPosXXX()) to POSXXX_TOINT
2014-02-24Fixed Formatting, added compiler warning suppressing methods, fixed commentsTheJumper1-2/+2
2014-02-23Fixed Formatting, Added DropChances and CanPickUpLoot attributes to MonstersTheJumper1-0/+35
2014-02-23Fixed Formatting, Added DropChances and CanPickUpLoot attributes to MonstersTheJumper1-0/+32
2014-02-23Fixed Formatting, Added DropChances and CanPickUpLoot attributes to MonstersTheJumper1-10/+13
2014-02-23Fixed Formatting, Added DropChance attributes to MonstersTheJumper1-0/+20
2014-02-22Changed formatting, encapsuled armor drop, introduced better static Enchantment IDsTheJumper1-1/+7
2014-02-22Monster.h: Added doxy-comments for drop methodsTheJumper1-0/+3
2014-02-21Fixed Mob Drops, Add Rare and Uncommon Drops, Looting inflicts DropsTheJumper1-0/+3
2014-02-11Fixed #627Tiger Wang1-2/+0
- Attack() is now called from cAggressive instead of cMonster * Monsters can no longer attack through walls * Should fix last remnants of player damage after teleporting (that both STR and bearbin contributed fixes to :P)
2014-02-03Exporded World:FindClosestPlayer, Item:IsEnchantable and Monster:MoveToPosition to Lua APItonibm191-0/+1
2014-01-25Implemented fall damage for mobsTiger Wang1-2/+6
+ Implemented mobile fall damage * Formatting fixes + Defined new Position->Integer macros
2014-01-25Mob bugfixesTiger Wang1-2/+10
* Mobs no longer require constant line-of-sight to a player to remain aggravated * Fixed an ASSERT * Fixed mobs jumping * Fixed Idle state not properly using AI + Added FILE_IO_PREFIX to favicon loading + Implemented #563
2014-01-24Miscellaneous improvementsTiger Wang1-13/+9
2014-01-24Large reworking of mob code [SEE DESC]Tiger Wang1-19/+49
+ Implemented better pathfinding - Removed lots of unused variables, functions, etc. * Changed some variable types * Other miscellaneous fixes, and also completes the previous PRs
2013-12-20Sorted a few constructors to remove warnings.madmaxoft1-1/+1
2013-11-24Moved source to srcAlexander Harkness1-0/+0
2013-11-10Bundled fixes [SEE DESC]Tiger Wang1-5/+2
* Fixed pickups spawning in an incorrect position from a JukeBox * Pickups make a popping sound in Prtcl1.7 * Arrows make a *what sort of sound does an arrow make anyway‽* when hitting a block, and a popping sound when fired * Mobs again have metadata * Fixed Prtcl1.7 not using valid JSON to kick a client * Minecarts and arrows again have metadata
2013-10-25cMonster: Improved doxycomments.madmaxoft1-2/+2
2013-10-24Renamed cMonster::GetSpawnRate() to GetSpawnDelay().madmaxoft1-2/+2
2013-10-20Fixed memory leaks in cMobCensus, moved GetSpawnRate() to cMonster.madmaxoft1-0/+3
2013-10-20Moved all MobTypesManager functions to cMonster.madmaxoft1-2/+24
This removes some of the memory leaks and is more logical in structure. Also the functions are exported to Lua.
2013-10-20Fixed loading allowed mobs in world.madmaxoft1-8/+8
2013-10-09Second round of fixesTiger Wang1-0/+6
* Implemented suggestions
2013-09-18Added moar mobs!Tiger Wang1-21/+23
+ Added dragons + Added golems + Added giants + Added horses + Added some missing items + Added missing spawn egg metas
2013-09-17Fixed undead burningTiger Wang1-1/+1
(c'mon xoft, test ya code :P)
2013-09-16Exported cMonster:GetMobType() to the Lua API.madmaxoft1-1/+3
2013-09-10Inside cMonster::getMobFamily() : replacing Polymorphism by Map, in order to remove redundancymgueydan1-1/+2
2013-09-08Implementing the MobSpawner (not used yet) that contains spawning rulesmgueydan1-1/+4
2013-09-07Adding a getType in Monster that return an enum instead of an int or charmgueydan1-1/+2
2013-09-07Adding Family for monsters : Hostile/Passive/Water/Ambientmgueydan1-0/+10
2013-09-06Moved daylight burning directly into cMonster.madmaxoft1-0/+7
2013-09-05Moved daylight burning directly into cMonster.madmaxoft1-0/+7
2013-08-19Moved entities into the Entities subfolder.madmaxoft1-1/+1
2013-08-16Replaced E_ENTITY_TYPE_XXX with cMonster::mtXXX.madmaxoft1-1/+35
Also slightly improved the spawning algorithm.
2013-07-01Rewritten entity-on-fire management ("forever on fire" bugs)madmaxoft@gmail.com1-2/+2
Fixes FS #297 and part of FS #403. Added sizes to all entities. Moved all damage-related functions from cPawn to cEntity API change: renamed cPawn:TeleportTo() to cEntity:TeleportToCoords() git-svn-id: http://mc-server.googlecode.com/svn/trunk@1635 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-04-22Moved physics to the cEntity class from the derivative classes (cMonster, cPickup). Added physics override to cPlayer to disable physics calculations. Fixed bug with pitch calculations on mobs.keyboard.osh@gmail.com1-6/+0
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1400 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-04-13Rewritten entities so that they are owned by individual chunks and ticked within their chunk's Tick()madmaxoft@gmail.com1-8/+8
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1385 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-02-21Moved the Speed member into cEntity class instead of its descendants.madmaxoft@gmail.com1-1/+0
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1222 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-12-22MTRand reference is now passed as a Tick() parameter so that it isn't created and destroyed over and over again. All entities will handle physics (empty callback for now)madmaxoft@gmail.com1-8/+8
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1096 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-12-22Reduced most mobs' constructors to oneliners by passing parameters to superclassesmadmaxoft@gmail.com1-2/+10
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1095 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-12-21Added sounds to levers and mobsluksor111@gmail.com1-0/+3
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1093 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-12-21Reworked the IsA() / GetClass() framework to actually be useful. Added GetParentClass().madmaxoft@gmail.com1-3/+2
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1090 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-12-21Refactored the TakeDamage API to take equipped weapon and armor into consideration (PvP untested)madmaxoft@gmail.com1-10/+15
http://forum.mc-server.org/showthread.php?tid=625 git-svn-id: http://mc-server.googlecode.com/svn/trunk@1087 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-24Source files cleanup: The rest of the files renamed.madmaxoft@gmail.com1-3/+3
git-svn-id: http://mc-server.googlecode.com/svn/trunk@887 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-23Source files cleanup: Mobs-related files in a separate subfolder, renamed.madmaxoft@gmail.com1-6/+5
git-svn-id: http://mc-server.googlecode.com/svn/trunk@883 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-24Monster classes don't use cPackets. Chat messages are sent / broadcast without cPackets. BlockEntities don't use cPackets.madmaxoft@gmail.com1-8/+9
git-svn-id: http://mc-server.googlecode.com/svn/trunk@783 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-08-19Almost all packets' handling is now rewritten not to use cPacket descendants elsewhere than in cClientHandle.madmaxoft@gmail.com1-2/+2
git-svn-id: http://mc-server.googlecode.com/svn/trunk@761 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-14Attempt to bring sanity to newlines across systems.cedeel@gmail.com1-101/+101
git-svn-id: http://mc-server.googlecode.com/svn/trunk@606 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-06-06Item-dropping code rewritten and centralized - now there's only one place to modify if we want to split or merge same-item drops: cWorld:SpawnItemPickups(). Also, mined blocks can now drop more items, and they recognize if they're being mined by the correct tool.madmaxoft@gmail.com1-3/+7
git-svn-id: http://mc-server.googlecode.com/svn/trunk@561 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-05-25Merged the composable_generator branch into the trunkmadmaxoft@gmail.com1-1/+10
git-svn-id: http://mc-server.googlecode.com/svn/trunk@504 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-02-15No longer using pointers for Vector3(f/d/i) in cEntity's and cTracerfaketruth1-2/+2
git-svn-id: http://mc-server.googlecode.com/svn/trunk@268 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-02-13Rewritten most of the code for multithreading; still not 100%, but getting there. If this commit proves to be too problematic, we can always undo it.madmaxoft@gmail.com1-2/+3
git-svn-id: http://mc-server.googlecode.com/svn/trunk@251 0a769ca7-a7f5-676a-18bf-c427514a06d6
2011-12-28- Implemented Drops from Burning animalslapayo94@gmail.com1-6/+0
- added right monster health and attack strength - refactored the Pawn/Monster/Player class a little bit - changed some namings to fit the style git-svn-id: http://mc-server.googlecode.com/svn/trunk@140 0a769ca7-a7f5-676a-18bf-c427514a06d6
2011-12-26- improved ClosestPlayerDetection (Really the closest now ;))lapayo94@gmail.com1-1/+1
- renamed function because the old one wasn´t listing - improved some time vars so no move gets dropped when the server laggs for a few seconds git-svn-id: http://mc-server.googlecode.com/svn/trunk@124 0a769ca7-a7f5-676a-18bf-c427514a06d6
2011-12-26 - Linux compatible fixes including updated makefilemtilden@gmail.com1-0/+1
- Mersenne Twister still says uint32 but it's now signed for compatibility with random uses needing negative values - Server seed is sent to clients, but needs to be able to be signed long long later on for authentic reasons - Protocol Version is required to match to ensure client compatibility, this should probably have a settings.ini check as well as store the value there git-svn-id: http://mc-server.googlecode.com/svn/trunk@121 0a769ca7-a7f5-676a-18bf-c427514a06d6
2011-12-25- Fixed Bug #99 -> Mobs no longer bother you in creative modelapayo94@gmail.com1-0/+3
- refactored many things in the Monster system git-svn-id: http://mc-server.googlecode.com/svn/trunk@112 0a769ca7-a7f5-676a-18bf-c427514a06d6
2011-12-21- Crafting fixed in 1.0.0lapayo94@gmail.com1-0/+4
- Server compatible with the weapons and equip again. (Some Packets were incompatible) - fixed bucket bugs (not all) - Fixed clients getting crashed by wrong Pickups - fixed nearly all mob drops. (Check wheather they are burning is missing Big Grin) - maybe some other things I can´t recall atm Big Grin git-svn-id: http://mc-server.googlecode.com/svn/trunk@94 0a769ca7-a7f5-676a-18bf-c427514a06d6
2011-10-03MCServer c++ source filesfaketruth1-0/+85
git-svn-id: http://mc-server.googlecode.com/svn/trunk@3 0a769ca7-a7f5-676a-18bf-c427514a06d6