强化装备 垫子玄学
来源:互联网 发布:美工修图多少钱一张 编辑:程序博客网 时间:2024/06/10 04:07
垫子问题
如果游戏强化机制用的是random()函数,那么多半没有给定种子,以无参构造函数使用。
而无参形式便与当前时间有关,也就有网友说的是 某强化时间段 成功率高的原因。
但系统随机都是伪随机。
例如给定种子(带参数的):
Random random = new Random(50);
System.out.println(random.nextInt(100));
System.out.println(random.nextInt(100));
Random random1 = new Random(50);
System.out.println(random1.nextInt(100));
System.out.println(random1.nextInt(100));
输出:
17
88
17
88
而不给定种子的无参构造函数与当前时间有关。
其源码:
public
Random() {
this
(seedUniquifier() ^ System.nanoTime());
}
System.nanoTime() 可以看出这个就是与系统时间相关的,继续百度。
public static long nanoTime():
Returns the current value of the most precise available system timer, in nanoseconds.This method can only be used to measure elapsed time and is not related to any other notion of system or wall-clock time.The value returned represents nanoseconds since some fixed but arbitrary time (perhaps in the future, so values may be negative). This method provides nanosecond precision, but not necessarily nanosecond accuracy. No guarantees are made about how frequently values change. Differences in successive calls that span greater than approximately 292 years (263 nanoseconds) will not accurately compute elapsed time due to numerical overflow.
Returns:The current value of the system timer, in nanoseconds.
Since:1.5
上面说返回当前的系统时间,以毫微秒的方式。
但中间有段英语,说以何时开始计算起始点并不确定。。。也就是说,初始值不确定。
于是这个函数一般用于计算中间的时间段。。。
可是,初始值为什么不确定,可以继续研究。。。
-----------------------------------------------
11.11日 看主播"撸了22年的右手"强化装备,各种失败。。。再次觉得冒险岛2强化装备 垫子没啥卵用。
- 强化装备 垫子玄学
- 装备强化与装备品质
- 玄学
- 装备
- 装备
- 装备
- 网易游戏2017互娱实习笔试编程(强化装备)
- 玄学杂说
- 玄学啊
- 玄学琐谈2
- Lightoj 1098【数学/玄学】
- Treap模板【玄学】
- 【玄学数论】Euclid
- 玄学算法CDQ分治
- 没有玄学,只有细节
- tarjan中的玄学
- BZOJ1426 玄学概率DP
- java装备
- WorkerMan和ThingPHP的结合使用
- 三道典型C语言题(4)
- java对象与json之间的转换
- SVG与Canvas的特点
- 18.笔记JAVASpring框架学习————基于注解配置Bean之二
- 强化装备 垫子玄学
- Log4j2官方文档翻译、学习笔记之一——log4j2基础配置及功能概述
- XYNUOJ 图像有用区域
- Jzoj5429 排列
- matplotlib的图片文字乱码
- 19.笔记JAVA Spring框架学习————Spring整合Hibernate
- java:文件的复制
- Windows下lua+redis调试环境搭建
- 如何简单设计接口测试用例