Chessking

Forum Replies Created

Viewing 15 posts - 91 through 105 (of 782 total)
  • Author
    Posts
  • in reply to: IronDuke’s Patch #18623
    Chessking
    Participant

    I think you are right. Beauty shots overrides the files as well, on top of your mod. All I have to do to test the interceptor is copy the .ini from your mod into Beauty Shots. I guess I got a bit confused about how I-war works because I haven’t been modding files for so long.

    After putting your .ini in Beauty Shots, the patcom indeed has two PBCs. However, they are not linked. I have to hit enter to fire the other PBC. Can you explain this?

    Also, I was going to mention I found another bug. Start the game and fly the ComSec. Go into external view. Strafe right, and all of the air-thrusters for both left and right will fire. Strafe left, and none of them will. The same issue is apparent with the other directions of motion.


    This is one tough navy, boy. They don’t give you time off, even for being dead. -Clay

    Storm Petrel

    in reply to: IronDuke’s Patch #19554
    Chessking
    Participant

    I think you are right. Beauty shots overrides the files as well, on top of your mod. All I have to do to test the interceptor is copy the .ini from your mod into Beauty Shots. I guess I got a bit confused about how I-war works because I haven’t been modding files for so long.

    After putting your .ini in Beauty Shots, the patcom indeed has two PBCs. However, they are not linked. I have to hit enter to fire the other PBC. Can you explain this?

    Also, I was going to mention I found another bug. Start the game and fly the ComSec. Go into external view. Strafe right, and all of the air-thrusters for both left and right will fire. Strafe left, and none of them will. The same issue is apparent with the other directions of motion.


    This is one tough navy, boy. They don’t give you time off, even for being dead. -Clay

    Storm Petrel

    in reply to: IronDuke’s Patch #18620
    Chessking
    Participant

    So I am working on testing the mod. And so far, I haven’t found anything different. Here is how I am testing it. I have your mod, Multimod, and Beuuty Shots in the mods folder. Beauty Shots is set to display the Carrier. I launch Beauty Shots with your mod active, and the turret on the back of the carrier is still upside down. Also, I set Beauty Shots to display the Navy Guillotine Destroyer, and launch it with your mod active, and the collisionhull is still too small. Same with the police interceptor; it still has one PBC. I must be missing something, but what is it? It could be a problem with Beauty Shots, but I can’t spend more time testing that right now.


    This is one tough navy, boy. They don’t give you time off, even for being dead. -Clay

    Storm Petrel

    in reply to: IronDuke’s Patch #19552
    Chessking
    Participant

    So I am working on testing the mod. And so far, I haven’t found anything different. Here is how I am testing it. I have your mod, Multimod, and Beuuty Shots in the mods folder. Beauty Shots is set to display the Carrier. I launch Beauty Shots with your mod active, and the turret on the back of the carrier is still upside down. Also, I set Beauty Shots to display the Navy Guillotine Destroyer, and launch it with your mod active, and the collisionhull is still too small. Same with the police interceptor; it still has one PBC. I must be missing something, but what is it? It could be a problem with Beauty Shots, but I can’t spend more time testing that right now.


    This is one tough navy, boy. They don’t give you time off, even for being dead. -Clay

    Storm Petrel

    in reply to: Preferred developing language #19526
    Chessking
    Participant

    I agree, this conversation has been somewhat off topic. I never considered using PM for the conversation, and I am sorry for that. However, my massive “post to solve all of IronyMan’s problems” would have exceeded the character limit anyways. 😛

    Yeah Chessking, let me know if/when you want to do something. I won’t have much to do this summer besides playing games.

    I wish I had that problem. In addition to the things I already have to do, I will be turning eighteen this summer… Anyways, take a look through my programs and see if anything interests you.

    Don’t worry, I’ll shut up now. :whistle:


    This is one tough navy, boy. They don’t give you time off, even for being dead. -Clay

    Storm Petrel

    in reply to: Preferred developing language #18559
    Chessking
    Participant

    I agree, this conversation has been somewhat off topic. I never considered using PM for the conversation, and I am sorry for that. However, my massive “post to solve all of IronyMan’s problems” would have exceeded the character limit anyways. 😛

    Yeah Chessking, let me know if/when you want to do something. I won’t have much to do this summer besides playing games.

    I wish I had that problem. In addition to the things I already have to do, I will be turning eighteen this summer… Anyways, take a look through my programs and see if anything interests you.

    Don’t worry, I’ll shut up now. :whistle:


    This is one tough navy, boy. They don’t give you time off, even for being dead. -Clay

    Storm Petrel

    in reply to: Preferred developing language #19523
    Chessking
    Participant

    I see it! Good luck with your future progress on this program.

    Strange… It won’t let me go to your new account’s profile.

    That was fun! I would like to collaborate on some more projects sometime. On Khan Academy, of course, not here.


    This is one tough navy, boy. They don’t give you time off, even for being dead. -Clay

    Storm Petrel

    in reply to: Preferred developing language #18554
    Chessking
    Participant

    I see it! Good luck with your future progress on this program.

    Strange… It won’t let me go to your new account’s profile.

    That was fun! I would like to collaborate on some more projects sometime. On Khan Academy, of course, not here.


    This is one tough navy, boy. They don’t give you time off, even for being dead. -Clay

    Storm Petrel

    in reply to: Preferred developing language #18550
    Chessking
    Participant

    But if you create a new profile, you won’t have your own username for that profile. 🙁
    My research has not revealed anything indicating that this has occurred before. I would suggest you copy the program’s code into a new program and save it again, then see if it shows up when you are logged out.

    Edit: perhaps your account got disconnected from your Google account or something like that.

    Also, I am glad you found my post helpful. I try to make my explanations as clear as possible, but rarely get feedback telling me whether I succeeded.


    This is one tough navy, boy. They don’t give you time off, even for being dead. -Clay

    Storm Petrel

    in reply to: Preferred developing language #19521
    Chessking
    Participant

    But if you create a new profile, you won’t have your own username for that profile. 🙁
    My research has not revealed anything indicating that this has occurred before. I would suggest you copy the program’s code into a new program and save it again, then see if it shows up when you are logged out.

    Edit: perhaps your account got disconnected from your Google account or something like that.

    Also, I am glad you found my post helpful. I try to make my explanations as clear as possible, but rarely get feedback telling me whether I succeeded.


    This is one tough navy, boy. They don’t give you time off, even for being dead. -Clay

    Storm Petrel

    in reply to: Preferred developing language #19516
    Chessking
    Participant

    The link still doesn’t work for me. Perhaps something in your account settings does not let other people view your programs? I’m not sure. Perhaps if you give me the link to your profile, rather than a specific program, that will work.

    I know what your problem is. Here is the code starting at line 172. I added the rotation variable and the two println() statements for debugging purposes.
    if (char.inship === true && control.occupied === true) {
    char.a = control.a;
    var rotation = atan2(mouseY-width/2,mouseX-height/2)-90;
    println(rotation);
    println(control.a);
    if (keys[SHIFT]) {
    if (control.a < atan2(mouseY-width/2,mouseX-height/2)-90) { control.a += control.agility; } if (control.a > atan2(mouseY-width/2,mouseX-height/2)-90) {
    control.a -= control.agility;
    }

    }
    Plug this code into your program and you will see the problem. At the left hand side, the rotation variable switches from 270 to -90, which obviously affects whether control.a is greater than or less than the mouse angle.

    To solve this, we need to designate an optimal situation. We can do this in the form of an IPO (input, processing, output) chart. The inputs are the ship rotation, and the mouse rotation to the center of the screen. I think the desired output should be the angle between these two angles. When the ship is facing the mouse, the output should be 0. As the mouse moves clockwise around the ship, the angle should increase, reaching 180 behind the ship. As the mouse moves counter-clockwise around the ship, the angle should decrease, reaching -180 behind the ship. The switching point between positive and negative angles should always be behind the ship.

    The final stage is the processing stage. How do we get from input to output? First, we define a variable for each input. We already have control.a defined, so lets add var rotation = atan2(mouseY-height/2,mouseX-width/2); for the mouse angle.

    Now, let’s say the ship is rotated 100 degrees, and is facing the pointer. Both input variables will be the same. If we subtract control.a from rotation, the angle will be 0 whenever the ship is facing the pointer.
    var rotation = atan2(mouseY-height/2,mouseX-width/2)-control.a;
    Now, not only is rotation 0 when the ship is facing the mouse, but the angle increases as the mouse moves clockwise around the ship, and decreases when the mouse moves counterclockwise around the ship, reaching -180 behind the ship. However, the number continues to decrease beyond that point, until it switches to a positive number at the left.

    To fix this, all we have to do is add 360 to var rotation when rotation is less than -180. At the same time, we should subtract 360 when rotation is greater than 180.
    if(rotation >= 180) {
    rotation -= 360;
    }else if(rotation < -180) { rotation += 360; }

    I originally used a while loop instead of an if statement, because the manual rotation of the ship allows control.a to reach values much higher than 180, 360, or even 1000. However, I then discovered this section of code in your program:
    if (control.a > 360) {
    control.a = 0;
    }

    This solves the problem if control.a reaches high values, but not if it reaches low values. So I would suggest changing it to this:
    if (control.a >= 360) {
    control.a = 0;
    }
    if (control.a < 0) { control.a = 360; }

    Edit: I forgot to mention, you need this code to utilize the output.
    if (keys[SHIFT]) {
    if(rotation > 0) {
    control.a += control.agility;
    }
    if(rotation < 0) { control.a -= control.agility; } }

    Now, everything should be working properly.

    For clarity, here is the entire fixed program: program.
    I hope this helps!

    P.S. Because var rotation is larger the further your mouse angle is from the angle of the ship, you could tell the ship to rotate faster or slower as well.

    P.P.S. The ship will vibrate around its focal point. This is because var rotation is not being updated when control.a is being updated during the execution stage (the code shown in my edit). The code below fixes the problem, albeit not very efficiently.
    if (keys[SHIFT]) {
    if(rotation > 0) {
    control.a += control.agility;
    }
    var rotation = atan2(mouseY-height/2,mouseX-width/2)-control.a;
    if(rotation >= 180) {
    rotation -= 360;
    }
    if(rotation < -180) { rotation += 360; } if(rotation < 0) { control.a -= control.agility; } }


    This is one tough navy, boy. They don’t give you time off, even for being dead. -Clay

    Storm Petrel

    in reply to: Preferred developing language #18541
    Chessking
    Participant

    The link still doesn’t work for me. Perhaps something in your account settings does not let other people view your programs? I’m not sure. Perhaps if you give me the link to your profile, rather than a specific program, that will work.

    I know what your problem is. Here is the code starting at line 172. I added the rotation variable and the two println() statements for debugging purposes.
    if (char.inship === true && control.occupied === true) {
    char.a = control.a;
    var rotation = atan2(mouseY-width/2,mouseX-height/2)-90;
    println(rotation);
    println(control.a);
    if (keys[SHIFT]) {
    if (control.a < atan2(mouseY-width/2,mouseX-height/2)-90) { control.a += control.agility; } if (control.a > atan2(mouseY-width/2,mouseX-height/2)-90) {
    control.a -= control.agility;
    }

    }
    Plug this code into your program and you will see the problem. At the left hand side, the rotation variable switches from 270 to -90, which obviously affects whether control.a is greater than or less than the mouse angle.

    To solve this, we need to designate an optimal situation. We can do this in the form of an IPO (input, processing, output) chart. The inputs are the ship rotation, and the mouse rotation to the center of the screen. I think the desired output should be the angle between these two angles. When the ship is facing the mouse, the output should be 0. As the mouse moves clockwise around the ship, the angle should increase, reaching 180 behind the ship. As the mouse moves counter-clockwise around the ship, the angle should decrease, reaching -180 behind the ship. The switching point between positive and negative angles should always be behind the ship.

    The final stage is the processing stage. How do we get from input to output? First, we define a variable for each input. We already have control.a defined, so lets add var rotation = atan2(mouseY-height/2,mouseX-width/2); for the mouse angle.

    Now, let’s say the ship is rotated 100 degrees, and is facing the pointer. Both input variables will be the same. If we subtract control.a from rotation, the angle will be 0 whenever the ship is facing the pointer.
    var rotation = atan2(mouseY-height/2,mouseX-width/2)-control.a;
    Now, not only is rotation 0 when the ship is facing the mouse, but the angle increases as the mouse moves clockwise around the ship, and decreases when the mouse moves counterclockwise around the ship, reaching -180 behind the ship. However, the number continues to decrease beyond that point, until it switches to a positive number at the left.

    To fix this, all we have to do is add 360 to var rotation when rotation is less than -180. At the same time, we should subtract 360 when rotation is greater than 180.
    if(rotation >= 180) {
    rotation -= 360;
    }else if(rotation < -180) { rotation += 360; }

    I originally used a while loop instead of an if statement, because the manual rotation of the ship allows control.a to reach values much higher than 180, 360, or even 1000. However, I then discovered this section of code in your program:
    if (control.a > 360) {
    control.a = 0;
    }

    This solves the problem if control.a reaches high values, but not if it reaches low values. So I would suggest changing it to this:
    if (control.a >= 360) {
    control.a = 0;
    }
    if (control.a < 0) { control.a = 360; }

    Edit: I forgot to mention, you need this code to utilize the output.
    if (keys[SHIFT]) {
    if(rotation > 0) {
    control.a += control.agility;
    }
    if(rotation < 0) { control.a -= control.agility; } }

    Now, everything should be working properly.

    For clarity, here is the entire fixed program: program.
    I hope this helps!

    P.S. Because var rotation is larger the further your mouse angle is from the angle of the ship, you could tell the ship to rotate faster or slower as well.

    P.P.S. The ship will vibrate around its focal point. This is because var rotation is not being updated when control.a is being updated during the execution stage (the code shown in my edit). The code below fixes the problem, albeit not very efficiently.
    if (keys[SHIFT]) {
    if(rotation > 0) {
    control.a += control.agility;
    }
    var rotation = atan2(mouseY-height/2,mouseX-width/2)-control.a;
    if(rotation >= 180) {
    rotation -= 360;
    }
    if(rotation < -180) { rotation += 360; } if(rotation < 0) { control.a -= control.agility; } }


    This is one tough navy, boy. They don’t give you time off, even for being dead. -Clay

    Storm Petrel

    in reply to: Torn Stars #19512
    Chessking
    Participant

    Below is a copy of a post originally posted by Bozobub, where he explained how to edit the registry to swap between EOC and Torn Stars executable files. Perhaps it will contain some hints on how to solve your problem.

    Posted by Bozobub on the thread “Modifying default ship.ini’s”

    By the by, usually if IWar 2 (and its variants) fail, after working previously, it’s due to a corrupted registry entry. You can often copy out those keys while it’s working, then simply reapply them if there’s an issue, and *pouf* it works!

    You can also do something similar to switch between multiple installs of IWar 2 (say, Torn Stars and the Vanilla game), by making multiple .reg files, one for each install. I posted the following 11 years ago(!) on the old Torn Stars subforum (thank heaven it was still there to copy/paste, with a couple of changes):

    First, you need one copy of EOC modded to Torn Stars (or w/e variant), and another copy in its original (fully patched! :D) form. I installed EOC to the path: “C:program FilesgamesIndependence War 2 -Edge of Chaos” and Torn Stars to the path “F:More GamesIWAR 2 – Torn Stars”. It doesn’t really matter which is which, so if you’ve already installed Torn Stars over your old EOC game, just reinstall EOC to a new folder with a new name/path of your choice.

    OK, now whichever executable you run in either install, your system will actually execute the version you installed MOST RECENTLY. Bummer. There is, however, a reasonably easy solution. All it takes is a little registry hackin’ :). In fact, just copy each of the two text bits below (including “Windows Registry Editor Version 5.00”) and save with the extension “.reg” (not “.txt”!)to two separate files and you’re set! I used the filename “EOC.reg” for the first one and “Torn Stars.reg” for the second. Yeah, I know, imaginative – lol. 😉

    OK, this 1st bit will be to set your game to run your original EOC. You’ll need to change all instances where I show ‘C:\PROGRA~1\GAMES\INDEPE~1’ to your actual install path for EOC. Yes, the backslashes are doubled! Keep in mind that these are old-school path names that are truncated to 8 characters; you MUST keep the tilde, as well:
    Windows Registry Editor Version 5.00

    [HKEY_LOCAL_MACHINESOFTWAREMicrosoftWindowsCurrentVersionUninstallIndependence War 2 – Edge of Chaos]
    “DisplayName”=”Independence War 2 – Edge of Chaos”
    “UninstallString”=”C:\PROGRA~1\GAMES\INDEPE~1\UNWISE.EXE C:\PROGRA~1\GAMES\INDEPE~1\INSTALL.LOG”

    [HKEY_LOCAL_MACHINESOFTWAREParticle SystemsEdge of ChaosSettings]
    “Options”=dword:00000001
    “InstallPath”=”C:\PROGRA~1\GAMES\INDEPE~1\”
    “Version”=dword:0000000e

    And now the version to set your system to run Torn Stars. Again, you’ll need to change all instances where I show ‘F:\MOREGA~1\IWAR2-~1’ to your actual install path for Torn Stars.
    Windows Registry Editor Version 5.00

    [HKEY_LOCAL_MACHINESOFTWAREMicrosoftWindowsCurrentVersionUninstallIndependence War 2 – Edge of Chaos]
    “DisplayName”=”Independence War 2 – Edge of Chaos”
    “UninstallString”=”F:\MOREGA~1\IWAR2 ~1\UNWISE.EXE F:\MOREGA~1\IWAR2 ~1\INSTALL.LOG”

    [HKEY_LOCAL_MACHINESOFTWAREParticle SystemsEdge of ChaosSettings]
    “Options”=dword:00000001
    “InstallPath”=”F:\MOREGA~1\IWAR2 ~1”
    “Version”=dword:0000000e
    That’s it! I’ve tested it and it works dandy. Just double-click (or right-click and select “Open”) to activate the corresponding .reg file whenever you want to change the version that runs, then click “Yes” when it asks if you want to add the data to the registry. It’s probably advisable to use a separate shortcut to each version – I do – but AFAIK you actually only need ONE; it’ll run the version most recently switched to, whichever you choose. As a nice little bonus, as long as you switch to the correct version before you do so, uninstalling will also work correctly on that version…

    Hope that helps.


    This is one tough navy, boy. They don’t give you time off, even for being dead. -Clay

    Storm Petrel

    in reply to: Torn Stars #18533
    Chessking
    Participant

    Below is a copy of a post originally posted by Bozobub, where he explained how to edit the registry to swap between EOC and Torn Stars executable files. Perhaps it will contain some hints on how to solve your problem.

    Posted by Bozobub on the thread “Modifying default ship.ini’s”

    By the by, usually if IWar 2 (and its variants) fail, after working previously, it’s due to a corrupted registry entry. You can often copy out those keys while it’s working, then simply reapply them if there’s an issue, and *pouf* it works!

    You can also do something similar to switch between multiple installs of IWar 2 (say, Torn Stars and the Vanilla game), by making multiple .reg files, one for each install. I posted the following 11 years ago(!) on the old Torn Stars subforum (thank heaven it was still there to copy/paste, with a couple of changes):

    First, you need one copy of EOC modded to Torn Stars (or w/e variant), and another copy in its original (fully patched! :D) form. I installed EOC to the path: “C:program FilesgamesIndependence War 2 -Edge of Chaos” and Torn Stars to the path “F:More GamesIWAR 2 – Torn Stars”. It doesn’t really matter which is which, so if you’ve already installed Torn Stars over your old EOC game, just reinstall EOC to a new folder with a new name/path of your choice.

    OK, now whichever executable you run in either install, your system will actually execute the version you installed MOST RECENTLY. Bummer. There is, however, a reasonably easy solution. All it takes is a little registry hackin’ :). In fact, just copy each of the two text bits below (including “Windows Registry Editor Version 5.00”) and save with the extension “.reg” (not “.txt”!)to two separate files and you’re set! I used the filename “EOC.reg” for the first one and “Torn Stars.reg” for the second. Yeah, I know, imaginative – lol. 😉

    OK, this 1st bit will be to set your game to run your original EOC. You’ll need to change all instances where I show ‘C:\PROGRA~1\GAMES\INDEPE~1’ to your actual install path for EOC. Yes, the backslashes are doubled! Keep in mind that these are old-school path names that are truncated to 8 characters; you MUST keep the tilde, as well:
    Windows Registry Editor Version 5.00

    [HKEY_LOCAL_MACHINESOFTWAREMicrosoftWindowsCurrentVersionUninstallIndependence War 2 – Edge of Chaos]
    “DisplayName”=”Independence War 2 – Edge of Chaos”
    “UninstallString”=”C:\PROGRA~1\GAMES\INDEPE~1\UNWISE.EXE C:\PROGRA~1\GAMES\INDEPE~1\INSTALL.LOG”

    [HKEY_LOCAL_MACHINESOFTWAREParticle SystemsEdge of ChaosSettings]
    “Options”=dword:00000001
    “InstallPath”=”C:\PROGRA~1\GAMES\INDEPE~1\”
    “Version”=dword:0000000e

    And now the version to set your system to run Torn Stars. Again, you’ll need to change all instances where I show ‘F:\MOREGA~1\IWAR2-~1’ to your actual install path for Torn Stars.
    Windows Registry Editor Version 5.00

    [HKEY_LOCAL_MACHINESOFTWAREMicrosoftWindowsCurrentVersionUninstallIndependence War 2 – Edge of Chaos]
    “DisplayName”=”Independence War 2 – Edge of Chaos”
    “UninstallString”=”F:\MOREGA~1\IWAR2 ~1\UNWISE.EXE F:\MOREGA~1\IWAR2 ~1\INSTALL.LOG”

    [HKEY_LOCAL_MACHINESOFTWAREParticle SystemsEdge of ChaosSettings]
    “Options”=dword:00000001
    “InstallPath”=”F:\MOREGA~1\IWAR2 ~1”
    “Version”=dword:0000000e
    That’s it! I’ve tested it and it works dandy. Just double-click (or right-click and select “Open”) to activate the corresponding .reg file whenever you want to change the version that runs, then click “Yes” when it asks if you want to add the data to the registry. It’s probably advisable to use a separate shortcut to each version – I do – but AFAIK you actually only need ONE; it’ll run the version most recently switched to, whichever you choose. As a nice little bonus, as long as you switch to the correct version before you do so, uninstalling will also work correctly on that version…

    Hope that helps.


    This is one tough navy, boy. They don’t give you time off, even for being dead. -Clay

    Storm Petrel

    in reply to: Preferred developing language #18524
    Chessking
    Participant

    Your link doesn’t seem to be working, IronyMan. I’m not sure why.

    I have been working on EOC 2-D. While playing around with the autopilot approach, I noticed that when coming from a certain direction, (the top right corner, to be exact), a ship would overshoot its target.

    The first thing I did to fix this was optimization. I had been manually calculating the stopping distance of the ship using a for loop. During a physics class I took a little while ago, I found a formula that would do the job better. I implemented the formula, and the ship still overshoots. I am as baffled about my problem as you are with yours. 😉

    Edit: I solved my problem! Yay!


    This is one tough navy, boy. They don’t give you time off, even for being dead. -Clay

    Storm Petrel

Viewing 15 posts - 91 through 105 (of 782 total)