c++ mir2x sound enabled

ventus

LOMCN Veteran
Veteran
Oct 17, 2013
926
132
105
Very interesting o_O Will take a look , thanks for sharing.

Wow that interface brings back memories. Items actually saving in shops, this maybe what the mir3 community has been looking for.

What else needs to be completed?
 
Last edited:

quanzhou

Loyal Member
Loyal Member
Aug 21, 2017
16
12
15
Very interesting o_O Will take a look , thanks for sharing.

Wow that interface brings back memories. Items actually saving in shops, this maybe what the mir3 community has been looking for.

What else needs to be completed?
NPC scripts.
Currently I use lua to setup NPC interactions.
I don't have any experience how to design NPC system, this is a newbie product.

mainly each NPC has a lua table named ```processNPCEvent```, which is a string->function table.
client post string which triggers functions in the table, when player click items on menu, it posts strings.

Inside the funtion script can call builtin functions for NPC logic, this is the way to extend the NPC.
like getUserGold(), getUserName() etc, and when NPC wants to install triggers to player, they can just install lua script on player instance.

It needs to implement all these NPC logic one by one.
Takes time.

Other like minor bug fix is long time work.
I will not rush.

Python:
local dq = require('npc.include.dailyquest')
processNPCEvent =
{
    [SYS_NPCINIT] = function(uid, value)
        uidPostXML(uid,
        [[
            <layout>
                <par>江湖上的朋友都叫我万拍子,不是我吹,你不了解的任务我都可以给你解答。你有什么想问的吗?</par>
                <par></par>
                <par><event id="npc_goto_1">询问一般的任务</event></par>
                <par><event id="npc_goto_2">对今日的任务进行了解</event></par>
                <par><event id="%s">结束</event></par>
            </layout>
        ]], SYS_NPCDONE)
    end,

    ["npc_goto_1"] = function(uid, value)
        uidPostXML(uid,
        [[
            <layout>
                <par>来吧,你有什么任务?</par>
                <par><event id="npc_goto_3">乞丐任务</event>,<event id="npc_goto_4">苍蝇拍任务</event>,<event id="npc_goto_5">石罂粟任务</event></par>
                <par></par>
                <par>(等级 9)</par>
                <par><event id="npc_goto_6">王大人任务</event>,<event id="npc_goto_7">比奇省任务</event>,<event id="npc_goto_8">药剂师任务</event></par>
                <par></par>
                <par>(等级 11)</par>
                <par><event id="npc_goto_9">轻型盔甲任务</event>,<event id="npc_goto_10">半兽人任务</event></par>
                <par></par>
                <par>(等级 16)</par>
                <par><event id="npc_goto_11">被盗的灵魂任务</event>,<event id="npc_goto_12">千年毒蛇任务</event>,<event id="npc_goto_13">堕落道士任务</event></par>
                <par></par>
                <par>(等级 20)</par>
                <par><event id="npc_goto_14">沃玛教主任务</event></par>
                <par></par>
                <par><event id="%s">前一步</event></par>
                <par><event id="%s">关闭</event></par>
            </layout>
        ]], SYS_NPCINIT, SYS_NPCDONE)
    end,

    ["npc_goto_2"] = function(uid, value)
        dq.setQuest(0, uid, value)
    end
}
 
  • Like
Reactions: ventus