Commit Graph

623 Commits

Author SHA1 Message Date
Dico200
1750c82208 Changed all CommandExecutor arguments
Added arguments command and label to all command executor functions,
hopefully for massive performance increase.

This is due to the following mess in PythonLoader:
``` Java
@Override
public boolean onCommand(CommandSender sender, Command command, String
label, String[] args) {
boolean result;
if (argcount == -1) {
try {
result = call(4, sender, command, label, args);
argcount = 4;
} catch (PyException e) {
//this could goof up someone ... they'll probably yell at us and
eventually read this code ... fuck them
if (e.type == Py.TypeError && (e.value.toString().endsWith("takes
exactly 3 arguments (4 given)") || e.value.toString().endsWith("takes
exactly 4 arguments (5 given)"))) {
result = call(3, sender, command, label, args);
argcount = 3;
} else if (e.type == Py.TypeError && (e.value.toString().endsWith("takes
exactly 2 arguments (4 given)") || e.value.toString().endsWith("takes
exactly 3 arguments (5 given)"))) {
result = call(2, sender, command, label, args);
argcount = 2;
} else {
throw e;
}
}
} else {
result = call(argcount, sender, command, label, args);
}
return result;
}
```

Note: Still WIP on reports - I'm working on making it keep solved
reports to fix issue 10
2015-03-19 23:51:33 +01:00
Dico200
d993cc223a Changed AC from toggle or , fixes #16
This solution to log any AC isn't very optimised as it will check for
permission twice. Any fix for this?

Anyways it now runs /ac <msg> from the player every time.
2015-03-19 22:02:07 +01:00
Dico200
40fa9c0692 simplified /me in misc.py
Replaced online user iteration with broadcast method
2015-03-19 21:51:13 +01:00
Dico200
5d23fe490b Remove annoying Damnspam plugin header
I hate plugin_header, can we maybe make it return a string which we
append the message to instead? ._.
or create like plugin_message(String pluginname, Player recipient,
String message)
2015-03-19 20:25:47 +01:00
Dico200
9476a1b0b7 Remove redundant try/catch 2015-03-18 22:26:54 +01:00
Dico200
194958f034 me cmd appearance hotfix (made new cmd) fixes #15 2015-03-18 22:25:58 +01:00
Dico200
55ac6c0977 Change /sudo command fixes #14 2015-03-18 21:09:49 +01:00
Dico200
39654bf4a7 Re-enabled AdminNotes module 2015-03-17 00:56:50 +01:00
jomo
4357c46085 copy dict keys before iterating
python doesn't like changing dicts while iterating over that dict
2015-03-15 05:00:04 +01:00
jomo
1db0ac4cd5 Revert "remove redundant loop"
This reverts commit cc50dc30bc.
2015-03-15 04:40:09 +01:00
jomo
1e7bd51b3b debug pmutils player leave event 2015-03-15 04:36:08 +01:00
jomo
cc50dc30bc remove redundant loop 2015-03-15 04:28:56 +01:00
jomo
a87ad7b2e9 fix all bukkit/uuid issues in pmtoggle 2015-03-15 04:26:53 +01:00
jomo
dbfc1dd2a2 merge 2015-03-15 04:19:02 +01:00
Dico200
f1856d3243 Disable adminnotes, fix stuff 2015-03-15 04:17:12 +01:00
Dico200
5ef17713a4 Change runas() in helpers to use player.chat 2015-03-15 04:03:40 +01:00
Dico200
96b4cb2e3f Disabled snowbrawl 2015-03-15 04:00:51 +01:00
Dico200
88a935f473 Fixed UUID problem in Pmtoggle
Thanks @jomo  for pointing out
2015-03-15 03:00:55 +01:00
Dico200
ad70989a40 Add colon in pmtoggle 2015-03-15 03:00:55 +01:00
Dico200
a24c7092f7 Add check if chatevent is cancelled in pmtoggle 2015-03-15 03:00:52 +01:00
Dico200
dc307fc5f0 cherry-pick pmtoggle into master 2015-03-15 03:00:18 +01:00
jomo
966943b9a2 Merge branch 'master' into dev 2015-03-15 02:58:03 +01:00
Dico200
1b2b3c2fa9 Fixed UUID problem in Pmtoggle
Thanks @jomo  for pointing out
2015-03-15 02:41:58 +01:00
Dico200
c0c1879fde Add colon in pmtoggle 2015-03-15 02:30:52 +01:00
Dico200
017d53928a Add check if chatevent is cancelled in pmtoggle 2015-03-15 02:30:33 +01:00
Dico200
bab2a6e198 Added pmtoggle to shared["load_modules"] in main 2015-03-15 02:20:41 +01:00
Dico200
5a669893b4 Remove redundant try/except in Pmtoggle module 2015-03-15 02:18:02 +01:00
Dico200
9a3942c034 pmtoggle works now, Fixes comments by Jomo
BTW: I didn't use retrieve_player as it gets an Offline player which
makes it slower and I know the player is online. That's why I used
Bukkit.getPlayer(juuid(uuidstring)). (line 40)
2015-03-15 02:16:30 +01:00
Dico200
43a8ec9481 Added pmtoggle module
pmtoggle adds /tm [player](togglemessage).
When activated, any chat message you send will be sent as:
/msg [player] [msg]
2015-03-15 01:13:36 +01:00
Dico200
1fd3d591f9 Fixed a little code in snowbrawl.py... even if its an outdated version. 2015-02-21 15:55:41 +01:00
jomo
2246b9f5a8 fix mentio color codes 2015-02-09 21:31:31 +01:00
PanFritz
60181bd657 Removed . from operators, remade line 17 2015-01-17 14:33:49 +01:00
PanFritz
9b4d73cfe2 Added check for . 2015-01-17 14:03:20 +01:00
PanFritz
c1a69c6a62 Fixed, upping snowball damaga 2015-01-17 05:31:32 +01:00
PanFritz
3bcfe42d65 Fixed, upping snowball damaga 2015-01-17 05:30:15 +01:00
PanFritz
ebe7b433ac Fixed, upping snowball damaga 2015-01-17 05:29:08 +01:00
PanFritz
511e4aa543 Fixed, upping snowball damaga 2015-01-17 05:27:52 +01:00
PanFritz
97733e7701 Fixed, upping snowball damaga 2015-01-17 05:17:27 +01:00
PanFritz
194d10b3c2 Fixed, upping snowball damaga 2015-01-17 05:16:28 +01:00
PanFritz
b8df8f8a6b Fixed, upping snowball damaga 2015-01-17 05:15:04 +01:00
PanFritz
c6ff9ccfa7 Fixed, upping snowball damaga 2015-01-17 05:13:38 +01:00
PanFritz
f9a99aaf0b Fixed, upping snowball damaga 2015-01-17 04:51:22 +01:00
PanFritz
955e40dc34 Fixed, upping snowball damaga 2015-01-17 04:49:41 +01:00
PanFritz
eba2b6731f Fixed, upping snowball damaga 2015-01-17 04:47:30 +01:00
PanFritz
a18cc32c60 Fixed, upping snowball damage 2015-01-17 04:41:45 +01:00
PanFritz
02d073eb2c Changed entity name 2015-01-17 04:40:10 +01:00
PanFritz
c062ce6782 changed getType to getTypeId 2015-01-17 04:36:41 +01:00
PanFritz
ea3331f540 changed getType to getTypeId 2015-01-17 04:34:21 +01:00
PanFritz
583e2cd4f9 changed getType to getTypeId 2015-01-17 04:31:03 +01:00
PanFritz
041bc029ca More debug code 2015-01-17 04:25:23 +01:00