Download as pdf or txt
Download as pdf or txt
You are on page 1of 25

Received 6 October 2023, accepted 18 October 2023, date of publication 25 October 2023, date of current version 28 November 2023.

Digital Object Identifier 10.1109/ACCESS.2023.3327581

Supply Chain Management Serious Game Using


Blockchain Smart Contract
ASTRID NOVITA PUTRI 1 , (Member, IEEE), MOCHAMAD HARIADI 1,2 , (Member, IEEE),
AND REZA FUAD RACHMADI1,2 , (Member, IEEE)
1 Department of Electrical Engineering, Institut Teknologi Sepuluh Nopember (ITS), Surabaya 60111, Indonesia
2 Department of Computer Engineering, Institut Teknologi Sepuluh Nopember (ITS), Surabaya 60117, Indonesia
Corresponding author: Mochamad Hariadi (mochar@elect-eng.its.ac.id)

ABSTRACT Smart Contract and Blockchain are necessary for transactions in supply chain management.
A smart contract is an agreement in the form of a cryptographic code digitally signed by the actors.
This technology holds the data transaction transparently and securely. The actors may benefit without
intermediaries involved in the transaction. Supply chain management will be easily tracked by decentralized
data sharing. Supply chain management involves transactions in agricultural sectors such as farmers, village
cooperatives units, distributors, and consumers. The Cooperative is a party that buys goods from farmers and
sells them to consumers. A smart contract is a digital signature that can access the system in transactions.
The system records log activities that show the origin of transactions. All actors can see the transaction
of agricultural products stored in the blockchain ledger in the Blockchain. This paper discusses blockchain-
based Smart Contract scenario for supply chain management that is simulated and implemented in the Serious
Game. The Game is developed using Unity 3D Development Platform, programming language contract using
Solidity, Moralis as Web3 Development Platform and dApp as backend blockchain, Network Environment
Polygon Ethereum, and Database that is Redis Enterprise, MongoDB Compass, and Mumbai Testnet.

INDEX TERMS Serious game, supply chain management, scenario, blockchain, smart contract.

I. INTRODUCTION them to consumers. The location of the Cooperative is also


In an agricultural country, most of the population lives in rural should close to the agricultural area. This step may fix the
areas, and their livelihood is agriculture. Most Indonesian primary commodities at stable prices [1].
farmers make transactions through a very long distribution One of the digital technologies developed in the technology
process that may affect the selling prices highly for staple industry is Blockchain. Blockchain may store data privately
foodstuffs such as rice, corn, beef, and chicken meat. One and securely. Thus, manufacturers may obtain information
of the causes of the high food prices is that the supply quickly and safely and conduct transactions without third
chain flows too long. The farmers’ prices remained low but parties. Blockchain is a technology recognized by the Supply
still high for consumers. The distribution phase in Indone- Chain Manufacturing industry in the world. Blockchain has
sia recently is from producers/farmers to distributors, then also been applied in several studies in the supply chain.
to sub-distributors, from sub-distributors to agents, then to Blockchain is an advanced database mechanism that shares
wholesalers, from wholesalers to retailers, and last to con- information transparently in a blockchain network. The data
sumers. The intermediary traders profit significantly from in the Blockchain are saved and linked in a block network [2].
the current supply chain, which harms farmers. Supply chain Blockchain structure has two components: Block Header
management is expected to be overcome, in which farmers and Transaction List that includes Blockchain, Genesis
and consumers benefit. The transaction should be through Block, Hashing, Proof of Work (PoW) or Proof of Stake
Cooperatives that buy goods directly from farmers and sell (PoS), nodes, transactions, and Smart Contract [3].
The transactions in Supply Chain Management need
The associate editor coordinating the review of this manuscript and a technology that supports data transparency. Blockchain
approving it for publication was Mehdi Sookhak . technology secures decentralized data records (ledger).
2023 The Authors. This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 License.
VOLUME 11, 2023 For more information, see https://creativecommons.org/licenses/by-nc-nd/4.0/ 131089
A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

Blockchain can verify and validate every transaction. Each including partnership dependence, which affects product
actor involved goes through a contract agreement scenario availability, service quality, transaction data security, stock,
(Smart Contract) that makes it easy to track the origin of the and buyer preferences. A blockchain-based Dapp application
products [2], [3]. can remove intermediaries in the supply chain to achieve price
Smart Contract can be used in various industries, especially optimization, making Dapp transactions straightforward and
those that conduct a contract agreement between two parties secure for users [6].
involving an intermediary. The smart contract can be applied From several related studies [1], [2], [4], [5], [7], [8],
as a contract regulated in Law. In this case, an official res- [9], [10], [11], it can be inferred that research is needed to
ident identity is required. In Indonesia, a Resident Identity make solution. Developing a serious game-based simulation
Card can facilitate legal identity tracking. Smart contract in may support operational supply chain management in making
the Supply Chain might benefit producers and consumers if decisions. In recent years, there have been many technologi-
the transaction is under the Law. The transaction also uses cal developments in games. One of them is a simulation-based
electronic mediums such as computers, networks, and others serious game. With an overview of modeling simulations,
in the Blockchain. Village Cooperative Unit could monitor input, output, and content, this serious game may be used
activities on supply chain management [4]. as a learning media to explore the learning environment.
The Smart Contract on Supply Chain Management is not In this agricultural game, players are visualized as having
only applied to the agricultural industry but also can be their farmland. They can organize and manage it as if selling
applied to other industries. Many sectors can use smart con- goods [12]. The games can be used to plant land for agricul-
tract to run the business efficiently and transparently. In the tural resources such as corn, wheat, cotton, and straw. Then,
Logistics sector, smart contract is utilized to automate and these crops are sold via a delivery cart, which can also sell
track product shipments. It helps to ensure better visibil- these items on the social market, as well as a reward feature,
ity, real-time monitoring, and payment process automation a ledger on the Blockchain [13], [14]. This game could show
between logistics parties [4]. In the Finance sector, smart the transparency of tracing data transactions and has been
contract can be applied in the financial industry as automatic simulated for farmers who take hold of giant farms; however,
processes such as payment processing, settlement contract, only some agricultural games can make stable prices, meet
or other financial agreements. It can increase efficiency, consumer needs, and benefit farmers.
speed, and accuracy in financial transactions. In the Insurance This research aims to simulate a serious game based on
field, industrial insurance may use smart contract to automate Blockchain smart contract using supply chain management.
claims processing and settlement. Smart contract can validate The simulation demonstrates the advantage of cutting sup-
claims based on predefined parameters and arrange claim ply chain distribution channels. Digital signatures created
payments automatically without human intervention [5]. by involved actors might provide data transparency and
In Property and Real Estate, property and real estate transac- optimize prices applicable to market conditions. The agri-
tions may use Smart contract to facilitate the buying, selling, cultural sector in Indonesia uses the Unity 3D development
and contracting agreements. Smart contract might increase platform, a programming language contract using Solidity,
the trust between the parties involved [6]. In Global com- Moralis as the Web3 Development Platform and dApp as the
merce, International commerce can use smart contract to blockchain backend, Polygon Ethereum Network Environ-
facilitate purchasing, shipping, and payment processes. Smart ment, and Databases Redis Enterprise, MongoDB Compass,
contract makes cross-border transactions simple, efficient and and Mumbai Testnet.
secure [7]. Smart Contractrequire specific business needs and
procedures within the industry. Appropriate usage of smart
contract in the industry has the same potency as in agriculture.
Sales transactions between Village Cooperative Units
and consumers require data transparency and responsibil-
ity to ensure that transactions have value. We provide
blockchain-based smart contracts, namely smart bidding on
the Blockchain. Bargaining automatic transactions between
farmers and Village Cooperative Units can increase farmers’
profits based on the price of Cost of Goods Sold and Agricul-
tural Exchange Rates. Cost of Goods Sold is an indicator in FIGURE 1. The research part of the supply chain management blockchain
is based on serious games.
Indonesia that describes how farmers can obtain products or
services produced from the agricultural sector as an optimal
price achievement [5].
Many applications in several B2B (business-to-business) II. NOVELTY AND CONTRIBUTION OF THE PAPER
startup application platforms reach suppliers at low prices The novelty of this research is that a Blockchain smart
between intermediaries, farmers and consumers; they are contract and Supply chain can manage distributed ledger
AgroMall Ula. However, these applications have drawbacks, technology in a new model Blockchain. It aims to provide

131090 VOLUME 11, 2023


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

