Marketplace on census

Discussion in 'Census: EverQuest II' started by Chillispike, Oct 12, 2017.

  1. Chillispike

    Chillispike New Member

    The marketpalce prices are on census as well.

    There are 3 different prices:
    1. 'normal_cost' = daybreak cash
    2. 'alt_currency_cost' = x Amount of the different currency like loyality tokens with "'alt_currency_id'" gives the item of the alt currency
    3. 'cost_override_text' = for other texts .. like "Free"


    My code to get the price of it is:

    Code:
    for c1 := 0 to childnodes.Count-1 do
        begin inc(sc);
              if (VarToStr(ChildNodes[c1].Attributes['normal_cost'])='') or (VarToStr(ChildNodes[c1].Attributes['normal_cost'])='0')
                 then normal_cost:='NULL'
                 else normal_cost:=ChildNodes[c1].Attributes['normal_cost'];
              if (VarToStr(ChildNodes[c1].Attributes['alt_currency_cost'])='') or (VarToStr(ChildNodes[c1].Attributes['alt_currency_cost'])='0')
                 then alt_currency_cost:=''
                 else alt_currency_cost:=ChildNodes[c1].Attributes['alt_currency_cost'];
                 
              if (normal_cost='NULL') and (alt_currency_cost='')
                 then begin if VarToStr(ChildNodes[c1].Attributes['cost_override_text'])<>''
                               then updateobtainmarket(ChildNodes[c1].Attributes['id'],'NULL','ยง'+ChildNodes[c1].Attributes['cost_override_text']);
                      end
                 else begin if alt_currency_cost<>''
                               then begin if alt_currency_cost='1'
                                             then updateobtainmarket(ChildNodes[c1].Attributes['id'],normal_cost,ChildNodes[c1].Attributes['alt_currency_id']+'#')
                                             else updateobtainmarket(ChildNodes[c1].Attributes['id'],normal_cost,alt_currency_cost+'x'+ChildNodes[c1].Attributes['alt_currency_id']+'#');
                                    end
                               else updateobtainmarket_noalt(ChildNodes[c1].Attributes['id'],normal_cost);
                      end;
        end;
    
     
  2. Feldon

    Feldon Administrator Staff Member

  3. Chillispike

    Chillispike New Member

    Normaly i try to figure it myself first .. helps me to write the code as well and then i fiddle around with it :D
     
  4. Feldon

    Feldon Administrator Staff Member

    Sounds painful. :) It's taken a lot of hours but I have been happy to write the documentation I have for EQ2 Census if other people can use it.
     
    • Like Like x 2

Share This Page