找回密码
 点一下
查看: 8591|回复: 84

[公告测试]感谢Lars GreedWind WC3C的Zoxc 论坛已支持触发JASS高亮显示 欢迎大家测试

  [复制链接]
发表于 2006-4-2 07:47:40 | 显示全部楼层 |阅读模式
[按名字字母顺序排名]
非常感谢Lars兄的从中帮助
非常感谢GreedWind兄的辛苦努力
非常感谢WC3C的Zoxc 提供代码

论坛目前已经顺利支持触发器的粘贴 可以直观的显示触发器内容
感谢GreedWind长时间辛苦
终于可以支持JASS的高亮显示,在此表示衷心感谢

再次感谢Lars  GreedWind   Zoxc


该功能刚刚增加 不知是否存在BUG 希望大家帮忙测试触发器和JASS的粘贴 按钮就在发贴或回复的一排按钮上  ROC的图标和未知图标

由于WE汉化补丁版本过于繁多 所以目前不支持中文触发器


最后更新 2006.04.06
发表于 2006-4-2 09:14:11 | 显示全部楼层
[trigger]
Initial
    Events
        Map initialization
    Conditions
    Actions
        Custom script:   set udg_Loc=Location(-2390,2370)
        Custom script:   call RandomMZ(66)
        Game - Display to (All players) for 30.00 seconds the text: Map Created
        For each (Integer A) from 0 to 10, do (Actions)
            Loop - Actions
                For each (Integer B) from 0 to 9, do (Actions)
                    Loop - Actions
                        Custom script:   if (udg_toRight[bj_forLoopBIndex+bj_forLoopAIndex*11]==false) then
                        Custom script:   call MoveLocation(udg_Loc,-2368+bj_forLoopBIndex*512,2368-bj_forLoopAIndex*512)
                        Destructible - Create a Door (Vertical) at Loc facing 0.00 with scale 0.50 and variation 0
                        Destructible - Make (Last created destructible) Invulnerable
                        Custom script:   endif
                        Custom script:   if (udg_toDown[bj_forLoopAIndex+bj_forLoopBIndex*11]==false) then
                        Custom script:   call MoveLocation(udg_Loc,-2624+bj_forLoopAIndex*512,2112-bj_forLoopBIndex*512)
                        Destructible - Create a Door (Horizontal) at Loc facing 0.00 with scale 0.50 and variation 0
                        Destructible - Make (Last created destructible) Invulnerable
                        Custom script:   endif
[/trigger]
测试...
测试结果:All Pass...

恩恩,以后的JASS语法显示应该是[JASS][/JASS]标签吧...

[ 本帖最后由 白银の游戏王 于 2006-4-2 09:18 编辑 ]
回复

使用道具 举报

 楼主| 发表于 2006-4-2 09:40:34 | 显示全部楼层
[trigger]HeroBeKillEvent
    Events
        Unit - A unit owned by Player 1 (Red) Dies
        Unit - A unit owned by Player 2 (Blue) Dies
        Unit - A unit owned by Player 3 (Teal) Dies
        Unit - A unit owned by Player 4 (Purple) Dies
        Unit - A unit owned by Player 5 (Yellow) Dies
        Unit - A unit owned by Player 6 (Orange) Dies
        Unit - A unit owned by Player 7 (Green) Dies
        Unit - A unit owned by Player 8 (Pink) Dies
    Conditions
        ((Dying unit) is A Hero) Equal to True
    Actions
        Set KilledHero = (Dying unit)
        Countdown Timer - Start FuhuoHeroTimer[(Custom value of KilledHero)] as a One-shot timer that will expire in 45.00 seconds
        Countdown Timer - Create a timer window for (Last started timer) with title death time
        Set FuhuoHeroTimerWindows[(Custom value of KilledHero)] = (Last created timer window)
        Countdown Timer - Show FuhuoHeroTimerWindows[(Custom value of KilledHero)]
        Unit - Suspend corpse decay for KilledHero
        Unit - Hide KilledHero
        Wait 45.00 seconds
        Unit - Unhide KilledHero
        Camera - Pan camera for (Owner of KilledHero) to (Position of KilledHero) over 2.00 seconds
        Countdown Timer - Destroy FuhuoHeroTimerWindows[(Custom value of KilledHero)][/trigger]
回复

使用道具 举报

发表于 2006-4-2 09:46:17 | 显示全部楼层
[trigger]HeroBeKillEvent
    Events
        Unit - A unit owned by Player 1 (Red) Dies
        Unit - A unit owned by Player 2 (Blue) Dies
        Unit - A unit owned by Player 3 (Teal) Dies
        Unit - A unit owned by Player 4 (Purple) Dies
        Unit - A unit owned by Player 5 (Yellow) Dies
        Unit - A unit owned by Player 6 (Orange) Dies
        Unit - A unit owned by Player 7 (Green) Dies
        Unit - A unit owned by Player 8 (Pink) Dies
    Conditions
        ((Dying unit) is A Hero) Equal to True
    Actions
        Set KilledHero = (Dying unit)
        Countdown Timer - Start FuhuoHeroTimer[(Custom value of KilledHero)] as a One-shot timer that will expire in 45.00 seconds
[/trigger]
回复

使用道具 举报

发表于 2006-4-2 09:49:37 | 显示全部楼层
测试专用!请勿执行!该触发将快速导致死机!
[trigger]Damn
    Events
        Time - Every 0.01 seconds of game time
    Conditions
    Actions
        Lightning - Create a lightning effect Chain Lightning - Primary (Center of (Playable map area)) (Random point in (Playable map area))
        Lightning - Create a lightning effect Chain Lightning - Secondary (Center of (Playable map area)) (Random point in (Playable map area))
        Lightning - Create a lightning effect Drain (Center of (Playable map area)) (Random point in (Playable map area))
        Lightning - Create a lightning effect Life Drain (Center of (Playable map area)) (Random point in (Playable map area))
        Lightning - Create a lightning effect Mana Drain (Center of (Playable map area)) (Random point in (Playable map area))
        Lightning - Create a lightning effect Finger of Death (Center of (Playable map area)) (Random point in (Playable map area))
        Lightning - Create a lightning effect Forked Lightning (Center of (Playable map area)) (Random point in (Playable map area))
        Lightning - Create a lightning effect Healing Wave - Primary (Center of (Playable map area)) (Random point in (Playable map area))
        Lightning - Create a lightning effect Healing Wave - Secondary (Center of (Playable map area)) (Random point in (Playable map area))
        Lightning - Create a lightning effect Lightning Attack (Center of (Playable map area)) (Random point in (Playable map area))
        Lightning - Create a lightning effect Magic Leash (Center of (Playable map area)) (Random point in (Playable map area))
        Lightning - Create a lightning effect Mana Burn (Center of (Playable map area)) (Random point in (Playable map area))
        Lightning - Create a lightning effect Mana Flare (Center of (Playable map area)) (Random point in (Playable map area))
        Lightning - Create a lightning effect Spirit Link (Center of (Playable map area)) (Random point in (Playable map area))[/trigger]

注:大家都可以看得出来,这触发有多可怕吧……

[ 本帖最后由 狐狸兄EX 于 2006-4-2 10:09 编辑 ]
回复

使用道具 举报

发表于 2006-4-2 12:01:26 | 显示全部楼层
不会。因为是在本地运算的。


唉。。没有英文版。。。郁闷。


[trigger]对战初始化
    事件
        Map initialization
    环境
    动作
        对战游戏 - Use melee time of day (for all players)
        对战游戏 - Limit Heroes to 1 per Hero-type (for all players)
        对战游戏 - Give trained Heroes a Scroll of Town Portal (for all players)
        对战游戏 - Set starting resources (for all players)
        对战游戏 - Remove creeps and critters from used start locations (for all players)
        对战游戏 - Create starting units (for all players)
        对战游戏 - Run melee AI scripts (for computer players)
        对战游戏 - Enforce victory/defeat conditions (for all players)[/trigger]
[trigger]
对战初始化
    事件
        地图初始化
    环境
    动作
        对战游戏 - 对用对战的时间设置 (对所有玩家)
        对战游戏 - 每一类型的英雄只召唤一个 对所有玩家)
        对战游戏 - 给英雄回城卷轴 (对所有玩家)
        对战游戏 - 设置初始资源 (对所有玩家)
        对战游戏 - 从被使用的 初始位置 中删除野生单位和小动物 (对所有玩家)
        对战游戏 - 创建初始单位 (对所有玩家)
        对战游戏 - 运行对战 AI 脚本 (对所有电脑玩家)
        对战游戏 - 强迫胜利/失败条件(对所有玩家)
[/trigger]

[ 本帖最后由 amp34 于 2006-4-2 12:29 编辑 ]
回复

使用道具 举报

发表于 2006-4-2 12:58:41 | 显示全部楼层
自己做了个双语版的汉化补丁
看来只要动作分类对了就行

[trigger]
Test2
    事件
        Player - 玩家 1 (红色) skips a cinematic sequence
    环境
    动作
        Set I = 0
        For each (Integer A) from 0 to 10, do (Actions)
            Loop - 动作
                For each (Integer B) from 0 to 9, do (Actions)
                    Loop - 动作
                        Set ptTemp = ((Position of 血魔法师 0001 <gen>) offset by ((0.00 + (128.00 * (Real((Integer B))))), (-128.00 - (64.00 * (Real((Integer A)))))))
                        Floating Text - Create floating text that reads (String(I)) at ptTemp with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
                        Custom script: set udg_iTemp = H2I(bj_lastCreatedTextTag)
                        Floating Text - Change text of (Last created floating text) to ((String(I)) + (( + ((String(iTemp)) + )))) using font size 10.00
                        Floating Text - Change (Last created floating text): 不允许 permanence
                        Floating Text - Change the lifespan of (Last created floating text) to 10.00 seconds
                        -------- Next --------
                        Set I = (I + 1)
[/trigger]

[ 本帖最后由 zyl910 于 2006-4-2 13:02 编辑 ]
回复

使用道具 举报

发表于 2006-4-2 13:02:58 | 显示全部楼层
还存在一个问题:
若存在水平滚动条
就不会显示最后一行
老要我们拖动滚动条
回复

使用道具 举报

发表于 2006-4-2 13:34:01 | 显示全部楼层
嗯。相信会解决D。。。
呃。看了一下代码。希望可以用
(项目数+1)*项目高
或者
项目数*项目高+滚动条的高。
来代替<div class=\"treeblock\" style=\"height:auto;\">
中的auto......
回复

使用道具 举报

发表于 2006-4-2 15:27:48 | 显示全部楼层
别忘记了,<DIV>的属性好像是只读的,所以。。。。。
回复

使用道具 举报

发表于 2006-4-2 15:31:09 | 显示全部楼层
原帖由 zyl910 于 2006-4-2 12:58 发表
自己做了个双语版的汉化补丁
看来只要动作分类对了就行

[trigger]
Test2
    事件
        Player - 玩家 1 (红色) skips a cinematic sequenc ...



这个容易解决的,只是WE中文版本有好多,所以没去做。。。。。
回复

使用道具 举报

发表于 2006-4-2 15:34:00 | 显示全部楼层
不知道谁有PHP的 ANSI2UNICODE程序?
回复

使用道具 举报

发表于 2006-4-2 15:52:18 | 显示全部楼层
我这有两个触发器贴上去不显示 不知道是我用法不当还是。。
http://www.gacn.net/forum/viewth ... ra=page%3D1#pid4141
回复

使用道具 举报

发表于 2006-4-2 16:03:23 | 显示全部楼层
[trigger]abc[/trigger]
回复

使用道具 举报

发表于 2006-4-2 16:21:18 | 显示全部楼层
应该是特殊字符的使用问题,程序没对一些特殊字符做处理。
把你不能显示的TRIGGER用[code][/code]粘贴出来看看。

[ 本帖最后由 greedwind 于 2006-4-2 16:23 编辑 ]
回复

使用道具 举报

发表于 2006-4-2 16:32:16 | 显示全部楼层
原帖由 greedwind 于 2006-4-2 15:34 发表
不知道谁有PHP的 ANSI2UNICODE程序?


偶只有C#版的...
回复

使用道具 举报

发表于 2006-4-2 16:42:35 | 显示全部楼层
不是人人都回JASS的

一定要支持中文!
回复

使用道具 举报

发表于 2006-4-2 17:25:16 | 显示全部楼层
原帖由 greedwind 于 2006-4-2 16:21 发表
应该是特殊字符的使用问题,程序没对一些特殊字符做处理。
把你不能显示的TRIGGER用[ code ][ /code ]粘贴出来看看。


其他的都能正常显示 就这两个什么都显示不出来:L

  1. Goldbachs conjecture 1
  2.     Events
  3.         Player - Player 1 (Red) types a chat message containing G as A substring
  4.     Conditions
  5.         (Integer((Substring((Entered chat string), 2, (Length of (Entered chat string)))))) Greater than 2
  6.     Actions
  7.         For each (Integer A) from 3 to (Integer((Substring((Entered chat string), 2, (Length of (Entered chat string)))))), do (Actions)
  8.             Loop - Actions
  9.                 Set P[1] = ((Integer A) + 1)
  10.                 Set P[2] = ((Integer A) - 1)
  11.                 Trigger - Run Goldbachs conjecture 2 <gen> (ignoring conditions)
  12.         If (GoldbachsTrueOrFalse Equal to True) then do (Game - Display to (All players) for 60.00 seconds the text: ((|cffffcc00 + (Substring((Entered chat string), 2, (Length of (Entered chat string))))) +  浠ュ?绗??Goldbach\'s conjecture|r)) else do (Set GoldbachsTrueOrFalse = True)
  13.         Set index = 1
复制代码

  1. Goldbachs conjecture 2
  2.     Events
  3.     Conditions
  4.     Actions
  5.         Set P[1] = (P[1] - 1)
  6.         Set P[2] = (P[2] + 1)
  7.         If (All Conditions are True) then do (Then Actions) else do (Else Actions)
  8.             If - Conditions
  9.                 P[1] Equal to 2
  10.             Then - Actions
  11.                 Game - Display to (All players) for 60.00 seconds the text: ((String((Integer A))) +  涓????oldbach\'s conjecture)
  12.                 Set GoldbachsTrueOrFalse = False
  13.                 Skip remaining actions
  14.             Else - Actions
  15.         Set index = 1
  16.         Trigger - Run Goldbachs conjecture 3 <gen> (ignoring conditions)
  17.         Set index = 2
  18.         Trigger - Run Goldbachs conjecture 3 <gen> (ignoring conditions)
  19.         If (All Conditions are True) then do (Then Actions) else do (Else Actions)
  20.             If - Conditions
  21.                 PrimeTrueOrFalse[1] Equal to True
  22.                 PrimeTrueOrFalse[2] Equal to True
  23.             Then - Actions
  24.                 Game - Display to (All players) for 60.00 seconds the text: (((String((Integer A))) + =() + ((String(P[1])) + (+ + ((String(P[2])) + )/2))))
  25.                 Skip remaining actions
  26.             Else - Actions
  27.                 Set PrimeTrueOrFalse[1] = True
  28.                 Set PrimeTrueOrFalse[2] = True
  29.                 Trigger - Run (This trigger) (ignoring conditions)
复制代码

[ 本帖最后由 illlusion 于 2006-4-2 17:28 编辑 ]
回复

使用道具 举报

 楼主| 发表于 2006-4-2 18:48:54 | 显示全部楼层
  1.         If (GoldbachsTrueOrFalse Equal to True) then do (Game - Display to (All players) for 60.00 seconds the text: ((|cffffcc00 + (Substring((Entered chat string), 2, (Length of (Entered chat string))))) +  Goldbach\'s conjecture|r)) else do (Set GoldbachsTrueOrFalse = True)
复制代码


应该是这句的原因造成的
回复

使用道具 举报

发表于 2006-4-2 19:11:39 | 显示全部楼层
经初步确认,是个 \' 的问题!!!
会修改的。

[ 本帖最后由 greedwind 于 2006-4-2 19:12 编辑 ]
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 点一下

本版积分规则

Archiver|移动端|小黑屋|地精研究院

GMT+8, 2024-10-1 12:03 , Processed in 0.039130 second(s), 19 queries .

Powered by Discuz! X3.5

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表