fix docs for events.js

This commit is contained in:
walterhiggins 2014-04-26 20:34:45 +01:00
parent a314bf849f
commit e0d5abb5f6
2 changed files with 2 additions and 0 deletions

View file

@ -869,6 +869,7 @@ events.on( 'block.BlockBreakEvent', function( evt ) {
evt.player.sendMessage( evt.player.name + ' broke a block!');
this.unregister();
} );
```
The `this` keyword when used inside the callback function refers to
the Listener object created by ScriptCraft. It has a single method

View file

@ -55,6 +55,7 @@ events.on( 'block.BlockBreakEvent', function( evt ) {
evt.player.sendMessage( evt.player.name + ' broke a block!');
this.unregister();
} );
```
The `this` keyword when used inside the callback function refers to
the Listener object created by ScriptCraft. It has a single method