das hier , habe ich per google gefunden :
Zitat:
Nothing is easier:
maxtime=(tim lengh of the animation)
tic
for i=1:10000 %main loop
operation
if toc>maxtime
break%end simulation
end
end
notice that "toc" counts the time from the last "tic", so tic goes out the loop and toc inside.
|
schau mal , ob es das sein könnte