查看: 5536|回复: 7

[交流讨论] 谁日语好的去官方提个建议呗

[复制链接]

笑问情缘

梦石
0
星屑
68
在线时间
238 小时
注册时间
2006-5-3
回帖
544
发表于 2015-12-4 13:34:13 来自手机 | 显示全部楼层 |阅读模式

加入我们,或者,欢迎回来。

您需要 登录 才可以下载或查看,没有账号?注册会员

×
不明白啊,既然出了mv,支持多平台,就应该在分歧里面加上上划,下滑之类的代替按键啊,不然做出来的按键判断根本没用啊!

梦石
1
星屑
23371
在线时间
9572 小时
注册时间
2012-6-19
回帖
7021

开拓者短篇九导演组冠军

发表于 2015-12-4 13:35:42 | 显示全部楼层
因为,多平台只是顺便
回复

使用道具 举报

梦石
0
星屑
156
在线时间
61 小时
注册时间
2011-2-3
回帖
47
发表于 2015-12-4 14:34:38 | 显示全部楼层
在安卓下能点击选 择吗
回复

使用道具 举报

梦石
0
星屑
60
在线时间
306 小时
注册时间
2014-8-5
回帖
403
发表于 2015-12-4 14:36:02 | 显示全部楼层
目前只是先行版。
  点我进入    
       ↓      
回复

使用道具 举报

梦石
0
星屑
1232
在线时间
1017 小时
注册时间
2011-4-30
回帖
1464
发表于 2015-12-4 15:06:02 | 显示全部楼层
本帖最后由 汪汪 于 2015-12-4 16:11 编辑

自己写吧.....
应该并不复杂.
我这种小白都写了个上划下划改变 数值输入 商店输入的 插件


点击展开/收起


  1. TouchInput._onTrigger = function(x, y) {
  2.     this._events.triggered = true;
  3.     this._x = x;
  4.     this._y = y;
  5.     this._date = Date.now();
  6.    
  7.     this._stx = x
  8.     this._sty = y;
  9.    
  10. };


  11. TouchInput._onRelease = function(x, y) {
  12.     this._events.released = true;
  13.     this._x = x;
  14.     this._y = y;

  15.     this._stx = x
  16.     this._sty = y;
  17. };

  18. //在条件分歧里的 脚本中使用就好..... 然后地图上会出现很奇怪的现象
  19. TouchInput.moveup = function(xup, yup) {
  20.         this._stx = this._stx || 0
  21.         this._sty = this._sty || 0
  22.     var tx = this._x - this._stx
  23.     var ty =  this._y - this._sty
  24.     var xtrue = false
  25.     var ytrue = false
  26.    
  27.     if ((xup == 0)||( ( (xup * tx )>0 )&& (Math.abs(tx) >  Math.abs(xup)) )){
  28.              xtrue = true
  29.     }
  30.     if ((yup == 0)||( ( (yup * ty )>0 )&& (Math.abs(ty) >  Math.abs(yup)) )){
  31.              ytrue = true
  32.     }
  33.     return xtrue &&  ytrue
  34. };





复制代码

点评

……那就需要记录位置了。。。。  发表于 2015-12-4 17:44
求手势操作QAQ  发表于 2015-12-4 17:16
回复

使用道具 举报

笑问情缘

梦石
0
星屑
68
在线时间
238 小时
注册时间
2006-5-3
回帖
544
 楼主| 发表于 2015-12-4 16:46:44 来自手机 | 显示全部楼层
能用在图片选项那里么?
回复

使用道具 举报

梦石
0
星屑
90
在线时间
387 小时
注册时间
2007-7-27
回帖
4075

开拓者

