[求助]卧龙先生 请教几个问题!
(defrule(true)
=>
(set-strategic-number sn-maximum-food-drop-distance 0)
(set-strategic-number sn-maximum-wood-drop-distance 0)
(set-strategic-number sn-maximum-gold-drop-distance 0)
(set-strategic-number sn-maximum-stone-drop-distance 0)
(set-strategic-number sn-maximum-hunt-drop-distance 0)
(set-strategic-number sn-food-gatherer-percentage 0)
(set-strategic-number sn-gold-gatherer-percentage 0)
(set-strategic-number sn-minimum-civilian-explorers 0)
(set-strategic-number sn-wood-gatherer-percentage 0)
(set-strategic-number sn-cap-civilian-explorers 0)
(set-strategic-number sn-percent-civilian-explorers 0)
(disable-self)
)
(defrule
(true)
=>
(set-strategic-number sn-percent-enemy-sighted-response 100)
(set-strategic-number sn-hits-before-alliance-change 25)
(set-difficulty-parameter ability-to-maintain-distance 100)
(set-difficulty-parameter ability-to-dodge-missiles 100)
(set-strategic-number sn-number-explore-groups 0)
(set-strategic-number sn-percent-attack-soldiers 0)
(set-strategic-number sn-task-ungrouped-soldiers 0)
(set-strategic-number sn-number-attack-groups 0)
(set-strategic-number sn-enemy-sighted-response-distance 10)
(set-strategic-number sn-total-number-explorers 0)
(set-strategic-number sn-relic-return-distance 0)
(disable-self)
)
(defrule
(taunt-detected 1 1)
=>
(acknowledge-taunt 1 1)
(set-signal 1)
)
以上是我用AI编辑器弄的一个 不动+数字侦测的AI,
请问是不是0-255都有效?
[此贴子已经被作者于2005-6-10 22:18:06编辑过]
没有人吗? 当然不是,你的脚本中只有一个地方是关于 信息 的:(defrule
(taunt-detected 1 1)
=>
(acknowledge-taunt 1 1)
(set-signal 1)
)就是上面的脚本,它只是实现了信息 1 ,而不是 0 - 255 . 那样怎么才能实现0-255? 是不是应该这样?(defrule
(true)
=>
(set-strategic-number sn-maximum-food-drop-distance 0)
(set-strategic-number sn-maximum-wood-drop-distance 0)
(set-strategic-number sn-maximum-gold-drop-distance 0)
(set-strategic-number sn-maximum-stone-drop-distance 0)
(set-strategic-number sn-maximum-hunt-drop-distance 0)
(set-strategic-number sn-food-gatherer-percentage 0)
(set-strategic-number sn-gold-gatherer-percentage 0)
(set-strategic-number sn-minimum-civilian-explorers 0)
(set-strategic-number sn-wood-gatherer-percentage 0)
(set-strategic-number sn-cap-civilian-explorers 0)
(set-strategic-number sn-percent-civilian-explorers 0)
(disable-self)
)
(defrule
(true)
=>
(set-strategic-number sn-percent-enemy-sighted-response 100)
(set-strategic-number sn-hits-before-alliance-change 25)
(set-difficulty-parameter ability-to-maintain-distance 100)
(set-difficulty-parameter ability-to-dodge-missiles 100)
(set-strategic-number sn-number-explore-groups 0)
(set-strategic-number sn-percent-attack-soldiers 0)
(set-strategic-number sn-task-ungrouped-soldiers 0)
(set-strategic-number sn-number-attack-groups 0)
(set-strategic-number sn-enemy-sighted-response-distance 10)
(set-strategic-number sn-total-number-explorers 0)
(set-strategic-number sn-relic-return-distance 0)
(disable-self)
)
(defrule
(taunt-detected 1 1)
=>
(acknowledge-taunt 1 1)
(set-signal 1)
)defrule
(taunt-detected 2 2)
=>
(acknowledge-taunt 2 2)
(set-signal 2)
)defrule
(taunt-detected 3 3)
=>
(acknowledge-taunt 3 3)
(set-signal 3)
)这样依此类推的写AI? 以前为其他兄弟实现了 0-255 信息了,你可以在这里下载,然后复制里面需要的部分内容到自己的文件里就可以了:<a href="https://www.hawkaoe.net/bbs/viewthread.php?tid=6557" target="_blank" >https://www.hawkaoe.net/bbs/viewthread.php?tid=6557</A> 谢谢卧龙先生了,真不知道该怎么感谢你 兄弟客气了! 有机会请你上馆子大搓特搓一顿 哇~~我拆开了看看,弄这个AI花了你多少时间了卧龙先生? 对了,<a href="https://www.hawkaoe.net/bbs/viewthread.php?tid=6557" target="_blank" ><FONT color=#000000>https://www.hawkaoe.net/bbs/viewthread.php?tid=6557</FONT></A>这个AI里面除了实现 0-255 信息外其他的那些代码是不动AI的代码吗? 中间一部分是失败条件,任一游戏者向玩家进贡1000任意资源时,玩家都会放弃。不需要可以删掉~ <DIV class=quote><B>以下是引用<I>250312431</I>在2005-6-11 12:35:53的发言:</B>
哇~~我拆开了看看,
弄这个AI花了你多少时间了卧龙先生? </DIV>
唔!这个 AI 确实耗了我较多的时间,不过 信息 部分的内容依然不是我一个一个加进去的.
主要是出于正确性的考虑,我抄起 Delphi 用程序(用电脑)一次性搞定的.
至于使用方面的问题是很简单的,你只要复制需要的内容,然后将他们合并在一起就 OK 了. 呵呵,卧龙先生辛苦了.我已经把你的AI用到我的战役里面了,发到百家谈了.先生务必要下载玩玩. 呵呵!
页:
[1]