I've done a very small amount of Lua coding before. For my current mod project I'll need to do a fair amount. Before I dive into it, I'd like to clarify one thing that I've wondered about for a while.
In the Lua Callback Reference list HERE, there's a whole list of functions that the game accepts. I understand how to use a lot of them but there's one way of using certain ones that I've seen a lot that I really don't get. Here's an example from the teleport sample code (not Zerted's):
Code: Select all
function MoveEntityToNode(entIn,pathIn,nodeIn)
Code: Select all
onvehkill = OnObjectKill(
function(object, killer)
if IsCharacterHuman(killer) and GetEntityClass(object) == GetEntityClassPtr("imp_hover_speederbike") then
counted_points = counted_points + 1
end
end)
Thanks in advance. I know there's probably an obvious answer I'm missing.





