Login
User Name:

Password:



Register

Forgot your password?
do_advance
Jun 27, 2026 10:32 am
By Remcon
Time spamming LOP1.6
Jun 17, 2026 4:03 pm
By Remcon
A Bash Startup Script
Feb 7, 2026 3:49 pm
By eldhamud
Force Skills
Jan 1, 2026 3:58 pm
By Elwood
Overland with Bitmaps
Jul 4, 2025 11:57 pm
By Samson
SillyMUD 1.2a
Author: J. Brothers, J. Sievert, et al
Submitted by: Samson
SillyMUD 1.1b
Author: J. Brothers, J. Sievert, et al
Submitted by: Samson
SWFotEFUSS 1.5.3
Author: Various
Submitted by: Samson
SWRFUSS 1.4.3
Author: Various
Submitted by: Samson
SmaugFUSS 1.9.8
Author: Various
Submitted by: Samson
Users Online
Anthropic, DotBot, Majestic-12, Amazonbot, Baiduspider, DuckDuckGo

Members: 0
Guests: 103
Stats
Files
Topics
Posts
Members
Newest Member
512
3,813
19,727
595
LucaWhish

» SmaugMuds » Codebases » SWFOTE FUSS » Ship Crashing into objects..
Forum Rules | Mark all | Recent Posts

Ship Crashing into objects..
< Newer Topic :: Older Topic > Crashing into the sun for mainly..

Pages:<< prev 1 next >>
Post is unread #1 Mar 29, 2024 7:48 am   
Go to the top of the page
Go to the bottom of the page

Elwood
Fledgling
GroupMembers
Posts15
JoinedMar 29, 2024

 
Hey again. It's been years, got back into playing with this stuff. Be more learning to do lol.
I used to be Deathbringer/RapidRunner but i dont know password i used, or have the email i used years ago..
anyhow... problem is...

You fly any ship into the sun it'll crash mud.

Speed: 100 Hull: 100% Shields: 0% Energy: 96%
Coordinates in Coruscant system: 110 -122 121
Proximity alert: Corusca Prime 0 0 0


Core Dump:

0x0000558e29710152 in move_ships () at space.c:606
606 if( !ship || !ship->starsystem )
(gdb) bt
#0 0x0000558e29710152 in move_ships () at space.c:606
#1 0x0000558e297758dc in update_handler () at update.c:2663
#2 0x0000558e2961bce6 in game_loop () at comm.c:570
#3 0x0000558e2961ab3b in main (argc=2, argv=0x7ffd9991c308) at comm.c:246


Post is unread #2 Mar 29, 2024 5:45 pm   
Go to the top of the page
Go to the bottom of the page

Remcon
Geomancer
GroupAdministrators
Posts1,991
JoinedJul 26, 2005

 
well after a quick look at the code you probably should add a ship_next and set ship_next to ship->next at the start and use ship_next instead of ship->next in the for loop. the ship is being destroyed when it flies into the sun and causing the issue.

Post is unread #3 Mar 30, 2024 12:54 am   Last edited Mar 30, 2024 5:38 am by Elwood
Go to the top of the page
Go to the bottom of the page

Elwood
Fledgling
GroupMembers
Posts15
JoinedMar 29, 2024

 
Remcon is a Genius! Don't know why i didnt think of it! lol.

Fix that works then would be here to help others.

in space.c move_ship
find
SHIP_DATA *ship;

and change it to:
SHIP_DATA *ship, *ship_next;


find
for ( ship = first_ship; ship; ship = ship->next )
   {


change it to:
for (ship = first_ship; ship; ship = ship_next)
{
    // Store the next ship pointer before potentially destroying the current ship
    ship_next = ship->next;


its what i did and its working

Pages:<< prev 1 next >>