Skip to content

Instantly share code, notes, and snippets.

View RoboMWM's full-sized avatar

RoboMWM

View GitHub Profile
@RoboMWM
RoboMWM / damageandvelocities.md
Last active October 27, 2016 16:00
Knockback, damage, and other caveats/quirks to note.

Note: When I mention "attack," I mean a melee attack (i.e. not with a snowball or bow).

EntityDamageByEntityEvent: When a player attacks another player, the cause is ENTITY_ATTACK

Using Entity#damage(damage, (Player)source): Haven't tested with other entities as source, but this fires a EntityDamageByEntityEvent, as if the source attacked the Entity (complete with a cause = ENTITY_ATTACK).

PlayerVelocityEvent: When a player attacks another player, a PlayerVelocityEvent is fired. This velocity event is 0 in the x and z direction (perhaps to reset the player's current movement?). However, if this velocity event is canceled, another velocity event is fired - this time with appropriate knockback values

Ideas why:

  • perhaps to "add on" to whatever prior velocity the player might be experiencing (since prior was canceled)
[PandaWire] Enabling PandaWire v1.0.1-SNAPSHOT
java.lang.IllegalAccessException: Can not set static final net.minecraft.server.v1_10_R1.BlockRedstoneWire field net.minecraft.server.v1_10_R1.Blocks.REDSTONE_WIRE to net.md_5.PandaRedstoneWire
at sun.reflect.UnsafeFieldAccessorImpl.throwFinalFieldIllegalAccessException(Unknown Source)
at sun.reflect.UnsafeFieldAccessorImpl.throwFinalFieldIllegalAccessException(Unknown Source)
at sun.reflect.UnsafeQualifiedStaticObjectFieldAccessorImpl.set(Unknown Source)
at java.lang.reflect.Field.set(Unknown Source)
at net.md_5.ReflectUtil.setStatic(ReflectUtil.java:43)
at net.md_5.PandaWire.onEnable(PandaWire.java:14)
at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:292)
at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:316)
@RoboMWM
RoboMWM / gist:fa1d4d24319c494c16f68ee1791a9792
Created October 30, 2016 01:12
when I make a lib, this is the name I should use
[18:11:11] %dotStart: "Requires RetardRoboLib v42.5.6 (incompatible with RetardRoboLib v42.5.5.1337)"
[22:40:08] +Godzilla: Paper/master 3725f9d Aikar: Fix faulty logic in Auto Save check - Fixes #443
[22:47:56] RoboMWM: wat faulty logic
[22:48:44] @Aikar: it was auto saving any modified chunk every tick >_>
[08:28:12] FatherWh0: I'm going to ask for some linux advise because the ubuntu guys couldn't answer.. or couldn't understand. I misstyped an address on my ubuntu box and ended up deleting firefox thx to some malicious code. In windows my Norton wold have blocked that script but alas "you don't need antivirus with linux". Any advise on how to block malicious script?
[08:29:10] @Aikar: wait, simply visiting the webpage executed coded and wiped out firefox?
[08:29:22] @Aikar: that kind of osecurity vuln would be having people panic
[08:31:36] FatherWh0: Yes, simply visiting a webpage installed code that, each time I launched firefox, opened endless thunderbird windows until it ran out of resources and froze.
[08:34:18] FatherWh0_: got a lovely image of a surgical wound and some words I won't repeat. Then 10000 thunderbird windows.
package com.empireminecraft;
import net.md_5.bungee.ServerConnection;
import net.md_5.bungee.UserConnection;
import net.md_5.bungee.api.ProxyServer;
import net.md_5.bungee.api.ServerPing;
import net.md_5.bungee.api.connection.ProxiedPlayer;
import net.md_5.bungee.api.event.ProxyPingEvent;
import net.md_5.bungee.api.event.ServerConnectEvent;
import net.md_5.bungee.api.event.ServerConnectedEvent;
@RoboMWM
RoboMWM / gist:77bc682605f067c3bd83ecc1131506e7
Last active November 23, 2016 02:30
redrield drops the mic on qball and then he rages
[18:24:49] RoboMWM: Qball, Red != Redrield
[18:24:55] RoboMWM: you should really stop pinging Red
[18:25:47] Qball: RoboMWM, you should stop being so rude to me and eat this taco
[18:26:01] RoboMWM: after you stop pretending you know java
[18:26:50] Redrield: Qball: WildernessTp is a clusterhypixel of stolen code
[18:26:58] Redrield: And you wouldn't merge my PR because you don't know kotlin
[18:27:01] * Redrield drops the mic
[18:28:28] Qball: Redrield, Why would I merge code I cant maintain and none of it is hypixeling stolen code you ass holes why dont you go hypixel yourself with your precious emacs
[18:28:59] %Z750: Qball, RoboMWM, Redrield alrighty enough you three
[18:29:00] Redrield: I don't even think Robo uses emacs, also what does that have to do with anything
[22:07:03] RoboMWM: is EntityChangeBlockEvent supposed to fire whenever a block turns into a FallingBlock (or primedTNT entity)? Seems to only do so when a blockphysicsevent is called on the block (and it's supposed to fall) or if it's placed in creative mode.
[12:31:07] @RoboMWM: I've never understood the prison gamemode
[12:31:50] @Sweepyoface: yeah I have no idea what the goal is in prison
[12:32:02] @RoboMWM: people rank up
[12:32:06] @RoboMWM: that's the only goal I see
[12:32:13] @RoboMWM: an endless goal from a-z
[12:32:22] @RoboMWM: dem unintended rhymes
@RoboMWM
RoboMWM / gist:9d7cad5cff9da27dba0ffc57e956dcca
Created November 28, 2016 20:35
Qball imports some RAM
[12:29:54] Qball: does importing packages use memory
[12:31:46] NibbleNinja: everything uses memory
[12:31:48] NibbleNinja: remember that kids