What is hardcoded?

Discussion in 'Closed bugs' started by Urknall, Oct 19, 2014.

  1. Urknall

    Urknall Member

    Messages:
    158
    Likes Received:
    0
    Trophy Points:
    0
    Hey folks,

    which files are hardcoded in Empires and how can I get access to these files? Which software do I need? Any ideas?
     
  2. Grantrithor

    Grantrithor Member

    Messages:
    9,820
    Likes Received:
    11
    Trophy Points:
    0
    What do you mean when you say "hardcoded", if you refer to any source code that will not be in your folders.
     
  3. Urknall

    Urknall Member

    Messages:
    158
    Likes Received:
    0
    Trophy Points:
    0
    Hmmm, it might be source code? I don't know, how these Half Life 2 mods are organized...
     
  4. Trickster

    Trickster Retired Developer

    Messages:
    16,576
    Likes Received:
    46
    Trophy Points:
    0
    Hardcoded means that a value is declared within the sourcecode, rather than being changeable within scripts.
     
  5. ImSpartacus

    ImSpartacus nerf spec plz

    Messages:
    8,597
    Likes Received:
    7
    Trophy Points:
    0
    This particular mod has much of its code in bin/client.dll and bin/server.dll.

    To edit those, you need to edit the source code and recompile. It's tedious and requires a certain amount of technical ability.

    For peasants, certain scripts were used to input parameters to the code. Pretty much everything in the scripts folder gets slurped up by the code.

    You can change shit in the scripts and not have to recompile any code. It makes it easier to iterate and allows less skilled people to participate (*ahem*).

    It might make more sense to go play in the scripts folder. That's what I do.
     
  6. Grantrithor

    Grantrithor Member

    Messages:
    9,820
    Likes Received:
    11
    Trophy Points:
    0
    Well any source code will not be in the client files, the files only have the binaries which is the source code compiled into binary code, the source is usually kept by the dev teams because it's potential intellectual property that they wouldn't want to have stolen. If you know how to program you could probably get on the dev team and have access to it, but I get the feeling you don't yet have the adequate skills.
     
  7. Urknall

    Urknall Member

    Messages:
    158
    Likes Received:
    0
    Trophy Points:
    0
    Ah ok, I understand... is it "open source" or do you/they keep it secret for a commercial future? I mean, are there plans to earn money for it in the next year?
     
  8. complete_

    complete_ lamer

    Messages:
    6,436
    Likes Received:
    144
    Trophy Points:
    0
    it contains steamworks code, which is under nda. also, krenzo is embarrassed by his code
     
  9. Krenzo

    Krenzo Administrator

    Messages:
    3,771
    Likes Received:
    0
    Trophy Points:
    0
    LOL, I'm sure any code in there that I had to be embarrassed about has been replaced by embarrassing Mootant code.
     
  10. ImSpartacus

    ImSpartacus nerf spec plz

    Messages:
    8,597
    Likes Received:
    7
    Trophy Points:
    0
    Shots fired!

    [​IMG]
     
  11. Z100000M

    Z100000M Vithered Weteran

    Messages:
    9,120
    Likes Received:
    70
    Trophy Points:
    0
    hows the LE(D)GO project these days?
     
  12. Fricken Hamster

    Fricken Hamster Mr. Super Serious

    Messages:
    3,619
    Likes Received:
    2
    Trophy Points:
    0
    I remember that one disgusting snippet that dealt with vectors when placing walls
     
  13. Grantrithor

    Grantrithor Member

    Messages:
    9,820
    Likes Received:
    11
    Trophy Points:
    0
    Like complete_ said it has Steamworks code that valve doesn't want all over the internet. Also people have made arguments on why Open Source wouldn't be optimal, and it's been argued to death, but that's not mine to argue.
     
  14. Lazybum

    Lazybum :D Staff Member Moderator

    Messages:
    4,823
    Likes Received:
    190
    Trophy Points:
    0
    I do suppose for some super basic stuff you could download the 2013 source code from the git hub and try to make rough guess of what's happening. Though I remember hearing a lot of code was actually made up because they didn't know source could do it already, or wasn't capable of doing what they wanted.

    So unless you really know what you are doing I don't think that would help at all, unless you wanted to make some map entity. You'd have to ask whoever to put it in, but they would also have to make sure it works with whatever empires does.
     
    Last edited: Oct 20, 2014
  15. Krenzo

    Krenzo Administrator

    Messages:
    3,771
    Likes Received:
    0
    Trophy Points:
    0
    Oh yeah, I didn't have the internet or access to any reference books when I was writing most of Empires 1.0 (I was in the middle of the Pacific Ocean), and that's one case I remember I couldn't look up how to convert degrees to radians and had to figure it out on my own.

    There's a lot of shitty code out in the world. Most of the time you can't even fix it because you're told that there's no return on investment for refactoring the code.
     
  16. ImSpartacus

    ImSpartacus nerf spec plz

    Messages:
    8,597
    Likes Received:
    7
    Trophy Points:
    0
    That's pretty heartbreaking. I've always wondered how much refactoring actually takes place in a project that has to make money.
     
  17. Candles

    Candles CAPTAIN CANDLES, DUN DUN DUN, DUN DUN DUN DUN.

    Messages:
    4,251
    Likes Received:
    10
    Trophy Points:
    0
    Depends on how maintainable it needs to be. If it's a release-and-move-on kinda' product, not much. Long-term it becomes much more important though.
     
  18. BigTeef

    BigTeef Bootleg Headshot master

    Messages:
    7,036
    Likes Received:
    36
    Trophy Points:
    0
    Thankfully candles is autistic enough to figure it out.
     
    Last edited: Oct 20, 2014
  19. f1r3w4rr10r

    f1r3w4rr10r Modeler

    Messages:
    2,475
    Likes Received:
    4
    Trophy Points:
    0
  20. Fricken Hamster

    Fricken Hamster Mr. Super Serious

    Messages:
    3,619
    Likes Received:
    2
    Trophy Points:
    0
    Most products nowadays are sold as a service, so it'll be maintained more often than not.
     

Share This Page