Author Topic: Been Wondering Whats Going on with Project Q?  (Read 989 times)

Legacy_Pstemarie

  • Hero Member
  • *****
  • Posts: 4368
  • Karma: +0/-0
Been Wondering Whats Going on with Project Q?
« Reply #45 on: May 10, 2014, 05:35:54 pm »


               

Question for Q Users...I'm getting tired of maintaining two separate projects and was wondering how Q users would feel if I rolled my Personal HAK Collection into Project Q ?


 


Look the stuff over (if you want) and let me know what you think - link is my sig. There would be no external requirements as listed on the download page to use Project Q. I'd jsut be rolling in the stuff that wasn't dependent upon work. 


 


I've put a poll up on the Q site - HERE



               
               

               
            

Legacy_boodah83

  • Full Member
  • ***
  • Posts: 247
  • Karma: +0/-0
Been Wondering Whats Going on with Project Q?
« Reply #46 on: May 10, 2014, 05:57:30 pm »


               

That would be just awesome! Though I'd really love to see the reworked Cave/Mines tileset rolled into it as well, if Zwerkules would be cool with it and nobody else objects.


 


Btw, never got around to comment on it, but I really like the idea of the world map tileset with the associated placeables and hope you'll continue working on that.



               
               

               
            

Legacy_MannyJabrielle

  • Sr. Member
  • ****
  • Posts: 275
  • Karma: +0/-0
Been Wondering Whats Going on with Project Q?
« Reply #47 on: May 11, 2014, 04:36:05 am »


               


Simplified script. Try this please and let me know if it works for you...



//:://////////////////////////////////////////////
//:: Created By: Pstemarie
//:: Created On: 5/9/2014
//:://////////////////////////////////////////////
void main()
{
    object  oPC     = GetItemActivator();
    int     iSex    = GetGender(oPC);
    int     iRace   = GetAppearanceType(oPC);
    int     nEffect;
 
    if(GetLocalInt(oPC,"USEDQITMASK") == 1)
    {
        SetLocalInt(oPC,"USEDQITMASK",0);
        effect eEff = GetFirstEffect(oPC);
        while(GetIsEffectValid(eEff) == TRUE)
        {
            if(GetEffectType(eEff) == EFFECT_TYPE_VISUALEFFECT)
            {
                RemoveEffect(oPC,eEff);
            }
            eEff = GetNextEffect(oPC);
        }
        return;
    }
 
    SetLocalInt(oPC,"USEDQITMASK",1);
 
    switch (iSex)
    {
        case GENDER_MALE:
        {
            switch (iRace)
            {
                case APPEARANCE_TYPE_HALFLING: nEffect = 738; break;
                case APPEARANCE_TYPE_DWARF: nEffect = 740; break;
                case APPEARANCE_TYPE_ELF: nEffect = 742; break;
                case APPEARANCE_TYPE_HUMAN:
                case APPEARANCE_TYPE_HALF_ELF: nEffect = 744; break;
                case APPEARANCE_TYPE_HALF_ORC: nEffect = 746; break;
            }
        }
        break;
 
        case GENDER_FEMALE:
        {
            switch (iRace)
            {
                case APPEARANCE_TYPE_HALFLING: nEffect = 739; break;
                case APPEARANCE_TYPE_DWARF: nEffect = 741; break;
                case APPEARANCE_TYPE_ELF: nEffect = 743; break;
                case APPEARANCE_TYPE_HUMAN:
                case APPEARANCE_TYPE_HALF_ELF: nEffect = 745; break;
                case APPEARANCE_TYPE_HALF_ORC: nEffect = 747; break;
            }
        }
        break;
    }
    ApplyEffectToObject(DURATION_TYPE_PERMANENT,EffectVisualEffect(nEffect),oPC);
    return;
}



 


Tried out the script.  Didn't work very well. Glanced over it and noticed a few typos.  Numbers not pointing to the correct vfx for several, no gnomes at all (poor short guys), and no eEff number for the human cases.


I fixed up the sex/racial appearance cases part of the script:


 



case GENDER_MALE:
        {
            switch (iRace)
            {
                case APPEARANCE_TYPE_HALFLING: nEffect = 738; break;
                case APPEARANCE_TYPE_DWARF: nEffect = 740; break;
                case APPEARANCE_TYPE_ELF: nEffect = 742; break;
                case APPEARANCE_TYPE_GNOME: nEffect = 744; break;
                case APPEARANCE_TYPE_HUMAN: nEffect = 746; break;
                case APPEARANCE_TYPE_HALF_ELF: nEffect = 746; break;
                case APPEARANCE_TYPE_HALF_ORC: nEffect = 748; break;
            }
        }
        break;

        case GENDER_FEMALE:
        {
            switch (iRace)
            {
                case APPEARANCE_TYPE_HALFLING: nEffect = 739; break;
                case APPEARANCE_TYPE_DWARF: nEffect = 741; break;
                case APPEARANCE_TYPE_ELF: nEffect = 743; break;
                case APPEARANCE_TYPE_GNOME: nEffect = 745; break;
                case APPEARANCE_TYPE_HUMAN: nEffect = 747; break;
                case APPEARANCE_TYPE_HALF_ELF: nEffect = 747; break;
                case APPEARANCE_TYPE_HALF_ORC: nEffect = 749; break;
            }
        }
        break;


I also noticed that the effect removal section has the side effect of removing *all* effects.  Granted the mask could be seen as just a demo-piece and this script not so important, but would probably be nice for module builders who toss the mask in somewhere their module to not have it muck up players who had just buffed with all their spells and such and shortly after decided they didn't wanna oogabooga the gobbies anymore.


 


Perhaps set the mask effect to a 24 game hour duration and skip the whole removing of all effects from the PC?  Or is there a way to remove a specific non-spell vfx?


Thinking about it for a moment more, maybe setup defining the constants for the mask vfx, TAD's tiki mask vfx, and whatever other VFX's builders may add into their own modules?  Could even be useful for a seamless intergration of the community vfx package, allowing effects to be quickly added in, allow applying/removing them without disturbing regular spell vfx's and such?  I could put together something for that if you are interested.


               
               

               
            

Legacy_Rolo Kipp

  • Hero Member
  • *****
  • Posts: 4349
  • Karma: +0/-0
Been Wondering Whats Going on with Project Q?
« Reply #48 on: May 11, 2014, 04:57:00 am »


               <rummaging around... >


I have proposed just such a system with the CVP.

It's a new 2da called phenovfx. 2da and it lists the name of the vfx and the starting index in visualeffects.2da

It does,  however,  rely on visual effects being listed in the same order that getrace() returns,  which is a different order from many systems used currently.


<... for the index to the catalog>
               
               

               
            

Legacy_MannyJabrielle

  • Sr. Member
  • ****
  • Posts: 275
  • Karma: +0/-0
Been Wondering Whats Going on with Project Q?
« Reply #49 on: May 11, 2014, 05:30:57 am »


               

I noticed that the Q masks are ordered a little differently myself in the visualeffects.2da when I put together a short little script to easily handle applying any VFX's.... it wouldn't do the q masks right because of the ordering....


Maybe go ahead with the 2da idea?  If anyone wants onboard with making their work compatible, they would have to use the ordering method... if not, oh well?


Or... do you mean "other systems" in a context I'm missing?



               
               

               
            

Legacy_Pstemarie

  • Hero Member
  • *****
  • Posts: 4368
  • Karma: +0/-0
Been Wondering Whats Going on with Project Q?
« Reply #50 on: May 11, 2014, 11:11:51 am »


               


SNIP




 


Sorry about the typos - when I missed the Gnomes it set all the remaining numbers off by one. Also, since the case APPEARANCE_TYPE_HUMAN statement doesn't have a break, it becomes part of the next case statement with a break - just trying to save some data.


 


Dispelling of all visual effects should be fixed now too.



//:://////////////////////////////////////////////
//:: Created By: Pstemarie
//:: Created On: 5/9/2014
//:://////////////////////////////////////////////
void main()
{
    object oPC     = GetItemActivator();
    object oItem   = GetItemActivated();
    int    iSex    = GetGender(oPC);
    int    iRace   = GetAppearanceType(oPC);
    int    nEffect;
    string sItem;
 
    if(GetLocalInt(oPC,"USEDQITMASK") == 1)
    {
        SetLocalInt(oPC,"USEDQITMASK",0);
        sItem = GetLocalString(oPC, "QITMASK_ID");
        effect eEff = GetFirstEffect(oPC);
        while(GetIsEffectValid(eEff) == TRUE)
        {
            if(GetEffectType(eEff) == EFFECT_TYPE_VISUALEFFECT && GetTag(GetEffectCreator(eEff)) == sItem)
            {
                RemoveEffect(oPC,eEff);
            }
            eEff = GetNextEffect(oPC);
        }
        DeleteLocalString(oPC,"USEDQITMASK");
        return;
    }
 
    SetLocalInt(oPC,"USEDQITMASK",1);
    SetLocalString(oPC, "QITMASK_ID", GetTag(oItem));
 
    switch (iSex)
    {
        case GENDER_MALE:
        {
            switch (iRace)
            {
                case APPEARANCE_TYPE_HALFLING: nEffect = 738; break;
                case APPEARANCE_TYPE_DWARF: nEffect = 740; break;
                case APPEARANCE_TYPE_ELF: nEffect = 742; break;
                case APPEARANCE_TYPE_GNOME: nEffect = 744; break;
                case APPEARANCE_TYPE_HUMAN:
                case APPEARANCE_TYPE_HALF_ELF: nEffect = 746; break;
                case APPEARANCE_TYPE_HALF_ORC: nEffect = 748; break;
            }
        }
        break;
 
        case GENDER_FEMALE:
        {
            switch (iRace)
            {
                case APPEARANCE_TYPE_HALFLING: nEffect = 739; break;
                case APPEARANCE_TYPE_DWARF: nEffect = 741; break;
                case APPEARANCE_TYPE_ELF: nEffect = 743; break;
                case APPEARANCE_TYPE_GNOME: nEffect = 745; break;
                case APPEARANCE_TYPE_HUMAN:
                case APPEARANCE_TYPE_HALF_ELF: nEffect = 747; break;
                case APPEARANCE_TYPE_HALF_ORC: nEffect = 749; break;
            }
        }
        break;
    }
    ApplyEffectToObject(DURATION_TYPE_PERMANENT,EffectVisualEffect(nEffect),oPC);
    return;
}


               
               

               
            

Legacy_MannyJabrielle

  • Sr. Member
  • ****
  • Posts: 275
  • Karma: +0/-0
Been Wondering Whats Going on with Project Q?
« Reply #51 on: May 11, 2014, 08:00:38 pm »


               

Ooooh, never knew that about cases.


 


Thank you '<img'>