Beiträge von Disane87

Due to human (non-bot) spam the first contribution of a user has to be reviewed and activated manually, all further contributions do not require this.
As long as a user does not have at least one reviewed and activated contribution, the user is unable to edit his profile, set a avatar, title picture or a signature.

    Hello all,
    currently I'm building housing planner (to plan houses with different block types and calculate the costs) and now I want to get all craftable types of block to put them into my planner. You can see the current status of the planner here: https://eco-pixel-grid.stackblitz.io

    I get all Items within the group "Block Items":

    C#
    var Items = Eco.Gameplay.Items.BlockItem.AllItems.ToList();
    
    
    Items.ForEach(x=>{
        if(x.Group == "Block Items"){
            Logger.Debug($"{x.FriendlyName}: {x.Category}");
        }
    });

    The output will be like this:

    "Log"


    [12:58:26] DISCORDBRIDGE DEBUG: Asphalt Road: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Barrel: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Biodiesel: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Brick: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Coal: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Copper Ore: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Copper Pipe: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Corrugated Steel: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Dirt: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Flat Steel: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Framed Glass: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Garbage: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Gasoline: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Glass: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Gold Ore: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Hewn Log: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Iron Ore: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Iron Pipe: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Log: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Lumber: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Mortared Stone: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Petroleum: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Reinforced Concrete: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Sand: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Sewage: Hidden
    [01:01:00] DISCORDBRIDGE DEBUG: Steel Pipe: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Stone: _None
    [01:01:00] DISCORDBRIDGE DEBUG: Stone Road: _None

    But as you can see, there are several block types which can't be crafted, like dirt or Iron Ore. I've already debugged the items but I don't find any property like "craftable" which I can check. Additionally I want to get the ingredients of that block to get this crafted (and the amount) to calculate an average in game price for one selected block.

    The base of the calculation will be one log item (which I guess is the most basis ingredient of all craftable blocks) with a configurable price.
    Does anybody of you has an advice to get this done?

    In short: I want a recursive list of all blocks that can be created with the corresponding ingredients to calculate an avarage price.

    I got it :) Not the best approach but it's okay for the first try:

    @mampf That's a good way to debug the mod, I was using another method which is more time consuming then that.

    What I did is use dev tier to load server in debug mode etc, but I prefer what you posted here and will be using this to debug my mods from now on, Thanks!!


    This is pretty good imho and works like a charm.
    [automerge]1539162407[/automerge]
    Just got it working with vscode flawlessly :) A bit tricky but vscode is prefered by me:

    After a successfull login I get a summary of the changes in the world (new plants/animals) which I want to use to post this into our discord channel.
    For this I guess I can use [ICODE]Eco.Stats.OrganismStats.GetPopulationStats()[/ICODE] is this correct?

    Aftet that I want to iterate over this with a list and create a string for that to push it to discord, but currently the string is always empty. Am I missing something?

    @Kronox Thank you for your detailed feedback and thoughts about this. As I profiled the traffic between webUI and server, there is a „public“ rest api which feeds the webUI with data and is the bridge between the entire law system and the server.

    I think it could be possible too, but I don‘t feel very comfortable with replacing files manually. I guess there could be a better solution for hooking into this process. But your assumptions pushed me into the right direction I think.

    The intension of the project is to have a game database on my own homepage for the server runs to run some fancy statistics stuff and so on.

    I‘ll keep you in touch with the project :P

    Hey guys,
    I'm pretty new to modding but I'm developing at a professional level since 10 years, So now I want to combine my hobby (eco) and my profession and want to write some mods - or getting started with it.

    Actuall I want to visualize some information about the world via a homepage of my server. As I saw, the webpage of eco is using an "internal" RESTful-API to get the data. Is there any chance to enhance it? Is there a WebAPI behind ist via .NET-Core or something else?