centralized data storage, maintain data privacy, and speed as collateral and randomly select valid actors to block. This
on chains involving multiple storage (Private Database). The process is how consensus on new transactions is reached in a
data is integrated into each other (ledger) through distribution blockchain network.
channels, which makes it easy for farmers to maximize their Nodes are computers or devices in a blockchain net-
agricultural products. New methods are used to optimize new work that participate in validating transactions and running
distribution channels simulated in the serious games: farmers, blockchain software. There are two main types of nodes: full
Village Unit Cooperative, distributors, and consumers. nodes, which store the entire history of the blockchain, and
This research contributes to analyzing and modeling light nodes, which only store part of the data.
Blockchain technology in the supply chain to support farmers Transactions are data added to blocks that record
deciding to cut distribution channels with a ‘‘Distributed the transfer of crypto assets or other information in a
Ledger’’. The study also demonstrates data transactions trans- blockchain network. The transactions in this research are
parently and optimizes prices using smart contract-based User Registration (UR), FarmerStock & FarmerShop (FSH),
blockchain smart bidding through a serious game. Serious FarmerKUDTransaction (FK), KUDStock (KS) & KUD
games can also be applied as learning media in agricultural Shop (KSH), KUDConsumerTransaction (KD), FarmerAuc-
production. Smart Bidding uses blockchain smart contract to tion (FA), FarmerKUDBidding Transaction (FBT) and Con-
optimize prices between farmers and Village Cooperatives in sumerStock (CS).
buying and selling products or services. So that automatic A smart contract is an independent program that runs on
bargaining transactions can increase farmers’ profits. the blockchain and can automate various functions and agree-
ments. Smart contract works automatically when the contract
III. RELATED WORK is fulfilled.
Blockchain is one of the innovations of current technological The basic structure of blockchain technology used in cryp-
developments. Blockchain might change the way we manage tocurrency networks is Bitcoin and Ethereum, as well as in
data and transactions. Blockchain is a digital ledger that is any other applications outside of cryptocurrencies, such as
decentralized in recording transactions in the form of blocks supply chains. Blockchain provides a secure and decentral-
connected so that a network of related actor nodes can verify ized basis to record data transactions.
each transaction [15]. A network of participating nodes veri- We present the research focused on Blockchain in smart
fies each transaction; once received, it is encrypted and added contract, which are formal digital agreements using ledger
to the Blockchain, resulting in a secure and immutable trans- technology. Smart contract using DLT protocols, Ethereum,
action chain that makes the information stored impossible to EOSIO, and Hyperledger Fabric is currently developing
manipulate. rapidly [16]. This research uses Ethereum smart contract.
The structure of Blockchain includes blocks that are the Supply chain management and Blockchain are transparent
basic unit of Blockchain. Each block contains data like sev- in every real-time tracking of every transaction in the supply
eral transactions. Each block has two main components: the chain [17]. Blockchain can assist in optimizing inventory
Block Header and Transaction List. Block Header contains management with real-time information to determine product
metadata, such as timestamp, a hash of the previous block demand and supply throughout the supply chain and can
(except the genesis block), and a nonce (a random number reduce the occurrence of the bullwhip effect. Blockchain also
used in the proof of work searching process commonly called has data reliability to prevent data deviation or falsification.
proof of work. Transaction List is the part of the block that Blockchain can facilitate secure automatic payments through
contains the included transactions in that block [3]. Smart Contractin the supply chain. Blockchain is encrypted
A Blockchain is a tiered sequence of blocks connected. with cryptography to guarantee transaction security [18].
Each block refers to the previous block via the previous block Blockchain and smart contract are technologies that enable
hash. Its header creates a chain relationship. Genesis Block improved supply chain management. This technology system
is the first block in the blockchain. The genesis block has no can be utilized in decision-making to coordinate contractual
preceded block to connect to and usually serves as the starting relationships between parties not meeting each other con-
point of the blockchain. nected in the blockchain ledger. The supply chain should
Hashing is the cryptographic process of data from a block, guarantee agricultural products before being delivered to con-
including transaction data and block headers converted into sumers; in this case, a smart contract is needed to evaluate
a fixed-length numerical string known as a hash. The hash food safety [3], [16].
from the previous block is put in the current block header. Transaction scenarios in smart contract occur between the
The hash of the entire block is used to verify data integrity agreements from actors recorded on the node chain, deployed
and inter-block relationships. on the Blockchain, and automatically verified by the sys-
The Proof of Work (PoW) Consensus Mechanism that tem [15], [17]. Smart contract import the data transparently,
blockchains use requires miners to solve complex mathe- traceably, and efficiently into the supply chain. The Ethereum
matical problems to add new blocks to the blockchain. The blockchain platform provides an interface for users to secure
Proof of Stake consensus mechanism that blockchains use their privacy using the blockchain programming language
requires coin holders to put up a certain amount of their coins contract ‘‘Solidity’’ [18].

VOLUME 11, 2023 131091


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

Farmer Chain, a smart supply chain management system,


automates digital agreements using Blockchain without inter-
mediaries to identify product authenticity, information, and
quantities [19]. The Ethereum-based Blockchain model is a
decentralized application network (DApp) that shows real-
time data transparently and securely since it runs on the
Blockchain network. The Blockchain system works without
human interference to reduce errors [20].
Farmers are still traditionally sending raw materials to con-
sumers, making the transactions a long process. The supply
chain Blockchain-based is used in the supply chain manage-
ment network to provide product information, distribution
prices, and price tracking in the security network since data FIGURE 2. System overview on supply chain management.
security, authenticity, and time are managed appropriately
[21], [22]. The supply chain can make orders and transactions TABLE 1. Related work on serious game, supply chain management,
easy and track and update delivery information from farmers smart contract and blockchain.
to consumers.
Serious game in supply chain management is also used as
a starting stage for planning agricultural products and provid-
ing information on product quantities and prices. Meanwhile,
the simulation games as decision-makers collaborate with the
company with large orders [19], [20]. Serious game is also
used to make strategic decisions in the supply chain from the
bullwhip effect [21].
The serious game supports supply chain resilience to make
decisions in transactions. When the transaction is not through
an intermediary, it might maximize profits for actors [26].
A serious game as a medium to secure transactions on supply
chain management. Serious games are a tool to increase
awareness of sustainable supply chain management games
based on observations [23].
Related research [3], [15], [24], [25], [26], [27], [28],
[29], [30], [31], [16], [17], [18], [19], [20], [21], [22], and
[23] discussing supply chain management, smart contracts,
Blockchain, smart bidding, and serious games are used to
facilitate tracking information in the blockchain ledger net-
work. The research integrated into this study is shown in
Table 1. Research on supply chain management connected to
Blockchain and Smart Contract is still challenging; Hence we
propose a game-based smart agriculture collaboration with a
new supply chain using Smart Contract and Blockchain that
connects farmers, cooperatives, and consumers without an
intermediary involved.

IV. SYSTEM OVERVIEW


Figure 2 shows that the participants involved in smart agri-
culture and supply chain management are farmers, Village
Unit Cooperative, distributors, and consumers. Every trans-
action must use a digital signature and be connected to a
decentralized blockchain network. Each connected node has The farmer is an attribute provider that manages corps
a linked Polygon Ethereum account in a smart contract. The production from planting, fruiting, harvest, farmer’s name,
transactions, including harvests, sales and purchases, and harvest location, stock quantity, harvest condition, expired
activity log browsing, are stored in Redis Enterprise, Mon- date, to prices.
goDB Compass, and Unity 3D Development Platform. The Village Unit Cooperative is the attribute provider that
actors involved in the blockchain network node are described purchases harvest from the farmer and receives activity logs
below: on each transaction. The products from the farmers are sold

131092 VOLUME 11, 2023


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

FIGURE 3. The proposed system and its relation to previous work.

to consumers. Village Unit Cooperative is a business entity himself. The developer determines the actor engaged in the
in rural areas that provides daily needs related to agricultural smart contract system. The contract is private and can only
activities. be accessed by the users who inherited it [33].
The distributor is the attribute provider that delivers Ethereum-based Network Environment. The blockchain
goods from Village Unit Cooperative to consumers. backend is Moralis as Web3, and the Database is Redis
The consumer is the individual or group of buyers who Enterprise. MongoDB Compass, Mumbai Testnet, search
purchase the products and receive activity logs from Village the Polygon blockchain for transactions, addresses, and
Unit Cooperative. tokens.
Figure 4 is the sequence of platform development used in
A. CERTIFICATE AUTHORITY (CA) FOR BLOCKCHAIN this paper. MetaMask is a browser plugin that functions as
SUPPLY CHAIN MANAGEMENT an Ethereum polygon-based crypto-wallet. While the Game
Certificate Authority (CA) is the application registered for Development Platform uses Unity 3D, programming lan-
the game of Blockchain-based on supply chain management guage contracts use Solidity and Polygon Ethereum-based
in which users receive authority and cryptographic informa- Network Environment. The blockchain backend is Moralis
tion to compose a blockchain network. CA contains a chain as Web3, and the Database is Redis Enterprise. MongoDB
code connected and deployed on the channel using a peer. Compass, Mumbai Testnet, search the Polygon blockchain
This chain code included instructions for the transaction of for transactions, addresses, and tokens.
agricultural products that support the appropriate prices. The
transaction is connected to the ratification policy peer and
blockchain code.
The game is developed using Unity 3D Development
Platform, programming language contract using Solidity, FIGURE 4. Smart contract development platform of supply chain
management on serious game.
Moralis as Web3 Development Platform and dApp as back-
end blockchain, Network Environment Polygon Ethereum,
and Database of Redis Enterprise, MongoDB Compass, and Figure 5 and Figure 6 Transactions on chain nodes are
Mumbai Testnet. The certificate authority verifies the cer- connected to blockchain peers. Farmer, Village Unit Cooper-
tificate holder’s identity before issuing the certificate. This ative, distributor, and consumer are identified as actors when
action helps to maintain security and authentication involving logging in to the platform. If registered on the platform, it will
cryptographic keys. The digital management of the solidity process digital signatures and be recognized and connected to
authority certificate is the game smart contract developer the blockchain network.

VOLUME 11, 2023 131093


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

Condition, and Price. The data displayed on FSH gave the


contract address from FarmerStockFS() to FarmerShopFSH()
for sale, as shown in Table 2.
FK is the sales transaction contract between the farmer and
the Village Unit Cooperative contains Transaction IDE, Stock
IDE, Farmer address, KUD address, Consumer address, Plant
name, Plant price, Quality, Expired date condition, Harvest
date, Transaction Hash, Amount in Matic, Rate Maticin IDR,
Session Token, and Class name. Each associated contract
transaction appears as a command for digital signature and
connects to the Blockchain’s permanent transaction store.
Table 3 shows the IDE information response to the address
of the farmer’s contract. Table 4 shows relevant information
on contract data from Table 5 with FarmerKUDTransac-
tionFK The transactions reach consensus saved on MongoDB
FIGURE 5. Transaction illustration of serious game-based smart contract Compass of sales transactions from farmer to Village Unit
on supply chain management.
Cooperative FK.
KS is Village Unit Cooperative keeps the purchased crops
from farmers and FK transactions. Village Unit Cooperative
stores goods at KSH, and they can re-sell to consumers using
the function of KUDStockKS().
KD is KSH makes products sold to consumers with
transactions based on relevant information traceability. The
FIGURE 6. Transaction verification of blockchain and game. transaction must pass digital signatures from FS and FH
on the Blockchain by displaying the Farmer Address, KUD
Address, Expired Date, and Txn Hash. Table 6 shows the
B. BLOCKCHAIN-BASED SMART CONTRACT transaction using the function KUDCustomerTransaction KD
TRANSACTION SCENARIO Table 7 shows the transaction after the product was sold
We explain ten Smart Contractto innovate supply chain man- from Unity 3D ConsumerStock CS Table 8 is the transaction
agement, namely User Registration (UR), Farmer Stock (FS), detail of CS for sale transaction KD connected to the address
Farmer Shop (FSH), Farmer KUD Transaction (FK), KUD distribution contract shown on ID, KUD Address,
Stock (KS), KUD Shop (KSH), Farmer Auction (FA), Farmer Farmer Address, Consumer Address, Condition, Expira-
KUD Bidding Transaction (FBT), KUD Consumer Transac- tion Date, Harvest Date, Quantity, and Plant Price.
tion (KD) & Consumer Stock (CS). The smart bidding-based serious game uses smart contract
UR contains contract registration and transaction processes games. There are two smart bidding mechanics in smart
on games. FS contains the identification of crop stocks carried contract blockchain:
out by farmers, FSH contains information on farmer’s stock a. FarmerAuctionFA() is Smart bidding on the farmer
that is to be sold to Village Unit Cooperative, FK contains side. FarmerAuction is a farmer’s auction database.
transactions between farmers and Village Unit Cooperatives, At FarmerAuction, many bidding from several joint
KS Contract contains information of sales stock at the Vil- wallet village unit cooperative accounts exist. Only
lage Unit Cooperative, KSH contains information of stock one transaction is agreed upon between the farmer and
in Village Unit Cooperatives that to be sold to consumers, the Cooperative Village Unit, even though the results
KD contains transactions between Village Units Cooperative, obtained offer bidding from many Cooperative Village
distributors and consumers, CS contains stock and consumer Units.
information. b. FarmerKUDBiddingTransactionFBT() is smart bid-
UR is the beginning stage of the game, which starts ding on the KUD side. FarmerKUDBidding Transac-
with scanning the linked wallet account on MetaMask, tionFBT() is a transaction made by a farmer who agrees
data UR ide, username, role, email, EthAddress, and to an auction offer for his crops and the highest price
auth_data_moralisEth. All data is saved permanently. Each from one of the Cooperative Village Units he chooses
actor is given the role function of the UserRegistrationUR() as the final selling price in smart bidding.
address, which can identify each role’s activity. Thus, it was Table 5. is the MongoDB Data Compass, which consists
easy to get information and track transactions conducted by of an interactive tool for querying, optimizing, and analyz-
actors. ing data on our MongoDB blockchain for sales transactions
FS is the farmer plants and harvests the crops and then between Farmer and Village Unit Cooperative. These trans-
saves the FS data by mentioning the Plants Name, Farmer’s actions are saved in MongoDB, Unity 3D, and the Redis
Address, Total Harvested, Harvest Date, Expired Date, Enterprise Database. Batch number of FK transaction, hash

131094 VOLUME 11, 2023


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

TABLE 2. Example information of sales transactions from FS & FSH.

TABLE 3. Smart contract from FS & FSH to FK.

TABLE 4. Smart contract of sale transaction from FK in Contract batch number TxnHash transaction sale in table 3.

transactions stores queries from Farmer Stock, Farmer Shop and Traceability of the data in the agricultural supply
transactions containing Transaction ID, Farmer Address, Vil- chain. We have explained in detail the implementation of
lage Unit Cooperative Address, Amount In Matic transaction, actors; they are farmer, Village Unit Cooperative, distributor,
RateMatic, IDR Transaction Hash, Class Name. Table 6 Vil- and consumer. The steps through which the actors invol-
lage Unit Cooperative stores stock from sales & Village Unit ved are:
Cooperative opens sales at KD through a contract at Village 1. Farmers who pass the contract make transactions that
Unit Cooperative. Consumer transactions are by displaying must go through the registration process via a QR Code
the Owner, Product Name, ETH From, and TxnHash. Table 7. connected to the function UserRegistrationUR() via a
shows the contract agreed upon between the consumer and the MetaMask wallet account. The farmer contract address
Village Unit Cooperative, and then the result of a blockchain is automatically connected with the FarmerStockFS()
game sales transaction stores the data that appears in Unity and FarmerShopFSH The accounts are used for Farmer
3D. Table 8 contains detailed consumer transactions and Stock, Farmer Shop, and Farmer KUD.
stock verified and recorded in a ledger on the blockchain Sales purchase transactions in FarmerKUDTransac-
game of the sales transactions from Village Unit Cooperative tionFK() between farmers and the Village Unit Cooper-
and consumer. Tables 9 and 10 Transaction details of the ative. Transaction of the ContractAddress() function in
Smart Bidding-based Serious Game of FarmerAuctionFA() the contract address added to the consensus in the net-
and FarmerKUDBidding TransactionFBT() transaction is work nodes of the information of the game blockchain
agreed upon between the farmer and the Cooperative Village system batch and deploy Blockchain according to
Unit. the address. Two smart bidding mechanics in smart
contract blockchain exist FarmerAuctionFA() and
FarmerKUDBidding TransactionFBT The transaction
C. SMART CONTRACT TRANSACTION ARCHITECTURE OF is agreed upon between the farmer and the cooperative
SUPPLY CHAIN MANAGEMENT GAME-BASED village unit with smart bidding
As shown in Figure 7, the sequence of all transactions 2. Village Unit Cooperative passing the contract has a
from the supply chain management-based blockchain smart similar process to Farmers. Village Unit Coopera-
contract game includes Contract Data and Contract Trans- tive, who make transactions, must register via a QR
actions from Product Registration, Sales, and purchase. Code connected to the function UserRegistrationUR()
Contract Transactions, Transfer Information, Distribution, via a MetaMask wallet account. The Village Unit

VOLUME 11, 2023 131095


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

TABLE 5. MongoDB compass for sale transaction from FK in contract batch number transaction hash in table 3.

TABLE 6. KS & KSH list from contract to KD.

TABLE 7. CS from Unity3D to contract village unit cooperative to consumer.

TABLE 8. Transaction detail of CS for sale transaction KD.

TABLE 9. Transaction detail of the smart bidding-based serious Game of FarmerAuctionFA().

Cooperatives carry out the registration process as to consumers through the function KUDStockKS()
(UVC/KUD) through User Registration and sell goods and KUDShopKSH() and contract KSH from KD
purchased from farmers (FK), then is stored and re-sell on the blockchain network from KD Transaction.

131096 VOLUME 11, 2023


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

TABLE 10. Transaction detail of the smart bidding-based serious Game of FarmerKUDBidding TransactionFBT().

FIGURE 7. The use case of blockchain-based smart contract transaction on supply chain management games (a) smart contract farming mode
(b) smart contract village unit cooperative mode (c) smart contract distribution mode (d) smart contract consumer mode.

KUDConsumerTransactionKD() sale and purchase connected to the function UserRegistrationUR() via a


transactions of crops with consumers. MetaMask wallet account.
3. Distributors passing the contract are the distributor who 4. Consumers passing contract are the consumers who
has the transaction process at the Village Unit Coop- registered via UserRegistrationUR() to be able to
erative through the function KUDConsumerTransac- make purchases and get information for harvest from
tionKD Consumers received requests from the function the Village Unit Cooperative connected to the func-
KUDConsumerTransactionKD() and changed delivery tion KUDConsumerTransactionKD() and Consumer-
status at the function KUDConsumerTransactionKD() StockCS() that stores information on consumers and
and ConsumerStockCS FarmerKUDBidding Trans- be able to track transactions on previous harvest on
action(FBT)() verifies delivery from farmer auction the network system blockchain games. Blockchain can
transactions and Village Units Cooperative. Distribu- track the information obtained from each transaction
tors who make transactions must register via a QR Code bound through a digital signature contract in which

VOLUME 11, 2023 131097


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

FIGURE 8. Component diagrams of UML blockchain smart contract with farming, village unit cooperative, distribution, and consumer.

FIGURE 9. The UML deployment diagram for supply chain management Game-Based

each transaction is added to the consensus on the net- Deployment diagram is a model diagram in UML that
work node of the blockchain games system. describes the relationships spread in the system. The diagram
The design uses UML Diagrams for the blockchain game involves software and actors depicting the application con-
smart contract integration system, namely the verification figuration done at run time. The application loads blockchain
model and integration flow for UML activity diagrams and nodes from Unity 3D Development Platform connected to
UML component diagrams. The class diagram is shown in Moralis, and MetaMask will be connected via actors, Net-
Figure 7 work environment using polygon Ethereum and database
Figure 8. The case of transactions integration between User using MongoDB Compass and Redis Enterprise as seen in
Registration (UR), Farmer Stock (FS), Farmer Shop (FSH), Figure 10.
Farmer KUD Transaction (FK), KUD Stock (KS), KUD Shop The class diagram has a class structure: User Registration,
(KSH), FarmerAuction (FA), FarmerKUDBidding Transac- FarmerStock, FarmerShop, FarmerKUDTransaction, KUD-
tion (FBT), KUD Customer Transaction (KD) and Consumer Stock, KUD Shop, KUDConsumerTransaction, FarmerAuc-
Stock (CS) present the actors including farmers, Village Unit tion, FarmerKUDBidding Transaction and ConsumerStock.
Cooperative, distributors, and consumers in this supply chain Each attribute describes in detail the content of the class.
management serious game. Component diagrams describe Meanwhile, methods are operations displayed in the list that
the interface flow required in communication between actors describe the interaction in a class [34]. UML model design
during transactions. uses stereotypes to identify an element’s purpose in a new

131098 VOLUME 11, 2023


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

FIGURE 10. Class diagram UML on game blockchain smart contract.

model [35]. The serious game-based blockchain smart con- Stereotypes provide additional information about the
tract is described in Table 11. classes in the UML model. Stereotypes are the notation used
in UML to add attributes or properties to elements in the
TABLE 11. Component diagrams on game blockchain smart contract with model [38]. In the context of a class diagram, stereotypes
stereotypes.
are used to provide specific information about the roles or
characteristics of the class represented in the system. As seen
in Table 13.
Class diagrams using stereotypes to provide additional
information about classes in the UML model. Table 14.
The class diagram design uses UML stereotypes based on
Smart Contract involving the actors: farmers, Village Unit
Cooperatives, distributors, and consumers. The transactions
in the smart contract model involve FarmerKUDBidding
transaction, FarmerKUDTransaction(FK) and KUD Cus-
tomerTransaction(KD) identifying contracts or agreements
agreed by actors in Blockchain network. Verification rules
on transactions are also must be met by actors. While the
real status saved in the blockchain network demonstrates
the sequence of actions on the nodes to reach a consensus
The UML implementation diagram uses stereotypes to pro- on the transactions. This smart contract design has flexi-
vide additional information about the elements model, nodes, ble verification settings. The verify() method is applied to
artefacts, or other elements involved in the implementation each transaction contract as a valid function in the rule
system [36], [37] as seen in Table 12. list. User Registration is used by scanning the wallet and

VOLUME 11, 2023 131099


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

TABLE 12. The UML deployment diagram on game blockchain smart TABLE 13. UML class diagram with stereotypes.
contract with stereotypes.

games in the supply chain are used to explore and simulate


filling in the ID card number and role on FarmerKUDBid- integrated games in decision-making to improve supply chain
ding for smart contract agreements between Farmers and performance. Cooperation in a supply chain management-
Village Unit Cooperatives to carry out the auction process. based serious game is also needed as a decision-making and
FarmerKUDTransaction (FK) is a smart contract agreement market strategy [33]. The actors involved must be registered
between Farmers and Village Unit Cooperatives for buying in the game application by showing a digital wallet account
and selling agricultural products. KUD Customer Transaction as a personal identity verified by the user and the Village Unit
(KD) is a smart contract agreement for selling and purchasing Cooperative as the system manager.
agricultural products between the Village Unit Cooperative, This study uses HFSM to design the sequence of game
distributors, and consumers. These can be seen in Figure 11. scenarios using smart contract in supply chain management
transactions. One of the advantages of using FSM is that it
D. HIERARCHICAL FINITE STATE MACHINE (HFSM) FOR can describe the serious game flow. Researchers use the smart
SCENARIO SMART CONTRACT BLOCKCHAIN-BASED contract method to hold the scenario flow based on the actors
WITH SUPPLY CHAIN MANAGEMENT involved.
Hierarchical Finite State Machine (HSFM) in supply chain HFSM in Figure 12. shows four scenarios, namely
management is a scenario design for a digital agreement con- Scenario 1 Farmer (S1), Scenario 2 Village Unit Cooperative
trol system using three working principles: State, Event, and (S2), Scenario 3 Distributor (S3), and Scenario 4 Consumer
Action [39]. Actions in response to input of the transaction (S4). Each sub-scenario describes the rules of supply chain
accompany changed status. The HFSM model is very suitable transactions and the rules of playing the games generally.
as a real-time design in controlling software. This game can Started from playing the game with the Wallet Login Tran-
be used to design scenarios due to deviations in the informa- sition on the digital wallet account and processing access to
tion obtained, which needs to be more transparent between each account via Scan My QR Code to the wallet; if regis-
the actors involved [40]. Thus, we need a Blockchain-based tered, it would automatically enter each scenario account. If it
smart contract on supply chain management that simulates is not registered, enter an email address and choose Farmer,
serious game as Automatic Scenario Control [33]. Serious Village Unit Cooperative, Distributor, or Consumer mode.

131100 VOLUME 11, 2023


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

TABLE 14. Class diagram UML on Game blockchain smart contract with
stereotypes.

FIGURE 11. UML class diagram for Game Blockchain design.

determining the selling price, smart bidding agreed upon


between the farmer and the cooperative village unit, even
though the results obtained offer bidding from many coopera-
At the same time, the digital signature will connect to the tive village units signing a digital signature on smart contract.
game scenario based on the scenario mode saved on the UR. Gas fee transaction data will be saved to KD.
As in Figure 13. Three states are sub-scenarios of Farmer, Figure 13c Design FSM distributor mode performs the
Village Unit Cooperative, Distributor, or Consumer mode. process of sending goods; a list of required goods will appear
Four scenarios have designs of story ideas from supply chain from the results of KD transactions. Whether the goods are
management games involving several actors in sales and sent to consumers or stored in the warehouse, it is connected
purchase transactions. to a smart contract. Meanwhile, in Figure 13d, the consumer
Figure 13a shows the FSM’s design through how farmers scenario mode has two choices. First, consumers purchase the
seek the agricultural field, choose what crops to be planted, crops from the Village Unit Cooperative by signing a digital
farm the fields, wait for the harvest, and harvest the crops. signature, then keep the stock. Second, the consumers see the
There are two choices to manage the corps: stored in the activity log like planting, fertilization, corps quality, farmer’s
farmer’s warehouse or sold to the Village Cooperative Unit name, plant expired date, harvest location, amount of stock,
by inputting the prices, smart bidding between the farmer and price saved on CS transactions.
and Village Unit Cooperative, Distributor selecting a digital
signature, then FK saved on the Blockchain. Figure 13b V. SMART BIDDING METHOD FOR FARMER’S PRICE
Village Unit Cooperative mode scenario will check the pur- OFFER IN SERIOUS GAME
chasing farmer’s harvest, which will be sold to the consumer, The process implementation serious game based on sup-
checking the quality stock from the farmer whether the corps ply chain management requires control in optimizing prices
will be stored in the warehouse or sold to the consumer, based on the product number, lead time, raw material costs,

VOLUME 11, 2023 131101


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

FIGURE 12. The hierarchical scenario-based smart contract on serious game using blockchain.

and purchasing and ordering costs in a certain period. In this 1. Data Analysis: Simulation of Serious Game Supply
study, control product quality can be seen from the expired Chain Management on the auction system applies the
date variable or the age of the commodity. When the stock variables of demand from farmers and offers from the
has expired, it will automatically expire in the store. When Village Unit Cooperative, current market price, product
the products expire in the consumer, they will expire at the quality audited by users in the application, and other
consumer. Smart Contract automatically process data verifi- factors that affect the price. The base price is deter-
cation, data validation, and payment calculations. In the smart mined by the farmer in the system. The price is set at
contract between the farmer and the Village Unit Cooperative, auction based on a specific time. The maximum price
there is a payment based on the quantity of product delivered. obtained by the farmer in the Smart bidding system for
When agricultural products are sent to the Cooperative, it can further bids.
provide data on the amount of product received. The smart 2. Optimum Pricing: The Game’s smart bidding and
contract will automatically calculate the amount of payment Smart Contractblockchain provides optimal price rec-
to farmers based on the price agreed beforehand. After the ommendations for agricultural products based on ana-
calculation, the smart contract can trigger an automatic trans- lyzing current market prices and cost of goods sold.
fer from the Village Unit Cooperative account to farmer For instance, a request from non-player characters, the
accounts and shipment tracking. Thus, it may reduce human Village Unit Cooperative can see product details on the
involvement and minimize the risk of human error in the system. The players are farmers based on farmer stock
supply chain. in this game simulation.
The smart bidding-based serious game automatically uses 3. Optimization of Farm Profits and Prices: Games smart
smart contract games in the bidding transactions process bidding on Smart Contractblockchain allows farmers
between farmers and Village Unit Cooperatives. to set price bids efficiently and optimally without
In Indonesian financial accounting, the cost of goods sold third-party. Farmers can analyze market prices, iden-
is obtained from the total expenses incurred by a business in a tify optimal prices, and increase their profits on sales
certain period. The cost of goods sold includes raw material of agricultural products. The increase in profits can
costs, direct labor costs, overhead costs, shipping costs for contribute to the Cost of Goods Sold, as farmers have
purchased goods, discounts, and product returns. The inven- enough income from their farming business.
tories and net purchases affect the cost of goods sold. The 4. Adjustment of demand and bidding: Adjustment of
cost of goods sold is to determine how much the charges are order and bidding: Smart bidding allows real-time price
incurred from processing raw materials until finished goods adjustments based on market conditions. If demand
and services are sold. increases or supply decreases, smart bidding can
An auction system on every Village Unit Cooperative adjust prices automatically. Farmers can maintain
might automate the bidding process and increase farmers’ competitiveness and obtain better exchange rates for
profits based on the Cost of Goods Sold and Agricultural their agricultural products since prices are determined
Exchange Rate. The Cost of Goods Sold is an indicator that according to market conditions. Smart bidding on a
describes how farmers can obtain products or services with game allows for real-time price adjustments according
results produced from the agricultural sector [11]. to changing virtual market conditions. If demand sud-
The following are ways of Smart Bidding implemented in denly increases or supply decreases, Smart Contractcan
the serious games: change prices immediately.

131102 VOLUME 11, 2023


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

FIGURE 13. Scenario actors (a) farmer mode, (b) village unit cooperative, (c) distributor or (d) consumer mode on scenario-based serious game using
blockchain.

VOLUME 11, 2023 131103


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

Algorithm 1 UserRegistrationUR
Input: Contract registration and game transaction processing. Farmer Stock (FS) contains the identification of crop stocks
carried out by farmersBlockchain and Smart Contract Interactions with the Moralis Unity SDK.
1. Public const string ContractAddress = ‘‘0 × 1.40242d88082800A5230a5DA2223074CE5d5f36’’;
public const string functionName = ‘‘greeting’’;
2. public static async void SendRawETH(MoralisUser _from, string _toAddress, float _value, Action _callback)
MoralisUser user = await Moralis.GetUserAsync();
float transferAmount = _value / GlobalConst.MATIC_TO_IDR;
string fromAddress = _from.authData[‘‘moralisEth’’][‘‘id’’].ToString();
string to Address = _toAddress;
TransactionInput txnRequest = new TransactionInput() { Data = String.Empty, From = fromAddress, To =
toAddress, Value = new HexBigInteger(UnitConversion.Convert.ToWei(transfer amount))
3. try
Moralis.Web3Client.Eth.TransactionManager.SendTransactionAsync(txnRequest);
4. bool txnComplete = Moralis.Web3Client.Eth.TransactionManager.SendTransactionAsync(txnRequest).
IsCompletedSuccessfully;
5. if(txnComplete)
_callback(); TxnHash: {txnHash}’’);

5. Transactions Efficiency: In-game smart bidding auto- In Algorithm 1: UserRegistrationUR() shows the interac-
mates the bidding process and saves the time and effort tion of the actor registration on the smart contract via My QR
required in negotiating prices with buyers. Farmers Code connected to MetaMask, thus saving the actor address
can focus on their farm production and management via the Moralis account. Actors involved in this blockchain
with this efficiency. It can increase the productivity and game should register through a smart contract or a MetaMask
quality of agricultural products, positively impacting wallet account by keeping the number contract address, name,
the Agricultural Exchange Rate. email, and user role, whether as a farmer, Village Unit
6. Player Decisions Effects: In-game smart bidding con- Cooperative, distributor, or consumer.
siders the decisions made by game players or char- The Algorithm 1 source code is accessible on request in
acters. For instance, if a player chooses to overgrow the GitHub repository https://github.com/AstridNovitaPutri
certain crops, smart bidding may adjust prices to reflect /alghorithmblockchain/blob/main/UserRegistrationUR.cs
the oversupply. Furthermore, Moralis will reconfirm the registration via
7. Performance Evaluation: In-game smart bidding can the user’s MetaMask wallet account. Then, it will be trans-
also evaluate performance impacted on the player’s ferred and stored in Moralis, Redis Enterprise, and Mon-
or character’s advantage. Players can see how their goDB. If the transaction is successfully sent, the game can
bidding decisions affect the financial results in the enter.
simulation and improve their strategy according to the Algorithm 2: FarmerStockFS() & FarmerShopFSH() save
results of this evaluation. transactions made by farmers starting to plant, harvest,
and crop stocks and show the harvest that will be sold
Smart bidding using blockchain smart contract in agricultural to the Village Unit Cooperative. The Algorithm 2 source
price bidding may increase profits without involving interme- code is accessible on request in the GitHub repository
diaries, optimize the prices according to market conditions, https://github.com/AstridNovitaPutri/alghorithmblockchain
increase efficiency, and provide better access to market infor- /blob/main/FarmerStockController.cs
mation in agricultural simulation games. Players may have Algorithm 3: on Smart contract, FarmerKUDTransac-
realistic and challenging experience in managing the trading tionFK() shows the sale and purchase transaction between
and economic aspects of virtual farming. Smart bidding can the farmer and the Village Unit Cooperative connected to
also add a strategic dimension to games and allow players to the Smart Contract Call. The farmers and Village Unit
hone decision-making skills. Cooperative stock will be up to date. The Village Unit
Cooperative buys stock from farmers through FK transac-
VI. SYSTEM IMPLEMENTATION tions and then sells it to the consumers. The Algorithm 3
We propose system implementation in implementing the source code is accessible on request in the GitHub repository
smart contract game in supply chain management. We apply https://github.com/AstridNovitaPutri/alghorithmblockchain
solidity language, unity 3D, and Moralis Blockchain as a /blob/main/FarmerShopController.cs
backend blockchain game. Blockchain can quickly provide Algorithm 4: KUDStockKS() & KUDShopKSH() save
decentralization development. the transactions made by the Village Unit Cooperative

131104 VOLUME 11, 2023


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

Algorithm 2 FarmerStockFS() & FarmerShopFSH() Algorithm 3 FarmerKUDTransactionFK()


Input: The data displayed on FSH that gives the contract address Input:The sales transaction contract between the farmer and
and information from the function FarmerStockFS() for sale to the the Village Unit Cooperative from the function FarmerKUD-
function FarmerShopFSH()
TransactionFK()
1. Public static async UniTask <Dictionary <FarmerStock,
PlantObject ≫ GetStocks(string _userAddress) { 1. Public static async void KUDBuyItem(FarmerShop
2. MoralisQuery <FarmerStock > farmer = await _shopItem, int _amount){
Moralis.Query <FarmerStock >(); 2. var transaction = Moralis.Client.Create
3. farmer = farmer.WhereEqualTo(‘‘farmerAddress’’, <KUDStock >();
_userAddress);
3. var user = await Moralis.GetUserAsync();
4. IEnumerable <FarmerStock > result = await
farmer.FindAsync(); 4. MoralisQuery <FarmerShop > itemQ = await
5. var list = new Dictionary <FarmerStock, PlantObject Moralis.Query <FarmerShop >();
>(); 5. itemQ = itemQ.WhereEqualTo(‘‘stockId’’,
6. foreach (FarmerStock stock in result) { _shopItem.stockId);
7. var plant = ScriptableUtils.GetPlant(stock.plantName);
6. FarmerShop item = await
8. list.Add(stock, plant); }
9. return list; } itemQ.FirstOrDefaultAsync();
10. Public static async UniTask <Dictionary <FarmerStock, 7. item.quantity -= _amount;
PlantObject ≫ GetMyStocks() { 8. transaction.stockId = _shopItem.stockId;
11. UserModel user = await UserController.GetMyUser(); 9. transaction.boughtTime = DateTime.
12. return await GetStocks(user.ethAddress); }
Now.ToUniversalTime();
13. Public static async void AddFarmerStock(FarmerStock
_stock, int _amount) { 10. transaction.condition = _shopItem.condition;
14. MoralisQuery <FarmerStock > stockQ = await 11. transaction.expirationDate =
Moralis.Query <FarmerStock >(); _shopItem.expirationDate;
15. IEnumerable <FarmerStock > result = await 12. transaction.farmerAddress =
stockQ.FindAsync();
_shopItem.farmerAddress;
16. FarmerStock selectedStock = null;
17. foreach (FarmerStock stock in result) { 13. transaction.harvestedDate =
18. if (stock.farmerAddress == _stock.farmerAddress && _shopItem.harvestedDate;
stock.plantName == _stock.plantName) { selectedStock = 14. transaction.quantity = _amount;
stock; }} 15. transaction.plantPrice = _shopItem.price;
19. if (selectedStock != null &&
16. transaction.kudAddress = user.ethAddress;
selectedStock.harvestedDate == Date-
Time.Now.ToUniversalTimeDate) 17. transaction.plantName = _shopItem.plantName;
20. { selectedStock.totalHarvested + = _amount; 18. await transaction.SaveAsync();
21. Debug.Log(‘‘Total of’’ + selectedStock.plantName + 19. if(item.quantity > 0){
‘‘is’’ + selectedStock.totalHarvested); 20. var successz = await item.SaveAsync();
22. if (selectedStock.totalHarvested > 0)
21. if(successz){
23. { var successz = await selectedStock.SaveAsync();
24. if (successz){ 22. Debug.Log(‘‘FarmerShop has been decreased,
25. Debug.Log(‘‘FarmerStock updated to DB’’); } updated to DB’’);
26. else { 23. }else{
27. Debug.Log(‘‘Failed to update to FarmerStock DB’’); 24. Debug.Log(‘‘Failed to update to FarmerShop DB’’);
28. }}
25. }
29. else {
30. await selectedStock.DeleteAsync(); 26. }else{
31. Debug.Log(‘‘Stock reached 0, deleted from Database’’); 27. await item.DeleteAsync();
32. } return; } 28. Debug.Log(‘‘Shop item reached 0, deleted from
33. var newStock = Moralis.Client.Create <FarmerStock >(); Database’’);
34. var user = await Moralis.GetUserAsync();
}}
35. newStock = _stock;
36. newStock.totalHarvested + = _amount;
37. Debug.Log(‘‘New Stock’’ + newStock.condition + new-
Stock.harvestedDate + newStock.expirationDate + new-
Stock.plantName + newStock.farmerAddress); from farmers’ crops and show KUDShopKSH connected
38. var success = await newStock.SaveAsync(); to User Moralis as an actor. The Algorithm 4 source
39. if (success) code is accessible on request in the GitHub repository
40. { Debug.Log(‘‘FarmerStock created to DB’’);
https://github.com/AstridNovitaPutri/alghorithmblockchain
41. } else
42. {Debug.Log(‘‘Failed to create to FarmerStock DB’’); } /blob/main/KUDShopController.cs
} Algorithm 5: KUDConsumerTransactionKD() & Con-
sumerStockCS() KSH makes products that will be sold

VOLUME 11, 2023 131105


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

Algorithm 4 KUDStockKS() & KUDShopKSH()


Input: Village Unit Cooperative keeps the purchased crops from Algorithm 5 KUDConsumerTransactionKD() &
Farmers and FK transactions. Village Unit Cooperative sells and ConsumerStockCS()
displays goods to be sold at KSH so they can be re-sold to consumers Input: KSH makes products that will be sold to consumers
using the function of KUDStockKS
with transactions that will attach relevant information
1. Public class KUDStockController{
2. public static async UniTask <Dictionary <KUDStock, regarding the traceability of information that must pass
PlantObject ≫ GetStocks(string _userAddress){ digital signatures on the Blockchain from FS and FH
3. MoralisQuery <KUDStock > farmer = await 1. Public class KUDShopController{
Moralis.Query <KUDStock >(); 2. public static async UniTask <Dictionary <KUDShop,
4. farmer = farmer.WhereEqualTo(‘‘kudAddress’’, _userAd- PlantObject ≫ GetStocks(string _userAddress){
dress); 3. MoralisQuery<KUDShop> farmer = await Moralis.
5. IEnumerable <KUDStock > result = await Query<KUDShop>();
farmer.FindAsync();
6. var list = new Dictionary <KUDStock, PlantObject >();
4. farmer = farmer.WhereEqualTo(‘‘kudAddress’’, _user-
7. foreach (KUDStock stock in result){ Address);
8. var plant = ScriptableUtils.GetPlant(stock.plantName); 5. IEnumerable<KUDShop> result = await farmer.
9. list.Add(stock, plant);} FindAsync();
10. return list;} 6. var list = new Dictionary<KUDShop, PlantObject>();
11. public static async UniTask <Dictionary <KUDStock, 7. foreach (KUDShop stock in result){
PlantObject ≫ GetMyStocks(){ 8. var plant = ScriptableUtils.GetPlant(stock.
12. UserModel user = await UserController.GetMyUser();
13. return await GetStocks(user.ethAddress);} plantName);
14. Public static async void SellStock(KUDStock _stock, int 9. list.Add(stock, plant);}
_amount, int _price){ 10. return list;}
15. var stockTobeSold = Moralis.Client.Create <KUDShop 11. public static async UniTask<Dictionary<KUDShop,
>(); PlantObject≫ GetMyStocks(){
16. MoralisQuery <KUDStock > stockQ = await 12. UserModel user = await UserController.GetMyUser();
Moralis.Query <KUDStock >(); 13. return await GetStocks(user.ethAddress);}
17. IEnumerable <KUDStock > result = await
stockQ.FindAsync();
14. Public static async UniTask<Dictionary<KUDShop,
18. KUDStock selectedStock = null; PlantObject≫ GetShopItems(bool isKUD){
19. foreach (KUDStock stock in result){ 15. var moralisUser = await Moralis.GetUserAsync();
20. if(stock.kudAddress == _stock.kudAddress && 16. MoralisQuery<KUDShop> query = await Moralis.
stock.plantName == _stock.plantName){ Query<KUDShop>();
21. selectedStock = stock;}} 17. if(isKUD)
22. if(selectedStock != null && selectedStock.harvestedDate 18. query = query.WhereEqualTo(‘‘kudAddress’’, moral-
== _stock.harvestedDate){
23. selectedStock.quantity -= _amount; isUser.ethAddress);
24. stockTobeSold.stockId = _stock.stockId; 19. var result = await query.FindAsync();
25. stockTobeSold.farmerAddress = _stock.farmerAddress; 20. var list = new Dictionary<KUDShop, PlantObject>();
26. stockTobeSold.kudAddress = _stock.kudAddress; 21. foreach (KUDShop item in result){
27. stockTobeSold.plantName = _stock.plantName; 22. var plant = ScriptableUtils.GetPlant(item.plantName);
28. stockTobeSold.quantity = _amount; 23. list.Add(item, plant);}
29. stockTobeSold.harvestedDate = _stock.harvestedDate; 24. return list;}
30. stockTobeSold.expirationDate = _stock.expirationDate; 25. public static async void CustomerBuy(KUDShop
31. stockTobeSold.condition = _stock.condition;
32. stockTobeSold.plantPrice = _price; _shopItem, int _amount){
33. await stockTobeSold.SaveAsync(); 26. var customerNewStock = Moralis.Client.
34. if(selectedStock.quantity > 0){ Create<CustomerStock>();
35. var successz = await selectedStock.SaveAsync(); 27. var user = await Moralis.GetUserAsync();
36. if(successz){ Debug.Log(‘‘FarmerStock has been 28. MoralisQuery<KUDShop> query = await Moralis.
decreased, updated to DB’’);} Query<KUDShop>();
37. else{ Debug.Log(‘‘Failed to update to FarmerStock DB’’);
}}
29. query = query.WhereEqualTo(‘‘stockId’’, _shopItem.
38. else{ stockId);
39. await selectedStock.DeleteAsync(); 30. KUDShop itemKUD = await query.FirstOr
40. Debug.Log(‘‘Stock reached 0, deleted from DefaultAsync();
Database’’);}}}} 31. itemKUD.quantity -= _amount;
32. customerNewStock.stockId = _shopItem.stockId;
33. customerNewStock.boughtTime = DateTime.Now.
to consumers and provides relevant traceability informa- ToUniversalTime();
tion that passes digital signatures on the Blockchain from 34. customerNewStock.condition = _shopItem.condition;
FS and FH. Consumer Stok keeps sales from the Village 35. customerNewStock.expirationDate = _shopItem.
Unit Cooperative. The connected smart contract saves expirationDate;

131106 VOLUME 11, 2023


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

36. customerNewStock.farmerAddress = _shopItem. https://github.com/AstridNovitaPutri/alghorithmblockchain/


farmerAddress; blob/main/KUDStockController.cs
37. customerNewStock.customerAddress= _shopItem. https://github.com/AstridNovitaPutri/alghorithmblock
customerAddress; chain/blob/main/CustomerStockController.cs
38. customerNewStock.kudAddress = _shopItem.
kudAddress; VII. SMART CONTRACT OPERATION TEST
39. customerNewStock.harvestedDate = _shopItem. We have tested smart contract transactions through the appli-
harvestedDate; cation. This application is connected to the Moralis and Redis
40. customerNewStock.quantity = _amount; Enterprise for synchronization. Each node on the OS network
41. customerNewStock.plantPrice = _shopItem. on the Blockchain can access every transaction connected to
plantPrice; the node chain.
42. customerNewStock.plantName = _shopItem.
TABLE 15. Test Environment System the table provides detailed
plantName; information about the software used.
43. customerNewStock.status = 0;
44. await customerNewStock.SaveAsync();
45. if (itemKUD.quantity > 0) {
46. var success = await itemKUD.SaveAsync();
47. if (success){
48. Debug.Log(‘‘FarmerShop has been decreased, updated
to DB’’);}
49. else{
50. Debug.Log(‘‘Failed to update to FarmerShop DB’’);}}
51. Else { VIII. EXPERIMENTAL EVALUATION
52. await itemKUD.DeleteAsync(); Implementation of this game is that the applications con-
53. Debug.Log(‘‘Shop item reached 0, deleted from nected to a wallet with functions: User Registration, Farm-
Database’’); erStock & FarmerShop, FarmerAuctionFA, FarmerKUD-
54. }}} BiddingTransactionFBT and FarmerKUDTransaction, KUD-
55. public class CustomerStockController Stock & KUD Shop, and KUDConsumerTransaction &
56. { ConsumerStock, then connected to smart contract via My
57. public static async UniTask<Dictionary< QR Code and connected to MetaMask. A confirmation tab
CustomerStock, PlantObject≫ GetStocks(string connecting to the account used for every blockchain game
_userAddress) transaction requires verification of digital signatures that will
58. { be linked to the Moralis SDK Application so that the actors
MoralisQuery<CustomerStock> query = await can see the history of transactions in smart contract.
Moralis.Query<CustomerStock>(); Figure 16(a) Smart contract connected to My Scan QR
query = query.WhereEqualTo(‘‘customerAddress’’, Code via wallet to connect to the agricultural game using
_userAddress); IEnumerable<CustomerStock> result Blockchain-based on serious game. After being connected,
= await query.FindAsync(); it passes based on registered accounts like farmers, Vil-
var list = new Dictionary<CustomerStock, lage Units Cooperative, distributors, or consumers. (b) As a
PlantObject>(); farmer, farmers plant corn and tomatoes on the land in the
foreach (CustomerStock stock in result) game by clicking on the plant options and planting them on
{ var plant = ScriptableUtils.GetPlant the vacant land. (c) waiting for the plants to mature until
(stock.plantName); list.Add(stock, plant); } harvested. (d) input the prices of harvest. The price, harvest
return list;} date, and expiration date (e) a tab of the harvest stock list
59. public static async UniTask<Dictionary< and price that will be sold to the Village Unit Cooperative
CustomerStock, PlantObject≫ GetMyStocks() saved in the FS, then selling the crops from farmers via
60. { FarmerShop (FSH) (f) choose which crops to be sold. (g) Sell
UserModel user = await UserController.GetMyUser(); the crops through the Village Unit Cooperative. Consumer
return await GetStocks(user.ethAddress); }} transaction displays the stock list of the owner (farmer’s
address), purchase amount, harvest date, expired date, pur-
the address and transfers the amount of ETH to TxnHash chase date, condition, and purchase price. (h) Consumer stock
so that the verification process and payment transactions stores consumers purchasing data of farmers and Village Unit
occur. All transactions are recorded and saved in the Cooperative transaction information. (i) and (j) each sale and
smart contract and Blockchain so that transactions can- purchase transaction from the Village Unit Cooperative and
not be manipulated or deleted. The Algorithm 5 source consumer appears request list of distribution section of the
code is accessible on request in the GitHub repository goods. The status would be updated when the goods are

VOLUME 11, 2023 131107


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

FIGURE 14. Blockchain network connected to smart contract node (a) setting moralis cloud server connected to redis enterprise
(b) redis enterprise connected to terminal migration blockchain of parse smart contract node (c)the image above shows the operating
windows server os connected to moralis cloud server network, redis enterprise for database connected to the terminal migration
blockchain of parse smart contract node to synchronize the smart contract and data before running the game application in unity 3D.

TABLE 16. Smart contract deployed transaction gas fee the table provides the used gas. The exchange rate from Polygon to US Dollar 1 MATIC is
1,096 USD.

delivered to the consumer. (k) On FarmerStockFS(), there carried out by the actors involved. As shown in Figure 17 (a),
is an auction button to go to smart bidding regarding the each transaction in supply chain management will save the
price between the farmer and the Village Unit Cooperative data on blockchain node chains, namely MongoDB Compas,
in the commodity auction using the system in smart bidding Network Environment Polygon Testnet Ethereum, and Unity
in the FarmerAuctionFA (l) The farmer will set the base 3D. (a) The blockchain game on FarmerKUDTransaction
price in the smart bidding system in the FarmerStockFS() (FK) transactions stores Hash transactions that will be trans-
menu. (m) Farmers will then receive price offers from sev- ferred to MongoDB Compas and can be viewed in detail in the
eral Cooperative Village Units using the system in smart Ethreum Polygon Testnet Network Environment. Transaction
bidding in the FarmerKUDBidding TransactionFBT Farmers Hash: 0 × 2855339. . . .017876c6c5ee259, Smart Contract
can choose the desired price by pressing the Accepted Bid Call: Aset/Script/Web3Utils/SmartContractCall:cs:99, Sta-
button. tus: Success, Block: 30772690, Timestamp: 38 Seconds
ago (10-Jan-2023 08.2:37 +UTC) from the Village
IX. TESTING Unit Cooperative 0 × 193d. . . .780bb2f8, for farmers
The result of testing Smart Contract scenarios of Blockchain- 0xb8ad. . . .78228e3d050, with a Value of 0.2263809 Matic,
based in serious games in supply chain management is Transaction Fee: 0.000031500000315 Matic and connected
proving the suitability of data using MongoDB Com- to MongoBD Compas.
pas, Polygon, and Unity by entering the transaction hash As in Figure 17 (b) sale and purchase transac-
blockchain address in each transaction shown in Figure 17(a) tions involve Village Unit Cooperative and consumer
and Figure 17(b). They look the same as the transactions in the KUD, ConsumerTransaction(KD) stores TxnHash:

131108 VOLUME 11, 2023


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

FIGURE 15. Smart contract verification with moralis and metamask (a) connected to wallet metamask and game
(b) digital signature of game blockchain transactions.

FIGURE 16. Smart contract-based supply chain management on serious game (a), (b), (c), (d), (e), (f), (g), (h), (i), (j), (k), (l), (m).

0 × 877ed5dc6eec. . . .2ce45530b40d, Smart Contract Fee: 0.000031500000315 Matic are connected then saved in
Call: Asset/Script/Web3Utils/SmartContractCall:cs:99, Sta- MongoBD Compass & CustomerStock(CS).
tus: Success, Block: 30772817, Timestamp: 41 secs a We compare the traceability system designed in this paper
go(Jan-10-2023 08:29:07 AM_UTC) from Consumer: 0 × by using a detailed comparison of each tracing transaction.
9cdc46141ed. . . 95910Ba9ae to Village Unit Cooperative: 0× The details of the comparison results, shown in Figure 18,
193df. . . .780bbb2f8, Value: 0.2645303 Matic, Transaction are below:

VOLUME 11, 2023 131109


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

FIGURE 17. (a) Each transaction in supply chain management will save the data on blockchain node chains,
namely MongoDB Compas, Network Environment Polygon Testnet Ethereum, and Unity 3D. (b) Sale and purchase
transactions involve Village Unit Cooperative and consumers in the KUD, ConsumerTransaction(KD) stores.

a. Traceability: We made a comparison of the tracing sys- the transactions comfortable for the actors with its
tem on the smart contract system in this game; the result interface.
is that all transactions have traceability by checking e. System Scalability: Blockchain can manage supply
the results of transactions using the blockchain address chain management. In large-scale transactions, it will
(Txn Hash) transactions using MongoDB Compas, be a challenge to implement the Blockchain in the
Polygon, and Unity. The results for all transactions are future; hence, the blockchain capacity and speed can
correct. be increased.
b. Decentralized application (Dapps): The transactions Blockchain in supply chain management has challenges
have not involved third parties, so they are peer-to-peer. with capacity and speed. A minimum standard specification
This technology is very secure because no party can is required to install Blockchain: Public blockchains like
access data, control, or change the information of trans- Bitcoin or Ethereum and private blockchains like Hyper-
actions in supply chain management since the ledgers ledger Fabric require a minimum processor with minimal
are all connected in a blockchain network system. Thus, Multi-Core Processors with speed for maximum blockchain
it is very transparent and secure. performance. The minimum RAM capacity on Bitcoin and
c. Accountability and Transparency: The actors involved Ethereum is 5 GB or more. Storage Capacity For example,
in supply chain management can see every transaction Bitcoin requires a large amount of storage. SSD is more
recorded in this blockchain game application. In some recommended than HDD because it reads and writes data
transactions, authority is needed to resolve the prob- faster. The Operating System on the Blockchain is vital
lem; in this case, the Village Unit Cooperative is an when processing blockchain transactions. Recommended
official government that can verify detailed informa- devices include Linux, Windows, MacOS, and a stable
tion and is responsible for logging activity in the Internet connection. These devices are essential in the
Blockchain; hence, the transaction is accountable. blockchain network for network synchronization and inter-
d. User-friendliness: The smart contract application using action. Further, firewall and security have proper firewall
a Blockchain-based scenario for supply chain manage- and security configuration to protect the node from security
ment on serious game is easy to use; thus, it makes threats.

131110 VOLUME 11, 2023


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

FIGURE 18. Details sale and purchase transactions at Polygon, Unity


(a) FarmerKUDTransaction(FK) Transactions (b) KUDConsumerTransaction (KD) &
ConsumerStock (CS).

X. DISCUSSION AND LIMITATIONS The limitation of this research is the application of smart
The purpose of the serious game as a learning medium is contract using Blockchain in serious games based on supply
to simulate a supply chain from farmers to consumers. Seri- chain management in the Indonesian case study. Farmers
ous Game is a collaboration of supply chain management, can directly sell their products to manufacturers, distributors,
Blockchain, and Smart Contract as a data security medium. or consumers without intermediaries, which also requires all
The transactions on the Blockchain are saved in ledgers and the chains in the Dynamic Supply Chain. Farmers benefit
databases stored privately. This application is decentralized by selling products at stable prices on the market without
as a result of cutting distribution channels. intermediaries. Consumers also benefit because purchasing
Blockchain Smart Contract are used as a link between prices are lower through farmers. The results of cutting supply
products from farmers and consumers. Blockchain smart chain distribution channels using blockchain smart contract
contract facilitate contract or agreement between one party are the goals of this game.
without a third party involved. The actors involved in the
Blockchain are farmers, Village Unit Cooperative, Distrib- XI. CONCLUSION
utors, and Consumers. Blockchain facilitates media com- This paper discussed the Serious Game as a Smart Agri-
munication between players in transactions to maximize culture simulation to support transactions on Supply Chain
farmer profits and increase actor knowledge. This applica- Management. The transaction is done without involving third
tion describes the simulation game modeling, input, output, parties like intermediaries since Blockchain technology has
content, and objectives. decentralized data sharing and a system for tracing sale and
The application of Blockchain using Smart Contract and purchase transactions. The data transaction is recorded in the
Smart Bidding is automatic bidding transactions between ledger using a smart contract, and each transaction involves
farmers and VUC. The aim is to increase farmers’ profits actors like the farmer, Village Unit Cooperative, distributor,
based on the price Cost of Goods Sold and Agricultural and consumer. Smart Contract of User Registration (UR),
Exchange Rates. The Cost of Goods Sold describes how FarmerStock & FarmerShop (FSH), FarmerKUDTransaction
farmers can obtain products or services produced from (FK), KUDStock (KS) & KUD Shop (KSH), KUDCon-
the agricultural sector to achieve optimal prices based on sumerTransaction (KD), FarmerAuction(FA), FarmerKUD-
data analysis, optimum price, optimization of farm profits Bidding Transaction (FBT) and ConsumerStock (CS) can
and costs, adjustment of demand and bidding, transac- track and integrate all transactions.
tion efficiency, player decision effects, and performance Smart contract scenario-based games are used to facilitate
evaluation. sale and purchase transactions and to trace data transactions

VOLUME 11, 2023 131111


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

transparently. The scenario is then simulated for farmers who [5] Y. Chang, E. Iakovou, and W. Shi, ‘‘Blockchain in global supply chains and
manage large farms. Farmers can promote the prices prop- cross border trade: A critical synthesis of the state-of-the-art, challenges
and opportunities,’’ Int. J. Prod. Res., vol. 58, no. 7, pp. 2082–2099,
erly and can meet consumer needs. The Smart Contract we Apr. 2020, doi: 10.1080/00207543.2019.1651946.
designed responds to the relevant actor to verify the actor’s [6] S.-K. Kim, ‘‘Blockchain governance game,’’ Comput. Ind. Eng., vol. 136,
identity in the transaction. Digital signatures determine data pp. 373–380, Oct. 2019, doi: 10.1016/j.cie.2019.07.004.
[7] M. Javaid, A. Haleem, R. P. Singh, S. Khan, and R. Suman, ‘‘Blockchain
validity and are saved permanently in the Blockchain that technology applications for industry 4.0: A literature-based review,’’
decentralizes on serious game applications. Smart bidding Blockchain: Res. Appl., vol. 2, no. 4, Dec. 2021, Art. no. 100027, doi:
using blockchain smart contract in agricultural price bid- 10.1016/j.bcra.2021.100027.
[8] M. Vicky and A. Suryono, ‘‘Legal reforming of smart contract in sup-
ding may increase profits without involving intermediaries,
ply chain demands process between retailer and consumer,’’ Jurnal
optimize the prices according to market conditions, increase Kajian Pembaruan Hukum, vol. 3, no. 1, pp. 91–122, Apr. 2023, doi:
efficiency, and provide better access to market information in 10.19184/JKPH.V3I1.33610.
agricultural simulation games. We have also developed this [9] A. Borselli, ‘‘Smart contracts in insurance: A law and futurology perspec-
tive,’’ in InsurTech: A Legal and Regulatory View, Milan, Italy, 2020, doi:
game using Unity 3D Development Platform, programming 10.1007/978-3-030-27386-6.
language contract using Solidity, Moralis as Web3 Develop- [10] R. M. Garcia-Teruel, ‘‘Legal challenges and opportunities of blockchain
ment Platform and dApp as backend blockchain, Network technology in the real estate sector,’’ J. Property, Planning Environ. Law,
vol. 12, no. 2, pp. 129–145, Jan. 2020, doi: 10.1108/JPPEL-07-2019-0039.
Environment Polygon Ethereum, and database that is Redis [11] G. Nalinipriya, R. Sangeetha, K. Saniya, and S. D. Navaraths, ‘‘Agro
Enterprise, MongoDB Compass, and Mumbai Testnet. bidding—A smart dynamic system for enhancement of Farmer’s lifestyle,’’
The testing results of blockchain smart contract show in Proc. Int. Conf. Smart Struct. Syst. (ICSSS), Mar. 2019, doi:
10.1109/ICSSS.2019.8882845.
that transaction data stored in node chains, namely Mon- [12] L. Ming, Z. GuoHua, and W. Wei, ‘‘Study of the game model
goDB Compas, Network Environment Polygon Testnet of E-commerce information sharing in an agricultural product sup-
Ethereum, and Unity 3D have successfully connected ply chain based on fuzzy big data and LSGDM,’’ Technol. Fore-
casting Social Change, vol. 172, Nov. 2021, Art. no. 121017, doi:
to the data obtained from the TxnHash transaction: 10.1016/j.techfore.2021.121017.
0 × 877ed5dc6eec. . . .2ce45530b40d saved successfully [13] S.-K. Kim, ‘‘Blockchain governance game,’’ Comput. Ind. Eng., vol. 136,
and stored in MongoDB Compass and displayed on pp. 373–380, Oct. 2019, doi: 10.1016/j.cie.2019.07.004.
Unity 3D Smart Contract Call: Asset/Script/Web3Utils/ [14] T. Aouam and N. Brahimi, ‘‘Integrated production planning and
order acceptance under uncertainty: A robust optimization approach,’’
SmartContractCall:cs:99, Status: Success, Block: 30772817, Eur. J. Oper. Res., vol. 228, no. 3, pp. 504–515, Aug. 2013, doi:
Timestamp: 41 secs a go(Jan-10-2023 08:29:07 AM_UTC) 10.1016/j.ejor.2013.02.010.
from Consumer: 0 × 9cdc46141ed. . . 95910Ba9ae to Vil- [15] A. Law, ‘‘Smart contracts and their application in supply chain man-
agement,’’ Massachusetts Inst. Technol., Syst. Des. Manage. Program,
lage Unit Cooperative: 0 × 193df. . . .780bbb2f8, Value: Tech. Rep., 2017, pp. 75–79. [Online]. Available: https://dspace.mit.
0.2645303 Matic, Transaction Fee: 0.000031500000315 edu/handle/1721.1/114082
The border of this research is that it has yet to apply the lat- [16] R. B. dos Santos, N. M. Torrisi, and R. P. Pantoni, ‘‘Third party certification
of agri-food supply chain using smart contracts and blockchain tokens,’’
est technology other than that used in this paper. Future work Sensors, vol. 21, no. 16, p. 5307, Aug. 2021, doi: 10.3390/s21165307.
can develop a combination of several different methods for [17] S. Su, K. Wang, and H. S. Kim, ‘‘Smartsupply: Smart contract based valida-
blockchain Smart Contract using Artificial Intelligence, Deep tion for supply chain blockchain,’’ in Proc. IEEE Int. Conf. Internet Things
(iThings), IEEE Green Comput. Commun. (GreenCom), IEEE Cyber, Phys.
Learning, and Machine learning to improve serious games. Social Comput. (CPSCom), IEEE Smart Data (SmartData), Jul. 2018, doi:
It may also create the Game using Metaverse technology so 10.1109/Cybermatics_2018.2018.00186.
that the benefits of blockchain smart contract have value. [18] F. Qu, H. Haddad, and H. Shahriar, ‘‘Smart contract-based secured
business-to-consumer supply chain systems,’’ in Proc. IEEE
Int. Conf. Blockchain (Blockchain), Jul. 2019, pp. 580–585, doi:
ACKNOWLEDGMENT
10.1109/Blockchain.2019.00084.
The authors would like to thank the Telematics Laboratory, [19] V. A. C. Aguiar, M. M. Rosly, and M. Nakano, ‘‘A single player serious
Institut Teknologi Sepuluh Nopember (ITS), Surabaya, and game for sustainable supply chain management,’’ vol. 28, no. 1, pp. 60–72,
Universitas Semarang for supporting this research. 2018, doi: 10.32165/jasag.28.1_60.
[20] Didactical Concepts and Evaluation of a Supply Chain, Online-Labs in
Education, 2022. Accessed: Mar. 20, 2023.
REFERENCES [21] I. A. Ştefan, J. B. Hauge, F. Hasse, and A. Ştefan, ‘‘Using serious games and
[1] R. Rachmawati, ‘‘Smart farming 4.0 Untuk Mewujudkan Pertanian simulations for teaching co-operative decision-making,’’ Proc. Comput.
Indonesia Maju, Mandiri, dan modern,’’ Forum Penelitian Agro Ekonomi, Sci., vol. 162, pp. 745–753, 2019, doi: 10.1016/j.procs.2019.12.046.
vol. 38, no. 2, 2020. Accessed: Mar. 20, 2023. [Online]. Available: [22] N. Kannengießer, S. Lins, C. Sander, K. Winter, H. Frey, and A. Sunyaev,
http://repository.pertanian.go.id/handle/123456789/13300 ‘‘Challenges and common solutions in smart contract development,’’ IEEE
[2] S. Saberi, M. Kouhizadeh, J. Sarkis, and L. Shen, ‘‘Blockchain tech- Trans. Softw. Eng., vol. 48, no. 11, pp. 4291–4318, Nov. 2022, doi:
nology and its relationships to sustainable supply chain management,’’ 10.1109/TSE.2021.3116808.
Int. J. Prod. Res., vol. 57, no. 7, pp. 2117–2135, Apr. 2019, doi: [23] G. J. Reddy, G. H. S. Kumar, T. Lohitasya, V. S. Nilay, K. S. Praveen,
10.1080/00207543.2018.1533261. B. S. Egala, and A. K. Pradhan, ‘‘FarmersChain: A decentralized
[3] P. Bottoni, N. Gessa, G. Massa, R. Pareschi, H. Selim, and farmer centric supply chain management system using blockchain
E. Arcuri, ‘‘Intelligent smart contracts for innovative supply chain and IoT,’’ in Proc. IEEE Int. Symp. Smart Electron. Syst. (iSES),
management,’’ Frontiers Blockchain, vol. 3, p. 52, Nov. 2020, doi: Dec. 2021, pp. 444–449. Accessed: Sep. 27, 2023. [Online]. Available:
10.3389/FBLOC.2020.535787. https://ieeexplore.ieee.org/abstract/document/9701127/
[4] H. Hasan, E. Al Hadhrami, A. Al Dhaheri, K. Salah, and R. Jayaraman, [24] G. N. Nithin, B. S. Egala, and A. K. Pradhan, ‘‘Global level smart
‘‘Smart contract-based approach for efficient shipment management,’’ vaccination tracking system using blockchain and IoT,’’ in Proc. IEEE
Comput. Ind. Eng., vol. 136, pp. 149–159, Oct. 2019, doi: Int. Symp. Smart Electron. Syst. (iSES), Dec. 2021, pp. 450–455, doi:
10.1016/j.cie.2019.07.022. 10.1109/iSES52644.2021.00106.

131112 VOLUME 11, 2023


A. N. Putri et al.: Supply Chain Management Serious Game Using Blockchain Smart Contract

[25] M. Yoo and Y. Won, ‘‘A study on the transparent price tracing system in ASTRID NOVITA PUTRI (Member, IEEE)
supply chain management based on blockchain,’’ Sustainability, vol. 10, received the bachelor’s degree in information
no. 11, p. 4037, Nov. 2018, doi: 10.3390/su10114037. systems and the master’s degree in informatics
[26] M. D. Turjo, M. M. Khan, M. Kaur, and A. Zaguia, ‘‘Smart supply chain engineering, concentrating on game technology,
management using the blockchain and smart contract,’’ Sci. Program., from Universitas Dian Nuswantoro, Semarang.
vol. 2021, pp. 1–12, Sep. 2021, doi: 10.1155/2021/6092792. She is currently pursuing the Ph.D. degree with
[27] T. Nonaka, K. Miki, R. Odajima, and H. Mizuyama, ‘‘Analysis of dynamic the Department of Electrical Engineering, Institut
decision making underpinning supply chain resilience: A serious game Teknologi Sepuluh Nopember Surabaya (ITS).
approach,’’ IFAC-PapersOnLine, vol. 49, no. 19, pp. 474–479, 2016, doi:
She is a Lecturer of technology informatics engi-
10.1016/j.ifacol.2016.10.632.
neering with Universitas Semarang. Her research
[28] D. Muriyatmoko, ‘‘Supply chain management untuk agen game RTS
menggunakan hierarchical finite state machine,’’ J. Animation Games interests include game technology, multimedia, blockchain, and smart city.
Stud., vol. 2, no. 1, p. 1, Jan. 2017, doi: 10.24821/jags.v2i1.1411. In 2012, she received an Excellent Scholarship from the Ministry of Educa-
[29] F. Buccafurri, C. Labrini, and L. Musarella, ‘‘Smart-contract based tion and Culture for the master’s studies.
access control on distributed information in a smart-city scenario,’’ Univ.
Mediterranea of Reggio Calabria, Calabria, Italy, Tech. Rep., 2020.
Accessed: Mar. 20, 2023. [Online]. Available: http://ceur-ws.org/Vol-
2580/DLT_2020_paper_9.pdf
[30] Y. M. Arif, S. Harini, S. M. S. Nugroho, and M. Hariadi, ‘‘An auto-
matic scenario control in serious game to visualize tourism destinations
recommendation,’’ IEEE Access, vol. 9, pp. 89941–89957, 2021, doi:
10.1109/ACCESS.2021.3091425.
[31] P. De Giovanni, ‘‘Blockchain and smart contracts in supply chain manage-
ment: A game theoretic model,’’ Int. J. Prod. Econ., vol. 228, Oct. 2020,
Art. no. 107855, doi: 10.1016/j.ijpe.2020.107855.
[32] G. Nalinipriya, R. Sangeetha, K. Saniya, and S. D. Navaraths, ‘‘Agro
bidding—A smart dynamic system for enhancement of Farmer’s lifestyle,’’ MOCHAMAD HARIADI (Member, IEEE)
in Proc. Int. Conf. Smart Struct. Syst. (ICSSS), Mar. 2019, pp. 1–4, doi: received the bachelor’s degree from the Depart-
10.1109/ICSSS.2019.8882845. ment of Electrical Engineering, Institut Teknologi
[33] M. Galli, D. Mezzogori, D. Reverberi, G. Romagnoli, and F. Zammori, Sepuluh Nopember (ITS), Surabaya, Indonesia,
‘‘Experiencing the role of cooperation and competition in operations and in 1995, and the M.Sc. and Ph.D. degrees from the
supply chain management with a multiplayer serious game,’’ in Proc. IFIP Graduate School of Information Science, Tohoku
Int. Conf. Adv. Prod. Manag. Syst., vol. 633, 2021, pp. 491–499, doi: University, Japan, in 2003 and 2006, respectively.
10.1007/978-3-030-85910-7_52. He is currently a Lecturer with the Department of
[34] H. Rocha and S. Ducasse, ‘‘Preliminary steps towards modeling blockchain Electrical Engineering, ITS. His research interests
oriented software,’’ in Proc. 1st Int. Workshop Emerg. Trends Softw. Eng. include video and image processing, data mining,
Blockchain, May 2018, pp. 52–57, doi: 10.1145/3194113.3194123. and intelligence systems. He is a member of IEICE and IAENG.
[35] C. Udokwu, P. Brandtner, A. Norta, A. Kormiltsyn, and R. Matulevičius,
‘‘Implementation and evaluation of the DAOM framework and support
tool for designing blockchain decentralized applications,’’ Int. J. Inf. Tech-
nol., vol. 13, no. 6, pp. 2245–2263, Dec. 2021, doi: 10.1007/s41870-021-
00816-6.
[36] D. A. Robles-Ramirez, P. J. Escamilla-Ambrosio, and T. Tryfonas, ‘‘IoT-
sec: UML extension for Internet of Things systems security modelling,’’
in Proc. Int. Conf. Mechatronics, Electron. Automot. Eng. (ICMEAE),
Nov. 2017, pp. 151–156, doi: 10.1109/ICMEAE.2017.20.
[37] T. Górski, ‘‘The 1+5 architectural views model in designing blockchain
and IT system integration solutions,’’ Symmetry, vol. 13, no. 11, pp. 1–17,
2021, doi: 10.3390/sym13112000.
[38] L. da S. Leite, A. R. de Farias Neto, F. L. de Lima, and R. M. Chaim, REZA FUAD RACHMADI (Member, IEEE)
‘‘Analyzing and modeling critical risks in software development projects: received the B.Eng. and M.Eng. degrees from
A study based on RFMEA and systems dynamics,’’ in Proc. World Conf. the Department of Electrical Engineering, Insti-
Inf. Syst. Technol. vol. 1368, 2021, pp. 22–35.
tut Teknologi Sepuluh Nopember (ITS), Surabaya,
[39] J. Q. Zhu, B. Shen, Q. P. Yuan, R. R. Zhang, M. W. Chen, W. H. Hu,
Indonesia, in 2008 and 2010, respectively, and
H. R. Guo, and L. L. Yan, ‘‘Events detection and handling based on hier-
archical finite state machines in EAST PCS,’’ Fusion Eng. Des., vol. 184,
the Ph.D. degree from Kumamoto University,
Nov. 2022, Art. no. 113278, doi: 10.1016/J.FUSENGDES.2022.113278. Japan, in 2018. He is currently a Lecturer and
[40] H.-W. Lin, Y.-C. Jhan, and Y.-L. Lin, ‘‘Learners’ hierarchical a Researcher with the Department of Computer
value structures in educational simulation games of supply chain Engineering, ITS. His research interests include
management,’’ Int. J. Online Pedagogy Course Des., vol. 12, computer vision, image understanding, deep con-
no. 1, 2022. Accessed: Mar. 20, 2023. [Online]. Available: volutional neural networks, and image-based intelligent transportation
https://www.igi-global.com/article/learners-hierarchical-value-structures- systems.
in-educational-simulation-games-of-supply-chain-management/311441

VOLUME 11, 2023 131113

You might also like