View Single Post
Re: Plugin interacting with AMX
Old
  (#4)
Pierre-Marie Baty
Roi de France
 
Pierre-Marie Baty's Avatar
 
Status: Offline
Posts: 5,049
Join Date: Nov 2003
Location: 46°43'60N 0°43'0W 0.187A
Default Re: Plugin interacting with AMX - 12-04-2004

I understand perfectly, however I'm not sure this is feasible. AMX's small script is compiled by AMX itself into bytecode, which is then interpreted. You can't add new opcodes and tell AMX that your external plugin is in charge of handling them, and AMX won't know how to compile your new instructions into bytecodes.

You can still decide to pass commands and instructions elseway. For example, your plugin could feature some simple "send" and "rcv" client commands, that would send and read bytes from a socket, and you could either call them from the server console by hand (great for testing) or through an AMX script by issuing a ClientCommand. It's ugly, but it can work.



RACC home - Bots-United: beer, babies & bots (especially the latter)
"Learn to think by yourself, else others will do it for you."
  
Reply With Quote