Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
share
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张振华
share
Commits
e986eaee
Commit
e986eaee
authored
Dec 11, 2018
by
张振华
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
7b583b3f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
11 deletions
+6
-11
数据发布预言机合约.md
数据发布预言机合约.md
+6
-11
No files found.
数据发布预言机合约.md
View file @
e986eaee
...
@@ -93,16 +93,11 @@ Event {
...
@@ -93,16 +93,11 @@ Event {
}
}
```
```
该事件表示:未来将公布【bitcoin】【blockhash】【大概时间2018-12-12 07:30:00之后】【区块高度为553450】的hash值。
该事件表示:未来将公布【bitcoin】【blockhash】【大概时间2018-12-12 07:30:00之后】【区块高度为553450】的hash值。
有一些博彩游戏,对实时性要求不高,比如说未来开奖的游戏B,要使用随机数,可以使用该事件结果作为作为随机数计算开奖结果。
有一些博彩游戏,对实时性要求不高,比如说未来开奖的游戏B,要使用随机数,可以使用该事件结果作为作为随机数计算开奖结果。
当bitcoin的区块高度达到设定高度553450后,addr将其生成的blockhash进行预发布到区块链全网,确认无误,无人提出异议,过一段时间后addr正式发布该结果。
当bitcoin的区块高度达到设定高度553450后,addr将其生成的blockhash进行预发布到区块链全网,确认无误,无人提出异议,过一段时间后addr正式发布该结果。
游戏B使用最终发布的blockhash计算开奖结果,对参与的玩家进行输赢判断及结算。
游戏B使用最终发布的blockhash计算开奖结果,对参与的玩家进行输赢判断及结算。
说明:
对于使用预言机发布数据的游戏合约,本身对预言机要发布的具体事件有具体的了解,知道数据如何在自己的游戏中使用。比如足球比赛,给出了开赛时间,则游戏设定要提前终止投注,保证参与公平性。
再比如对于比特币的未来区块hash做开奖随机数的场景,游戏合约要知道未来生成区块hash的时间是一个估算值,数据发布者会实时调整确保估算尽量准确,但由于区块生成时间本身并不固定,所以游戏合约要考虑时间波动因素,确保提前结束投注,保证参与公平性。
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment