estoy utilizando solo linux pero le instalare mac por que no sube tan rapido y me da un error tsc calibration failed
Esta sección te permite ver todos los mensajes escritos por este usuario. Ten en cuenta que sólo puedes ver los mensajes escritos en zonas a las que tienes acceso en este momento.
Mostrar Mensajes Menú
void add( int d )
{
if ( _next == 0 )
_next = new LinkList( d );
else
_next->add( d );
}
void Print( )
{
std::cout << "Dat Value : " << _value << std::endl;
if ( _next )
_next->Print( );
}
#include <cstdlib>
#include <cstdlib>
#include <iostream>
using namespace std;
class LinkList{
int dat;
LinkList *nxt;
public:
~LinkList(){
delete nxt;
}
LinkList(int t =0):dat(t){
nxt = new LinkList(0);
}
void add(LinkList *ll,int d){
nxt = ll;
dat =d;
}
void Print(){
while(nxt != NULL)
{
cout <<"Dat Value : "<< dat<<std::endl;
nxt = nxt->nxt;
}
}
};
int main(int argc, char *argv[])
{
LinkList f, r1(7), r2(6);
f.add(&r1,7);
f.add(&r2,6);
f.Print();
system("PAUSE");
return EXIT_SUCCESS;
}
import java.awt.*;
import java.io.*;
import javax.swing.JFrame;
import javax.swing.JPanel;
import java.awt.image.*;
public class Main extends JPanel{
int x;
int vx;
int y;
int vy;
public void move(){
vy =1;
vx =1;
x = x+vx;
y = y+vy;
}
public void paint(Graphics g){
super.paint(g);
Graphics2D g2d = (Graphics2D)g;
g2d.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING,
RenderingHints.VALUE_TEXT_ANTIALIAS_ON);
Image im = ImageIO.read(new File("nave.png"));
g2d.drawImage(im, x,y,null);
/////g2d.dispose();///
}
public static void main(String []args){
Main m = new Main();
JFrame f = new JFrame("ddd");
f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
f.setSize(800,800);
f.getContentPane().add(m);
f.setVisible(true);
while(true){
m.repaint();
m.move();
try{
Thread.sleep(25);
}catch(Exception e){}
}
}
}
.getImage()
pero por que dice que no reconoce el simbolo en la consola y si uso ToolKit.getDefaultToolkit.getImage(..) , getClass().getResource("").getImage()
si no me equivoco es asi pero quisiera saber por que cuando lo hago la imagen se queda en un punto (inicialize y=0 ,x =0, no lo puse por hacerlo rapido) ,me gustaria saber que puedo hacer para que se muevan o me recomiendan algo, en los tutoriales lo hacen asi ,claro con sus cambios y no quiero copiar.