1. Trouble with the game?
    Try the troubleshooter!

    Dismiss Notice
  2. Issues with the game?
    Check the Known Issues list before reporting!

    Dismiss Notice

Your Personal Micro Blog(s)

Discussion in 'General Discussion' started by tdev, Jan 24, 2015.

  1. SixSixSevenSeven

    SixSixSevenSeven
    Expand Collapse

    Joined:
    Sep 13, 2013
    Messages:
    6,958
    A VAGCOM cannot fully reflash the ECU from scratch, it modifies existing firmware only. VCDS is a debugger only, cannot reflash at all.
     
  2. Zappymouse

    Zappymouse
    Expand Collapse

    Joined:
    Jun 18, 2013
    Messages:
    1,060
    Ah crap, thought you were talking about general OBD jobs. My bad. :|
     
  3. TheAdmiester

    TheAdmiester
    Expand Collapse

    Joined:
    Aug 7, 2012
    Messages:
    579
    The kind of amazing fun stuff I get to work with to add engine swaps to Forza 4.


    (imported from here)

    It's not overly technical or anything, but as you can see from the number of fields - those IDs go from 247000 to 1563000 with very few gaps between - it's a boring, messy pain to work on (but with a satisfying payoff). Thankfully it's all relatively modular so I can cut and throw bits around to make a hacky swap work. Also, the game has no problems or file checks on a larger-than-usual database, so I can work however I want.
     
  4. SixSixSevenSeven

    SixSixSevenSeven
    Expand Collapse

    Joined:
    Sep 13, 2013
    Messages:
    6,958
    Just throw some SQL at it...
     
  5. TheAdmiester

    TheAdmiester
    Expand Collapse

    Joined:
    Aug 7, 2012
    Messages:
    579
    That might be a bit too much of an effort to learn just for this. Editing the tables myself is a big mess but it's "my" big mess, I know what to do and it's almost like a routine.
     
  6. SixSixSevenSeven

    SixSixSevenSeven
    Expand Collapse

    Joined:
    Sep 13, 2013
    Messages:
    6,958
    select * from List_UpgradeEngine where ManufacturerID=49;
     
  7. TheAdmiester

    TheAdmiester
    Expand Collapse

    Joined:
    Aug 7, 2012
    Messages:
    579
    Another thing is the fact that most edits I do only require changing a single field, or adding a new record and only needing to fill in the fields for that. At that point it'd take about the same amount of time writing a script as it would just updating them myself. All I need to do is typically find an ID from a table which I can use the filters for, then use that ID as a reference in a record I make in another table.
     
  8. Dummiesman

    Dummiesman
    Expand Collapse

    Joined:
    Sep 17, 2013
    Messages:
    4,700
    Pretty easy once you learn it :p. I had to memorize it when coding a website

    Code:
    UPDATE [I]List_UpgradeEngine [/I]SET [I]WeightDistDiff[/I]=[I]0[/I],DragScale=[I]0.1[/I] WHERE [I]id[/I]=[I]247000[/I];
     
  9. TheAdmiester

    TheAdmiester
    Expand Collapse

    Joined:
    Aug 7, 2012
    Messages:
    579
    It seems that the tool I'm using to edit tables can also create an SQL file from the database, if for whatever reason you wanted to execute it to build a new copy of it. It does seem extremely simple:

    Code:
    CREATE TABLE [CameraOverrides] ([CarId] INTEGER,[CamFollowLowHeightOffset] REAL,[CamFollowLowRadiusOffset] REAL,[CamFollowLowTargetYOffset] REAL,[CamFollowHighHeightOffset] REAL,[CamFollowHighRadiusOffset] REAL,[CamFollowHighTargetYOffset] REAL,[CamBumperHighHeightOffset] REAL,[CamBumperHighZOffset] REAL,[CamBumperLowHeightOffset] REAL,[CamBumperLowZOffset] REAL,[CamHoodHeightOffset] REAL,[CamHoodZOffset] REAL,[CamHoodPitchOffset] REAL,[CamCockpitOffsetX] REAL,[CamCockpitOffsetY] REAL,[CamCockpitOffsetZ] REAL,[SplitscreenCamCockpitOffsetX] REAL,[SplitscreenCamCockpitOffsetY] REAL,[SplitscreenCamCockpitOffsetZ] REAL,[CockpitWheelPositionOffsetX] REAL,[CockpitWheelPositionOffsetY] REAL,[CockpitWheelPositionOffsetZ] REAL,[CockpitWheelRotationOffset] REAL);
    INSERT INTO `CameraOverrides` VALUES ('260','0.0','0.0','0.0','0.0','0.0','0.0','0.0','0.0','0.0','0.0','0.4','0.03','0.0','0.0','0.2','-0.48','0.0','0.0','0.0','0.0','0.0','0.0','0.0');
    INSERT INTO `CameraOverrides` VALUES ('261','0.0','0.0','0.0','0.0','0.0','0.0','0.0','0.0','0.0','0.0','0.53','-0.03','0.0','0.0','0.17','-0.47','0.0','0.0','0.0','0.0','0.01','0.0','0.0');
    The CREATE line setting all of the column names, and the INSERT lines just putting data into those columns using CSVs. I could probably pick this up very easily, but like I said, in the time it would take to memorise the order of the columns in a table and write a script to put the values in, I could just hit Create New Record and do it myself.
     
  10. SixSixSevenSeven

    SixSixSevenSeven
    Expand Collapse

    Joined:
    Sep 13, 2013
    Messages:
    6,958
    You would never use the create line. It's all already been created. Insert, update, delete and when searching maybe select, only terms you need.
     
  11. SoHigh00

    SoHigh00
    Expand Collapse

    Joined:
    Nov 11, 2013
    Messages:
    506
    B16a2 swap, anyone?
    qwese.JPG
    Fits like it was intentionally made for the covet :p
     
  12. theshark

    theshark
    Expand Collapse

    Joined:
    Aug 5, 2012
    Messages:
    137
    Sooo late to that party, but i couldn't resist:
    Code:
    var operands = {
      "+": function(y,x){ 
      	return x+y
      },
      "-": function(y,x){
      	return x-y;
      },
      "*": function(y,x){
      	return x*y;
      },
      "/": function(y,x){
      	return x/y;
      }
    }
    
    function ReversePolishNotation(str) { 
    
      var stack = [];
      var number = /\d+/;
      str.split(' ').forEach(function(token){
      	if(token.match(number) !== null){
      		stack.push(parseFloat(token));
      	}else{
      		stack.push(operands[token](stack.pop(),stack.pop()));
      	}
      });
      return stack[stack.length-1];       
    }
     
    • Like Like x 1
  13. Zappymouse

    Zappymouse
    Expand Collapse

    Joined:
    Jun 18, 2013
    Messages:
    1,060
    Remove the headlight and place a pod filter there. Now it's a Honda!
     
  14. Bakasan

    Bakasan
    Expand Collapse

    Joined:
    Dec 3, 2013
    Messages:
    1,486
    That would make sense, as the Covet is very similar (dimension wise) to an EF9 Civic, which was available with a B16

    perhaps if you change the valve cover a bit (i.e to make the engine fictional/Ibishu branded) it would be perfect for a Japanese spec Covet
     
  15. TheAdmiester

    TheAdmiester
    Expand Collapse

    Joined:
    Aug 7, 2012
    Messages:
    579
    The create line is there because this is a script that's meant to be run "from nothing". It creates a new database and puts those tables in with their contents.
     
  16. SixSixSevenSeven

    SixSixSevenSeven
    Expand Collapse

    Joined:
    Sep 13, 2013
    Messages:
    6,958
    New table with those rows don't you mean.

    I am familiar with SQL. I know what create does. I even know a workaround to the issue you mention above of having to remember the order of columns when using the update and insert commands (basically you can manually specify which order you are putting data into columns, you don't have to do it in the tables order).
    I just didn't think create has any purpose in the context of forzas database which has all its tables for you already.



    SQL in video games is quite common btw.
     
  17. TheAdmiester

    TheAdmiester
    Expand Collapse

    Joined:
    Aug 7, 2012
    Messages:
    579
    The script I showed was extracted from the database, which I assume would be used as the safest way to make a copy of it. Like I said, it's intended to be run on a database that's either blank or doesn't have the mentioned tables to fill all of those values/columns in. The script is never used by the game, it's just one generated by the program I was using for if I wanted to add the data to a database without those tables. Of course, in that case it does indeed need the create lines, because there would be no tables to put the data into otherwise.
     
    #157 TheAdmiester, Feb 15, 2015
    Last edited: Feb 15, 2015
  18. SoHigh00

    SoHigh00
    Expand Collapse

    Joined:
    Nov 11, 2013
    Messages:
    506
    That's a great Idea...let's take it one step further though, shall we? :)
    yy.JPG
     
    #158 SoHigh00, Feb 18, 2015
    Last edited: Feb 18, 2015
  19. Shadowdragon94

    Shadowdragon94
    Expand Collapse

    Joined:
    Jul 9, 2013
    Messages:
    348
    [content chaught on fire]
     
    #159 Shadowdragon94, Feb 19, 2015
    Last edited: Feb 19, 2015
  20. SixSixSevenSeven

    SixSixSevenSeven
    Expand Collapse

    Joined:
    Sep 13, 2013
    Messages:
    6,958
    Bloody travellers. Their horse is stuck on our land once again
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice