Crashes on rotating May 14, 2009, 11:33:17 pm Also still getting random crashes especially when rotating the map.Petty I know but it's frustrating.Moderator: Split this topic as it did not relate to the topic from which it was split. Quote Selected Last Edit: May 15, 2009, 06:20:25 am by jamespetts
Re: Crashes on rotating Reply #1 – May 15, 2009, 06:21:13 am Colin,are you sure that this is a problem specific to Simutrans-Experimental? I have not done anything to the code relating to rotation, or the display of objects on the map at all. It would be very surprising if this problem was caused by any of the changes that I have made to other areas of the code. Quote Selected
Re: Crashes on rotating Reply #2 – May 16, 2009, 07:28:54 pm hello James, if you introduce new variables in cl****es like koord, koord3, etc this variables have to be rotated as well. I dont know if this applies to ST-experimental. Quote Selected
Re: Crashes on rotating Reply #3 – May 16, 2009, 07:46:36 pm I really don't think that I have changed koord or koord3d... Quote Selected
Re: Crashes on rotating Reply #4 – May 17, 2009, 03:19:54 am James,Just a thought. Maybe Dwachs is saying that, if you use koord or koord3d in your new features (e.g., halts for waiting times), you need to translate those koord or koord3d objects to fit into the new, rotated coordinate plane in karte_t::rotate90(). Quote Selected
Re: Crashes on rotating Reply #5 – May 17, 2009, 09:58:51 am I don't think that that's what Dwachs is saying, and I'm not sure what sort of use that you imagine here - how would one "rotate", for example, a p****ing reference to a co-ordinate in a method? Quote Selected
Re: Crashes on rotating Reply #6 – May 17, 2009, 10:41:45 am Like Knightly said,When simutrans rotates a map, everything is rotated. Especially coordinates will change. That is, if you have in your cl**** member variables like koord etc, you have to ensure to rotate these member variables in the rotate function too. That means, after rotation unrotated koords will point to the wrong location. Quote Selected
Re: Crashes on rotating Reply #7 – May 17, 2009, 01:36:56 pm Quote from: jamespetts – on May 17, 2009, 09:58:51 amI don't think that that's what Dwachs is saying, and I'm not sure what sort of use that you imagine hereThis is the International Simutrans Forum, and many people are not native English speakers as you do. Thus, when you read other people's posts, you cannot expect everyone to express their point in English as clearly as you do, and sometimes you need to guess what other people actually mean and be patient.When I expressed to you my understanding of Dwachs's previous post, I did that out of kindness, and I don't think I deserve a rude comment like "what sort of use that you imagine here". Actually, it seems to me that it is you who fail to understand my point, and that is not my fault.Quote - how would one "rotate", for example, a p****ing reference to a co-ordinate in a method?I haven't read all your ST EXP code, but at least with respect to waiting times, you do record koords for directly reachable halts. You record those halts' koords as a key and record a fixed list of waiting times for those halts, and save these key-data pairs in the hashtables of waiting_times[c]. They are even saved in the save game. So, can you say that you don't need to translate those koords when the map is rotated? I am not saying that this is the cause of Colin's crashes, but at least this is a bug that need to be fixed, and it serves to illustrate Dwachs' point. Quote Selected
Re: Crashes on rotating Reply #8 – May 17, 2009, 01:45:41 pm Knightly,I was not intending to be rude - I think that you misunderstand me. I was only stating that I did not really understand what you meant, and that what you wrote did not appear to me to be what Dwachs had meant. Apologies if it came accross the wrong way.In fact, you are right about the co-ordinate storage for the waiting times lists: I have added a method to rotate those. There were some other rotation issues, too, that I could not trace back to any Simutrans-Experimental specific code, but have put in place work-arounds so that rotation no longer crashes, which will be available in the next release. Thank you to all those who have helped to track down the problem :-) Quote Selected
Re: Crashes on rotating Reply #9 – May 18, 2009, 06:13:45 am Knightly - I didn't read his phrase as rude -- I think it's a misunderstanding. Quote Selected
Re: Crashes on rotating Reply #10 – May 18, 2009, 11:12:54 am Thanks for your explanation, Issac. I am not a native English speaker myself, so I will trust your expert opinion . In any case, I am not unhappy anymore after reading James' reply.James, my apologies for misinterpreting your post. Quote Selected
Re: Crashes on rotating Reply #11 – May 18, 2009, 11:30:13 am Back to the topic, Colin's savegame, (Experimental 3.4.2.sve) which was uploaded before, still crash on rotating in v3.9. Quote Selected
Re: Crashes on rotating Reply #12 – May 18, 2009, 12:00:56 pm Z9999,thank you for the report. Hmm, this is a difficult one to track down... Quote Selected
Re: Crashes on rotating Reply #13 – May 18, 2009, 11:20:39 pm James -I don't know if you've yet determined whether this bug is due to ST Exp or not, but just to let you know, I still experience a crash in v3.10 when trying to rotate the map. (Actually, the game just freezes up.) I was able to rotate 180 degrees fine, but now I can't rotate it back at all. Very disorienting, having to view the map from 180 degrees difference when you've played for hours looking at it from a particular viewpoint. Quote Selected
Re: Crashes on rotating Reply #14 – May 18, 2009, 11:28:13 pm If you save and reload, can you rotate again? Quote Selected
Re: Crashes on rotating Reply #16 – May 18, 2009, 11:32:57 pm Hmm, sorry that you're having problems. I'm afraid that this one is very hard to track down... Quote Selected Last Edit: May 18, 2009, 11:39:15 pm by jamespetts
Re: Crashes on rotating Reply #17 – May 18, 2009, 11:37:14 pm At least it's playable. Thanks for your efforts, is there any more information I can provide that might help? Quote Selected
Re: Crashes on rotating Reply #18 – May 18, 2009, 11:39:20 pm Can you upload your saved game for diagnostic purposes? Quote Selected
Re: Crashes on rotating Reply #19 – May 18, 2009, 11:52:59 pm Sure. I used a pak128+pak128.Britain mix in this particular game, but I think you can still open it using pak128. I tested it that way and it opens fine, but many vehicles/stations are missing or replaced with other versions. I still experienced the rotation bug though. (Also, the notes in simuconf say that savegame compatibility is affected by using different catchment values, so if it does make a difference, I use "2" instead of your default "3".) Save is now uploaded: http://simutrans-germany.com/files/upload/1907.sve Quote Selected Last Edit: May 18, 2009, 11:59:03 pm by tick tock
Re: Crashes on rotating Reply #20 – May 19, 2009, 06:27:17 pm Tick Tock,thank you very much for uploading that. I have had another go at fixing the problem in 3.11, which seems to work for your saved game. Could you give it a try? Thank you very much for your testing and reporting. Quote Selected
Re: Crashes on rotating Reply #21 – May 19, 2009, 08:01:23 pm Yes, it seems to work fine now! Thanks, as always, for the quick response. Quote Selected
Re: Crashes on rotating Reply #22 – May 19, 2009, 08:34:41 pm Excellent - glad that it works for you :-) Quote Selected