Commit graph

404 commits

Author SHA1 Message Date
Ruud Schramp
1122c2ef23 Small error in demo code, index missing 2016-03-28 15:44:07 +00:00
walterhiggins
8bc648ec29 Fix issue #256 and fix issue #287 2016-03-19 12:09:26 +00:00
walterhiggins
f9f60f7702 Merge branch 'requireCacheAccess' of https://github.com/MrVoltz/ScriptCraft into MrVoltz-requireCacheAccess 2016-01-02 11:57:04 +00:00
walterhiggins
6cfe460e37 Merge branch 'refreshFix' of https://github.com/MrVoltz/ScriptCraft into MrVoltz-refreshFix 2016-01-02 11:29:27 +00:00
Martin P
ef04a62c54 Allow access to module cache through require.cache and require.resolve 2016-01-01 17:43:27 +01:00
Martin P
d27747b3a0 Fix refresh(): add skipOpCheck parameter, unregister event handlers & cancel tasks (only Bukkit) 2016-01-01 17:40:00 +01:00
Martin P
a0b46b0975 Fixed: Allow loading json using require() 2016-01-01 17:35:33 +01:00
walterhiggins
badf8b5470 Undoing merge of PR #278 2016-01-01 12:55:53 +00:00
Walter Higgins
eef507fdfe Merge pull request #278 from MrVoltz/patch-1
Allow loading json using require()
2015-12-31 12:07:45 +00:00
Walter Higgins
7090ac5c5b Merge pull request #274 from aaron-powell/master
Fixed bukkit version of recipes.js module
2015-12-30 16:26:32 +00:00
walterhiggins
aa42b74119 Added lightning module 2015-12-30 13:01:11 +00:00
walterhiggins
e285bb6891 added new entities and spawn modules 2015-11-21 17:07:40 +00:00
MrVoltz
7b309dba16 Allow loading json using require() 2015-11-18 15:50:52 +01:00
walterhiggins
4aa28c0af3 Make blocktype work with numbers 2015-11-08 16:23:02 +00:00
Aaron
893dbd6aaa Fixed bukkit version of recipes.js module
I was having trouble adding recipes to my bukkit server using ScriptCraft.  It looks like the example in js/modules/recipes.js only works on a CanaryMod server, and the original version of js/modules/bukkit/recipes.js caused type related errors and didn't seem to implement Spigot/Bukkit methods properly.  With these changes I can now create a custom recipe and add it to the server with the following (note that the recipes.add() function both creates a bukkit ShapedRecipe AND adds the recipe to the server):

var items = require("items");
var recipes = require("recipes");
var events = require("events");

var bow = items.bow(1);
var tnt = items.tnt(1);
var explodeBow = items.bow(1);

var explodeBowMeta = explodeBow.getItemMeta();
explodeBowMeta.setDisplayName("Bow of Exploding");
explodeBowMeta.setLore(["Excite. Very boom."]);
explodeBow.setItemMeta(explodeBowMeta);

var explodeBowRecipe = recipes.add(
{
    result: explodeBow,
    ingredients: {B: bow, T: tnt},
    shape: ["   ", "TB ", "   "]
});
2015-10-02 15:55:31 -07:00
Maarten Verwijs
5dd897aaa9 Fixes incompatibility where utils.players is []
Using spigot 1.8.8, utils.players() always returns empty due to usage of deprecated calls.