发表于 2015-12-4 18:49:40 | 显示全部楼层
现在日版都没发布呢,应该去英文论坛提意见(不
吸吸
回复

使用道具 举报

梦石
0
星屑
1232
在线时间
1017 小时
注册时间
2011-4-30
回帖
1464
发表于 2015-12-4 20:43:58 | 显示全部楼层
本帖最后由 汪汪 于 2015-12-4 20:45 编辑

鼠标加强手势
  1. //=============================================================================
  2. // ww_Gesture.js
  3. //=============================================================================
  4. /*:
  5. * @plugindesc 鼠标加强手势
  6. * @author wangwang
  7. *
  8. * @param jiange
  9. * @desc 默认鼠标轨迹记录间隔
  10. * @default 20
  11. *
  12. * @param fangshi
  13. * @desc 默认判断方式 0 完全匹配 1,最后匹配  2 最前匹配  3 包含
  14. * @default 0
  15. *
  16. * @param jishi
  17. * @desc 是否即时判断? 0兼用,1即时,2之前
  18. * @default 0
  19. *
  20. * @help
  21. * 参考:
  22. *    FireGestures.uc.js
  23. * 功能:
  24. * 触摸上添加鼠标手势的判断
  25. * 使用方法:
  26. * TouchInput.Gesture(gt, fangshi,jishi )
  27. * gt 是一个数组 ,包含手势信息,如[2,6,8,4] 下,右,上,左
  28. * fangshi 判断的方式,
  29. *    0 完全匹配 必须手势完全一致
  30. *    1 最后匹配 必须最后的那部分手势完全一致
  31. *    2 最前匹配 必须最前面的那部分手势完全一致
  32. *    3 包含匹配 手势包含即可
  33. * jishi 判断是否即时?
  34. *    0 兼用 ,判断 正在绘制的手势或者之前绘制完的手势
  35. *    1 即时 ,判断 正在绘制的手势
  36. *    2 判断 ,判断 之前绘制完的手势
  37. */



  38. (function() {


  39. TouchInput.clear = function() {
  40.         //鼠标按下
  41.     this._mousePressed = false;
  42.     //屏幕按下
  43.     this._screenPressed = false;
  44.     //按下时间
  45.     this._pressedTime = 0;
  46.     //事件
  47.     this._events = {};
  48.     //事件 触发
  49.     this._events.triggered = false;
  50.     //事件 取消
  51.     this._events.cancelled = false;
  52.     //事件 移动
  53.     this._events.moved = false;
  54.     //事件释放
  55.     this._events.released = false;
  56.     //事件 轮x
  57.     this._events.wheelX = 0;
  58.     //事件 轮y
  59.     this._events.wheelY = 0;
  60.     //触发
  61.     this._triggered = false;
  62.     //取消
  63.     this._cancelled = false;
  64.     //移动
  65.     this._moved = false;
  66.     //释放
  67.     this._released = false;
  68.     //轮x
  69.     this._wheelX = 0;
  70.     //轮y
  71.     this._wheelY = 0;
  72.     this._x = 0;
  73.     this._y = 0;
  74.     //日期
  75.     this._date = 0;
  76.     //修改部分
  77.     this._Gesture_last_dChain = []
  78.     this._Gesture_directionChain = []
  79.     var jiange = parseInt(PluginManager.parameters("ww_Gesture")["jiange"], 10);
  80.     var fangshi = parseInt(PluginManager.parameters("ww_Gesture")["fangshi"], 10);
  81.     var jishi =parseInt(PluginManager.parameters("ww_Gesture")["jishi"], 10);
  82.     if (isFinite(jiange) && jiange > 0 )
  83.     {
  84.             this._Gesture_jiange  = jiange
  85.     }else {
  86.             this._Gesture_jiange  = 20
  87.     }
  88.     if (isFinite(fangshi) && [0,1,2].contains(fangshi) )
  89.     {
  90.             this._Gesture_fangshi  = fangshi
  91.     }else {
  92.             this._Gesture_fangshi  = 0
  93.     }
  94.     if (isFinite(jishi) && [0,1,2].contains(jishi) )
  95.     {
  96.             this._Gesture_jishi  = jishi
  97.     }else {
  98.             this._Gesture_jishi  = 0
  99.     }
  100. };




  101. TouchInput._onTrigger = function(x, y) {
  102.     this._events.triggered = true;
  103.     this._x = x;
  104.     this._y = y;
  105.     this._date = Date.now();
  106.     //修改部分
  107.     this.startGesture(x,y)
  108. };

  109. /**当取消 x,y
  110. * @static
  111. * @method _onCancel
  112. * @param {Number} x
  113. * @param {Number} y
  114. * @private
  115. */
  116. TouchInput._onCancel = function(x, y) {
  117.     this._events.cancelled = true;
  118.     this._x = x;
  119.     this._y = y;
  120.     //修改部分
  121.    
  122.     this.stopGesture(x,y)
  123. };

  124. /**当移动 x,y
  125. * @static
  126. * @method _onMove
  127. * @param {Number} x
  128. * @param {Number} y
  129. * @private
  130. */
  131. TouchInput._onMove = function(x, y) {
  132.     this._events.moved = true;
  133.     this._x = x;
  134.     this._y = y;
  135.     //修改部分
  136.     this.progressGesture(x,y)
  137.    
  138. };

  139. /**当释放
  140. * @static
  141. * @method _onRelease
  142. * @param {Number} x
  143. * @param {Number} y
  144. * @private
  145. */
  146. TouchInput._onRelease = function(x, y) {
  147.     this._events.released = true;
  148.     this._x = x;
  149.     this._y = y;
  150.     //修改部分
  151.     this.stopGesture(x,y)
  152. };





  153.     //开始手势
  154.         TouchInput.startGesture = function (x,y) {
  155.                 this._Gesture_lastX = x;
  156.                 this._Gesture_lastY = y;
  157.                 this._Gesture_last_dChain = []
  158.                 this._Gesture_directionChain = [];
  159.         }
  160.        
  161.         //进行手势
  162.         TouchInput.progressGesture = function (x,y) {
  163.                 var x = x
  164.                 var y = y
  165.                 var lastX = this._Gesture_lastX
  166.                 var lastY = this._Gesture_lastY;
  167.                 var jiange = this._Gesture_jiange
  168.                 //差值
  169.                 var subX = x - lastX
  170.                 var subY = y - lastY;
  171.                 //差值的绝对值
  172.                 var distX = (subX > 0 ? subX : (-subX))
  173.                 var distY = (subY > 0 ? subY : (-subY));
  174.                 var direction;
  175.                 //如果差值绝对值小于间隔
  176.                 if (distX < jiange && distY < jiange )
  177.                         return;
  178.             // 如果 x 差值 > y 差值
  179.                 if (distX > distY)
  180.                     //方向左
  181.                         direction = subX < 0 ? 4 : 6;
  182.                 else
  183.                     //方向上下
  184.                         direction = subY < 0 ? 8 : 2;
  185.                         //方向链
  186.                 var dChain = this._Gesture_directionChain;
  187.                
  188.                 //如果方向 不等于 方向链 最后一个
  189.                 if (direction != dChain[dChain.length - 1]) {
  190.                         dChain.push(direction);
  191.                         this._Gesture_directionChain = dChain
  192.                 }
  193.                 this._Gesture_lastX = x;
  194.                 this._Gesture_lastY = y;
  195.         }

  196.         //停止手势
  197.         TouchInput.stopGesture = function (x,y) {
  198.                 this._Gesture_last_dChain  = this._Gesture_directionChain
  199.                 this._Gesture_directionChain = [];
  200.                 return this._Gesture_last_dChain
  201.         }
  202.        
  203.     TouchInput.Gesture = function(gt,fangshi,jishi){
  204.             var jishi = jishi || this._Gesture_jishi
  205.             var fangshi = fangshi || this._Gesture_fangshi
  206.             var  gesture;
  207.             var  gesture2 ;
  208.             if  ( jishi == 1  ||  jishi == 0){
  209.                     gesture = this._Gesture_directionChain.clone()
  210.                     gesture2= gt.clone()
  211.                     if(gesture.join()!= "" && gesture2.join() != ""){
  212.                             if (fangshi == 0){
  213.                                     if ( gesture.join() == gesture2.join()){
  214.                                             return true
  215.                                         }
  216.                             }
  217.                             if ( fangshi == 1 ){
  218.                                     gesture.reverse()
  219.                                     gesture2.reverse()
  220.                                     if( gesture.join().indexOf( gesture2.join()) == 0 ){
  221.                                             return true
  222.                                     }
  223.                             }
  224.                             if ( fangshi == 2 ){
  225.                                     if( gesture.join().indexOf( gesture2.join()) == 0 ){
  226.                                             return true
  227.                                     }
  228.                             }
  229.                             if ( fangshi == 3 ){
  230.                                     if( gesture.join().indexOf( gesture2.join()) >= 0 ){
  231.                                             return true
  232.                                     }
  233.                             }
  234.                     }
  235.             }
  236.             if (jishi == 2 || jishi == 0){
  237.                     gesture = this._Gesture_last_dChain.clone()
  238.                     gesture2= gt.clone()
  239.                     if(gesture.join()!= "" && gesture2.join() != "" ){
  240.                             if (fangshi == 0){
  241.                                     if ( gesture.join() == gesture2.join()){
  242.                                             return true
  243.                                         }
  244.                             }
  245.                             if ( fangshi == 1 ){
  246.                                     gesture.reverse()
  247.                                     gesture2.reverse()
  248.                                     if( gesture.join().indexOf( gesture2.join()) == 0 ){
  249.                                             return true
  250.                                     }
  251.                             }
  252.                             if ( fangshi == 2 ){
  253.                                     if( gesture.join().indexOf( gesture2.join()) == 0 ){
  254.                                             return true
  255.                                     }
  256.                             }
  257.                             if ( fangshi == 3 ){
  258.                                     if( gesture.join().indexOf( gesture2.join()) >= 0 ){
  259.                                             return true
  260.                                     }
  261.                             }
  262.                     }
  263.             }
  264.             return false
  265.     }



  266.    






















  267. })();

复制代码













  参考的 FireGestures.uc.js
@墨凌羽   
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册会员

本版积分规则

Powered by Discuz! X5.0 © 2001-2026 Discuz! Team.

在本版发帖返回顶部