Use donate plugin for payments to players
Posted: 06 Jun 2020, 18:52
Hi,
I'm trying to write a small lottery plugin that pays a random amount of planets to a random player at the end of each map (very similar to lottery plugins for older ASECO's).
For the payment I want to use the plugin.donate.php, which should be able to make a payment from the server to a player (according to the description). But my attempt crashed UASECO (unfortunately I don't get any error messages).
I'm adding the dependence in the constructor: $this->addDependence('PluginDonate', Dependence::REQUIRED, '1.0.0', null);
And I'm trying to use the plugin like this: $aseco->plugins['PluginDonate']->admin_payment($aseco, $aseco->server->login, $targetLogin, $amountPlanets);
($targetLogin = login of the player who won the lottery)
I'm still new to PHP and I couldn't find any help on how to use the donate plugin to make a payment from the server. Thank you in advance.
Cheers,
Padawan
I'm trying to write a small lottery plugin that pays a random amount of planets to a random player at the end of each map (very similar to lottery plugins for older ASECO's).
For the payment I want to use the plugin.donate.php, which should be able to make a payment from the server to a player (according to the description). But my attempt crashed UASECO (unfortunately I don't get any error messages).
I'm adding the dependence in the constructor: $this->addDependence('PluginDonate', Dependence::REQUIRED, '1.0.0', null);
And I'm trying to use the plugin like this: $aseco->plugins['PluginDonate']->admin_payment($aseco, $aseco->server->login, $targetLogin, $amountPlanets);
($targetLogin = login of the player who won the lottery)
I'm still new to PHP and I couldn't find any help on how to use the donate plugin to make a payment from the server. Thank you in advance.
Cheers,
Padawan