This fixes it on my machine, but not tested on other 'bukkit' servers.
2015-09-27 21:07:12 +02:00
Walter Higgins
e3079047a1 Merge pull request #264 from CoderDojoStirling/classroom-example-file
Put example js file in classroom player directory.
2015-08-29 19:48:33 +01:00
walterhiggins
bff23932a7 Fix issue #269 for both spigot and canary - make sure new stairs don't cause same issue again. 2015-08-29 19:07:19 +01:00
walterhiggins
0dbff00703 Fix issue #269 2015-08-29 12:09:25 +01:00
walterhiggins
bef42e3148 Fixes issue #265 (sound module broken in bukkit/spigot/glowstone) 2015-08-16 11:50:27 +01:00
Gregory Huczynski
9e7cb07a8f Put example js file in classroom player directory. 2015-08-12 18:40:49 +01:00
walterhiggins
62ff9034a6 Fix issue #261 2015-08-01 12:33:40 +01:00
walterhiggins
5fc1b9cb05 fixes issue #254 2015-06-07 15:15:42 +01:00
Walter Higgins
db4be7950f Merge pull request #251 from carlrobert/patch-20
Remove unused variables bkBukkit, bkSign
2015-06-07 14:18:23 +01:00
Walter Higgins
1ee38d809e Merge pull request #247 from carlrobert/patch-17
Known times() limitation mentioned
2015-06-07 14:09:30 +01:00
Walter Higgins
6ab9581a62 Recipes module - workaround for JDK-8072596 2015-06-07 10:09:53 +01:00
Walter Higgins
fdd599ca97 fixing fireworks problem on mac os 2015-06-01 12:29:07 +01:00
Robert Storlind
146a27263b Remove unused variables bkBukkit, bkSign
Not sure why the diff explodes for this two-line change though.
2015-06-01 08:34:54 +02:00
walterhiggins
ff4ca68366 Use DyeColor.values() to get better array of colors for fireworks. 2015-05-31 20:04:05 +01:00
walterhiggins
4a1c1b7b01 Provide more helpful errors when trying to require non-existent modules 2015-05-31 16:44:42 +01:00
walterhiggins
10497efae3 3.1.5 fix events.connect/events.connection mismatch 2015-05-31 09:09:42 +01:00
Robert Storlind
0b119da4d7 Known times() limitation mentioned
Also took the liberty of tidying up some formatting.
2015-05-29 17:45:42 +02:00
walterhiggins
734e058e9a adding block-colors module 2015-05-24 12:18:00 +01:00
walterhiggins
4a2ea3c26a Added quartz pillar and chiseled blocks. 2015-05-17 18:46:36 +01:00
walterhiggins
b55be089f8 Fix bed to work with latest CanaryMod 1.2.0 2015-05-17 18:46:04 +01:00
walterhiggins
6224845e8b remove ambiguity in call to teleportTo() 2015-05-17 15:07:33 +01:00
Walter Higgins
e6be40c5c8 Merge pull request #222 from monowii/master
Fixed teleport util for CanaryMod
2015-05-17 14:50:08 +01:00
Walter Higgins
bda8d96916 Merge pull request #242 from carlrobert/patch-16
Trivial typo
2015-05-09 14:01:19 +01:00
Walter Higgins
754dd687e1 Merge pull request #236 from vorburger/SomeMinorCleanUp
Thanks for this @vorburger . I'm interested in how you used blockly with ScriptCraft - is there source code for that integration anywhere?
2015-05-09 14:00:25 +01:00
Robert Storlind
b4af7553f9 Trivial typo 2015-05-06 21:50:57 +02:00
Apple Lam
ebd42ed347 Fix typo
fix http module for bukkit.
2015-04-28 20:09:59 +08:00
Michael Vorburger
c987058aae .gitignore with two files which are apparently generated 2015-04-22 21:31:32 +02:00
Michael Vorburger
0423141bf1 Just fixed formatting for better readability, no real changes. 2015-04-19 16:40:06 +02:00
Walter Higgins
52070cffdc Merge pull request #231 from carlrobert/patch-11
Bukkit and CanaryMod links corrected. jslint.
2015-04-16 21:25:05 +01:00
Robert Storlind
70f97bea7c constructor spelling ... 2015-04-14 20:14:18 +02:00
walterhiggins
4bc1e2f582 Deprecating plugin() function 2015-04-11 10:43:33 +01:00
Robert Storlind
baac1cbe3f Bukkit and CanaryMod links corrected. jslint.
The bukkit link was broken, btw.
2015-04-10 22:25:44 +02:00
Robert Storlind
d70099f475 No longer advertise copy & paste
Drones are for building only.
2015-04-09 08:41:55 +02:00
walterhiggins
06d80171fb Added inventory module for bukkit too 2015-03-24 19:37:44 +00:00
walterhiggins
1a4b087562 Added new 'inventory' module. 2015-03-22 14:05:19 +00:00