File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed
src/main/java/com/cheatbreaker/nethandler/server Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change 1616@ NoArgsConstructor
1717public class CBPacketSwingInhibitorUpdate extends CBPacket {
1818
19+ private int type = 0 ;
20+
1921 private int frequencyMs ;
2022 private double decayRate ;
2123 private int cpsCap ;
2224
25+ public CBPacketSwingInhibitorUpdate (int frequencyMs , double decayRate , int cpsCap ) {
26+ this .type = 0 ;
27+ this .frequencyMs = frequencyMs ;
28+ this .decayRate = decayRate ;
29+ this .cpsCap = cpsCap ;
30+ }
31+
2332 @ Override
2433 public void write (ByteBufWrapper out ) throws IOException {
34+ out .buf ().writeInt (this .type );
2535 out .buf ().writeInt (this .frequencyMs );
2636 out .buf ().writeDouble (this .decayRate );
2737 out .buf ().writeInt (this .cpsCap );
2838 }
2939
3040 @ Override
3141 public void read (ByteBufWrapper in ) throws IOException {
42+ this .type = in .buf ().readInt ();
3243 this .frequencyMs = in .buf ().readInt ();
3344 this .decayRate = in .buf ().readDouble ();
3445 this .cpsCap = in .buf ().readInt ();
You can’t perform that action at this time.
0 commit comments