Revive payments via Budget

This commit is contained in:
Greg Fitzgerald
2019-03-03 15:43:51 -07:00
parent e8ae603a01
commit 2ec9bc9f05
7 changed files with 53 additions and 14 deletions

View File

@ -25,6 +25,24 @@ pub enum SystemInstruction {
}
impl SystemInstruction {
pub fn new_program_account(
from_id: Pubkey,
to_id: Pubkey,
tokens: u64,
space: u64,
program_id: Pubkey,
) -> BuilderInstruction {
BuilderInstruction::new(
system_program::id(),
&SystemInstruction::CreateAccount {
tokens,
space,
program_id,
},
vec![(from_id, true), (to_id, false)],
)
}
pub fn new_move(from_id: Pubkey, to_id: Pubkey, tokens: u64) -> BuilderInstruction {
BuilderInstruction::new(
system_program::id(),