File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -24,7 +24,7 @@ It allows you to create things like this:
2424
2525``` tsx
2626import { InSim } from ' node-insim' ;
27- import { InSimFlags , IS_BTC , IS_MST , PacketType } from ' node-insim/packets' ;
27+ import { InSimFlags , InSimPacketInstance , IS_MST , PacketType } from ' node-insim/packets' ;
2828import { StrictMode } from ' react' ;
2929import {
3030 Button ,
@@ -54,11 +54,11 @@ function App() {
5454 });
5555
5656 // Clickable buttons
57- const handlePlayerClick = (plid : number ) => (_ : IS_BTC , inSim : InSim ) => {
57+ const handlePlayerClick = (plid : number ) => (_ : InSimPacketInstance < PacketType . ISP_BTC > , inSim : InSim ) => {
5858 inSim .send (new IS_MST ({ Msg: ` /echo PLID ${plid } ` }));
5959 };
6060
61- const handleConnectionClick = (ucid : number ) => (_ : IS_BTC , inSim : InSim ) => {
61+ const handleConnectionClick = (ucid : number ) => (_ : InSimPacketInstance < PacketType . ISP_BTC > , inSim : InSim ) => {
6262 inSim .send (new IS_MST ({ Msg: ` /echo UCID ${ucid } ` }));
6363 };
6464
You can’t perform that action at this time.
0 commit comments