How to use the AVRG probe: Difference between revisions
Jump to navigation
Jump to search
Whirled vox (talk | contribs) m (Text replacement - "<" to "<") |
Whirled vox (talk | contribs) m (Text replacement - ">" to ">") |
||
| Line 5: | Line 5: | ||
The simplest nothing-but-probe application would have a client something like: | The simplest nothing-but-probe application would have a client something like: | ||
<actionscript | <actionscript> | ||
package { | package { | ||
| Line 23: | Line 23: | ||
} | } | ||
</actionscript | </actionscript> | ||
and a server agent something like: | and a server agent something like: | ||
<actionscript | <actionscript> | ||
package { | package { | ||
| Line 47: | Line 47: | ||
} | } | ||
</actionscript | </actionscript> | ||
[[Category:Code tutorials]][[Category:Game tutorials]] | [[Category:Code tutorials]][[Category:Game tutorials]] | ||
Latest revision as of 11:26, 4 September 2018
We have provided an extra debugging tool for AVRGs. It is under the contrib code.
You can include it with any AVRG you write. It's basically a GUI that lets you call any function either directly on the client-side API or indirectly through the server-side agent.
The simplest nothing-but-probe application would have a client something like:
<actionscript> package {
import com.whirled.avrg.AVRGameControl;
import com.whirled.contrib.avrg.probe.ClientPanel;
public class Probe extends ClientPanel
{
public function Probe ()
{
super(new AVRGameControl(this));
x = y = 10;
}
}
}
</actionscript>
and a server agent something like:
<actionscript>
package {
import com.whirled.ServerObject;
import com.whirled.avrg.AVRServerGameControl;
import com.whirled.contrib.avrg.probe.ServerModule;
public class Server extends ServerObject
{
public function Server ()
{
_ctrl = new AVRServerGameControl(this);
_module = new ServerModule(_ctrl);
_module.activate();
}
protected var _ctrl :AVRServerGameControl;
protected var _module :ServerModule;
}
}
</actionscript>