08-08-2013, 08:11 PM
Yep. GTG out and do something, but I'll see about doing these later today.
Random Chitchat 2012-2016
|
08-08-2013, 08:11 PM
Yep. GTG out and do something, but I'll see about doing these later today.
08-08-2013, 09:04 PM
(08-08-2013, 07:36 PM)xoft Wrote: Oh, by the way, the entity spawning hooks have been implemented and seem to work. I wonder what kind of plugins will this sparkIm planning to make a mob spawning plugin. When an entity spawn, it will check if if its in the right biome and if not, kill mob. One question, OnMonsterSpawned is called only when a monster is spawned or when an animal is spawned too?
Monster is anything "living", it equals Mob in the default terminology. We haven't yet settled the terminology down, sometimes we use Mob, sometimes Monster, but they are the same.
You can see that in the inheritance graph here: http://mc-server.xoft.cz/wiki/API%20clas...tities.png Behold the c++ template master. I have bent LuaState several times over until calling named Lua functions is almost as easy as calling a C++ function: bool FirstReturnedValue = false; int SecondReturnedValue = 0; m_LuaState.Call("FunctionName", a_World, a_Player, cLuaState::Return, FirstReturnedValue, SecondReturnedValue);This calls function FunctionName() that takes 2 args (World, Player) and returns 2 values (a bool and an int). Pity that each combination of {#args, #returns} must be specifically written in cLuaState, but still, this is a major step-up.
08-09-2013, 12:17 AM
Mob is a stupid name for an enemy/sentient/monster/whatever
08-09-2013, 12:25 AM
I tried the latest rev and now when I break a block I get:
Quote:Error in plugin WorldEdit: Could not find function OnPlayerEating()
Oops, probably a mixed up constant in the cPlugin_NewLua. I'll fix it momentarily.
Fixed. I'm glad that the error reporting in the new Lua interface works, I didn't try it out (08-09-2013, 12:17 AM)FakeTruth Wrote: Mob is a stupid name for an enemy/sentient/monster/whatever On the other hand, Monster is a stupid name for sheep, chicken etc. I personally like Mob better, especially because its meaning has kinda already stuck in the MC community. Thanks given by: NiLSPACE
08-09-2013, 12:44 AM
Yeah I think Mob is probably the best name - it's already established in minecraft and it doesn't get confusing whatever type it is.
08-09-2013, 12:45 AM
Monster is not good either no :p You shouldn't encourage Notches strange naming of things :p
08-09-2013, 02:03 AM
Should I be dumping the tests I write back into the source code as well?
Then we could have a script that would run the tests and report on failures that anybody could use.
08-09-2013, 03:18 AM
What's up with the NoiseTest in the tests folder. It seems to test the speed of the noise gens. Anybody mind if I re-purpose the folder for different tests?
|
« Next Oldest | Next Newest »
|