Basechain
  • About Basechain
  • Base BigBang Language
    • Introduction
    • 1. Getting started
      • 1.1 Installing BigBangNet
      • 1.2 BigBang basics
    • 2. Type
      • 2.1 Primitives
      • 2.2 Sequences
      • 2.3 Composites
    • 3. Keywords
    • 4. Storing data
      • 4.1 Constants
      • 4.2 Variables
      • 4.3 Maps
    • 5. Functions
      • 5.1 Public functions
      • 5.2 Private functions
      • 5.3 Read-only functions
  • 6. Control flow & error handling
    • 6.1 Asserts
    • 6.2 Try
    • 6.3 Unwrap flavours
    • 6.4 Response checking
  • 7. Using BigBangNet
    • 7.1 Creating a new project
    • 7.2 Writing your first contract
    • 7.3 Interacting with your contract
    • 7.4 Testing your contract
  • 8. Practice projects
    • 8.1 Time-locked wallet
    • 8.2 Smart claimant
    • 8.3 Multi-signature vault
  • 9. Traits
    • 9.1 Defining traits
    • 9.2 Implement traits
    • 9.3 Passing traits as arguments
  • 10. Building a marketplace
    • 10.1 Setup
    • 10.2 Listing & cancelling
    • 10.3 Fulfilling listings
    • 10.4 Uni tests
  • 11. Runtime cost analysis
  • Nodes & Miners
    • Run a Node with Docker
    • Run a Node with DigitalOcean
    • Run a Node with a Hosted Provider
    • Base Node Configuration
    • Mine testnet Base tokens
    • Verify Miner
    • Miner costs and fees
  • Website
  • X(Twitter)
  • Github
Powered by GitBook
On this page
  • block-height
  • burn-block-height
  • tx-sender
  • contract-caller
  1. Base BigBang Language

3. Keywords

Keywords are specific terms that have an assigned meaning. Some keywords were introduced in previous chapters, such as true, false, and none. It is important to pay attention to other keywords as well.

block-height

Refers to the current height of the Base blockchain, represented as an unsigned integer. This value can be read at any point in the code, assuming the chain tip is at height 5.

burn-block-height

This unsigned integer reflects the current block height of the underlying burn blockchain, which in this case is Bitcoin.

tx-sender

This field contains the principal that initiated the transaction. It can be utilized to verify the principal calling a public function.

contract-caller

The function is called by a principal, which can be either a standard principal or a contract principal. If the contract is directly called through a signed transaction, then the tx-sender and contract-caller will be the same. If the contract calls another contract, then the contract-caller will be the previous contract in the chain.

Previous2.3 CompositesNext4. Storing data

Last updated 1 year ago