返回
项目实战

Implementing Locked Staking on Sui

This course will guide you through implementing locked staking contracts on Sui. You will learn how to create staking mechanisms that lock users’ assets for a specified period, ensuring secure and transparent staking operations. Using the Move language, we will introduce key concepts such as setting lock periods and handling withdrawals after the lock duration. Let’s get started!

语言move
难度简单
总时长2小时

目标学习者

这门课是给谁上的

  • Developers who are interested in blockchain and smart contracts.
  • Developers who are interested in Move programming.
  • Developers who are interested in Sui.

要求

  • No CS background required – the course explains the code line by line to help beginners quickly grasp the concepts.
  • Basic understanding of Sui and Move.

你会学到什么

  • The complete process of implementing a Locked Staking Protocol based on the Sui test network
Sui
Stake
Unstake

课程安排

  • Unit 1 - Course Introduction

    Locked Staking on Sui course introduction.


  • Unit 2 - Define Modules and Import Dependencies

    In this unit, we will introduce how to set up the environment configuration for our project and import the relevant dependencies.


  • Unit 3 - Define LockedStake Struct

    In this unit, we will introduce how to define the LockedStake struct.


  • Unit 4 - LockedStake Struct Core Functions

    In this unit, we will introduce the core operation functions of LockedStake, such as unlocking assets and depositing staking objects.


  • Unit 5 - Stake and Unstake Functions

    In this unit, we will introduce how to implement the staking and unstaking functions in locked staking.


  • Unit 6 - Information Retrieval Functions

    In this unit, we will introduce how to implement the information retrieval function in the locked staking contract.


  • Unit 7 - Interaction

    In this unit, we will learn how to build and deploy a program.

practice

Implementing Locked Staking on Sui

14 小节
移动端和桌面端均可访问