fix docs for events.js
This commit is contained in:
parent
a314bf849f
commit
e0d5abb5f6
2 changed files with 2 additions and 0 deletions
|
@ -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
|
||||
|
|
|
@ -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
|
||||
|
|
Reference in a new issue