CRYPTO NEWS

Return type in method signature of ABI and contract differs – ethers.js call still works

I observed a strange behaviour that I cannot explain.

I’m calling the EIP-1271 function

function isValidSignature(bytes32 _dataHash, bytes calldata _signature) external view returns (bytes4) 

of the Gnosis Safe Smart Contract. If the signature is valid, this method is expected to return the EIP-1271 magic value (0x1626ba7e).

I’m using ethers.js and this code:

import { Contract, utils, ethers } from "ethers"; ... const abi = ['function isValidSignature(bytes32 _message, bytes _signature) public view returns (bool)'];  const walletContract = new Contract("0xE1...", abi, provider); let msg = "A simple message"; let sig = "0x"; const hashMessage = utils.hashMessage(msg); const isValid = await walletContract.isValidSignature(hashMessage, sig); if (!isValid ) {    throw new Error("Invalid signature."); } 

The return types of the contract and the ABI differ: byte4 vs. bool. When I execute the code, isValid actually contains a boolean, whereas I would expect the call await walletContract.isValidSignature(hashMessage, sig) to fail because the return type is not byte4.

How does that work? Does ethers.js do some implicit casting of byte4 to boolean?

On a sidenote, using Web3j (Java), the same call fails with the following exception: org.web3j.tx.exceptions.ContractCallException: Unable to convert response

Himo World Announces Open Beta of PvP Strategy Game

Melbourne, Australia, 1st July, 2022, Chainwire Himo World, an NFT-based strategy game developed by Kaofox Corp, has announced its open beta launch. The open beta will go live in July 2022, giving players an opportunity to experience the most advanced iteration of the PvP title to date. The free-to-play release incorporates features that have elevated::Listen

Melbourne, Australia, 1st July, 2022, Chainwire

Himo World, an NFT-based strategy game developed by Kaofox Corp, has announced its open beta launch. The open beta will go live in July 2022, giving players an opportunity to experience the most advanced iteration of the PvP title to date.

The free-to-play release incorporates features that have elevated GameFi into the most innovative gaming vertical in the world. Powered by BNB Chain, Himo World utilizes a Create-to-Earn and Compete-to-Earn model that rewards players for the time they put in. A strategic match-3 game, Himo World combines roster-building elements to offer a wide range of unique Heroes with limitless skill combinations.

Features that will debut with the open beta include:

  • Hero Progress System: Heroes can now level up to learn new skills
  • Gold: new in-game utility which plays a vital role in the create-to-earn model
  • Hero Perks: based on Race & Class, each Hero is empowered with unique perks that can dynamically influence the outcome of every move
  • Roster Synergies: choosing which Heroes to battle is more critical than ever as it will give the Roster unique boosts
  • Expansion of new Rank tiers and fresh Arenas in the game
  • New features including Hero & Skill Fragment drops, Daily Rewards, and other fantastic Liveops
  • Open Beta Main Season will start in July with a $20,000 prize pool to reward the most competitive leaderboard chasers

Available as both a mobile and web app, Hiro World incorporates features that will attract players of all abilities. Its Hero Progress System rewards repeat play, with roster synergies and rank tiers designed to stimulate competition and ensure longevity. In addition to PvP mode, future releases will enable players to participate in rogue-like player-vs-environment (PvE) as well as many other exciting game modes.
 

Himo World Open Beta

The Hero Progress System allows the players’ Heroes to level up for the first time in Himo World. Along with the Heroes’ higher levels, they can learn new skills, which means that the players now can fill out unlockable skill slots to enable more Skills to be triggered. Genesis Heroes, besides high rarity, can now learn up to 4 skills. Players can use Gold to unlock more Heroes’ Skill slots at different level milestones.

Gold, a brand new in-game utility, will significantly contribute to the birth of the Create-to-Earn model in Himo World. In-game, the Gold earned after each match will scale by the player’s rank level. This latest model in GameFi can assist the participants in becoming active “creators” and unlock more untapped potentials in GameFi, which is the path that Himo World aspires to follow. 

The system will have eight rank tiers, including Beginner, Apprentice, Adept, Magnus, Disciple, Master, GrandMaster, and Legendary, ascendingly. Each tier of rank has five levels in which players attain the requisite rank point and can receive the specific corresponding rewards. Notably, more rank tiers will be available in this Open Beta version. 

Himo World strongly believes in the potential of the Create-to-Earn model and competitive GameFi soon. The creators of this unique and creative Strategic Match-3 title strongly believes in a sustainable growth of the genre, in a future where the boundary between Traditional and Gamefi players are indistinguishable, to contribute to the rise of a new competitive breed of gamers. This was proven in the short term by an impressive influx of new users since Closed Beta in May, plus a very high retention rate and engagement up to this point.
 

About Himo World

Himo World is an NFT game that features deck building, strategy mechanics, and match-3 gameplay. It’s super easy to play, but unlike other casual match-3 games, it’s challenging to master.

The game features Free-to-Play, Create-to-Earn, and Compete-to-Earn. Other game modes include Rogue-like PvE, Seasonal Ranking system, Tournaments, Token & Items staking, and many more ground-breaking features yet to be discovered.

Social links:
Telegram: https://t.me/HimoWorldOfficial 

Discord: https://discord.gg/himoworld 

Twitter: https://twitter.com/himoworldglobal

Contacts

Chief Marketing Officer

  • Vu Nguyen
  • Himo World
  • [email protected]

Der Beitrag Himo World Announces Open Beta of PvP Strategy Game erschien zuerst auf Crypto News Flash.

Return type in method signature of ABI and contract differs – ethers.js call still works

Shopping cart
There are no products in the cart!
Continue shopping
0