Page 1 of 1

More Event Info

Posted: Thu Aug 08, 2013 8:40 pm
by zer0t3ch
Here's a list of info that I think needs to be added to event calls:

onputitem - What item was placed. Maybe return itemstack (like onplayermineditem)
onpickedupitem - What item was picked up? (like onplayermineditem)
onsectorscanned - Add area generated (like onchunkgenerated)

finally, one quick question, I see in defines.lua something called controllers, (ghost, player, god) how do I change these? (I want to add a godmode)

Re: More Event Info

Posted: Fri Aug 09, 2013 7:11 am
by SilverWarior
zer0t3ch wrote:finally, one quick question, I see in defines.lua something called controllers, (ghost, player, god) how do I change these? (I want to add a godmode)
Game already has God mode. All you have to do is start Sandbox scenario from scenarios screen.
Also if you wanna add God mode in your custom scenario I suggest you check control.lua from Sandbox scenario to see how it is implemented there.

Othervise theese were added in preparation for multiplayer mode:
. ghost is reserved for spectators (cant affect gameworld in any way)
- player is prety obvious
- god is for god mode where you can still can affect gameworld in RTS way but have no character so you can't be kiled :D

Re: More Event Info

Posted: Fri Aug 09, 2013 8:15 am
by drs9999
zer0t3ch wrote:onsectorscanned - Add area generated (like onchunkgenerated)
This event returns the radar-entity.
So if I measured it correctly the scanned sector of a radar is the radar-positon +/- 128 blocks

+1 for the other event-suggestions

Re: More Event Info

Posted: Fri Aug 09, 2013 1:04 pm
by zer0t3ch
SilverWarior wrote:
zer0t3ch wrote:finally, one quick question, I see in defines.lua something called controllers, (ghost, player, god) how do I change these? (I want to add a godmode)
Game already has God mode. All you have to do is start Sandbox scenario from scenarios screen.
Also if you wanna add God mode in your custom scenario I suggest you check control.lua from Sandbox scenario to see how it is implemented there.

Othervise theese were added in preparation for multiplayer mode:
. ghost is reserved for spectators (cant affect gameworld in any way)
- player is prety obvious
- god is for god mode where you can still can affect gameworld in RTS way but have no character so you can't be kiled :D
Thanks both of you, I had no idea about the sandbox, so I'll go have a look at that. It should get me closer to finishing my project. (I'm doing this mod)