static void InitUserData(WebData wdata)
{
    int i, j, ns;
    realtype *bcoef, *diff, *cox, *coy, dx, dy;
    realtype (*acoef)[NS];

    acoef = wdata->acoef;
    bcoef = wdata->bcoef;
    diff = wdata->diff;
    cox = wdata->cox;
    coy = wdata->coy;
    ns = wdata->ns = NS;

    for (j = 0; j < NS; j++) {
        for (i = 0; i < NS; i++) acoef[i][j] = 0.;
    }
    for (j = 0; j < NP; j++) {
        for (i = 0; i < NP; i++) {
            acoef[NP+i][j] = EE;
            acoef[i][NP+j] = -GG;
        }
        acoef[j][j] = -AA;
        acoef[NP+j][NP+j] = -AA;
        bcoef[j] = BB;
        bcoef[NP+j] = -BB;
        diff[j] = DPREY;
        diff[NP+j] = DPRED;
    }

    /* Set remaining problem parameters */

    wdata->mxns = MXNS;
    dx = wdata->dx = DX;
    dy = wdata->dy = DY;
    for (i = 0; i < ns; i++) {
        cox[i] = diff[i]/SQR(dx);
        coy[i] = diff[i]/SQR(dy);
    }

    /* Set remaining method parameters */

    wdata->mp = MP;
    wdata->mq = MQ;
    wdata->mx = MX;
    wdata->my = MY;
    wdata->srur = SQRT(UNIT_ROUNDOFF);
    wdata->mxmp = MXMP;
    wdata->ngrp = NGRP;
    wdata->ngx = NGX;
    wdata->ngy = NGY;
    SetGroups(MX, NGX, wdata->jgx, wdata->jigx, wdata->jxr);
    SetGroups(MY, NGY, wdata->jgy, wdata->jigy, wdata->jyr);
}
Beispiel #2
0
        void EnterCombat(Unit* /*who*/)
        {
            _EnterCombat();

            SetGroups();
            SummonGroups();
            CastTeleport();

            if (instance->GetData(DATA_UROM_PLATAFORM) != 3)
                instance->SetData(DATA_UROM_PLATAFORM, instance->GetData(DATA_UROM_PLATAFORM)+1);
        }
Beispiel #3
0
        void EnterCombat(Unit* /*pWho*/)
        {
            if (pInstance)
                pInstance->SetData(DATA_UROM_EVENT, IN_PROGRESS);

            SetGroups();
            SummonGroups();
            CastTeleport();

            if (pInstance && pInstance->GetData(DATA_UROM_PLATAFORM) != 3)
                pInstance->SetData(DATA_UROM_PLATAFORM, pInstance->GetData(DATA_UROM_PLATAFORM)+1);
        }