Just started learning and need help please

Discussion in 'Jiggy Runtime Development' started by Wesche, May 24, 2008.

  1. Wesche

    Wesche New Member

    Joined:
    Dec 1, 2007
    Messages:
    633
    Likes Received:
    4
    Device:
    2G iPod touch
    I downloaded jiggy thing and got it all set and did the app but... Well... I now how to creat the bar at the top set background color and all that basic stuff.... but I want to creat a simple darts game... where the background is just a picture of a dart for when someone presses the screen. That is all I want... so here is what I have...
    I have no idea how to set the background the way I want or what the "fucntion" to put for when I touch screen or how to set pictures, I have tried searching on google and on the forums but I cant find how...
  2. micaheljcaboose

    micaheljcaboose Well-Known Member

    Joined:
    Jan 20, 2008
    Messages:
    1,855
    Likes Received:
    82
    Gotta pull off one of these puppies.
    Code:
    var mainView = new UIImageView(new Image('Default.png'));
    window.setContentView( mainView );
    Make it look like this:
    Code:
    Plugins.load( "UIKit" );
    
    var window = new UIWindow( UIHardware.fullScreenApplicationContentRect );
    window.setHidden( false );
    window.orderFront();
    window.makeKey();
    window.backgroundColor = [ 1 , 1 , 1 , 1 ]; //White background
    
    [B]var mainView = new UIImageView(new Image('Default.png'));
    window.setContentView( mainView );[/B]
    
    var bar = new UINavigationBar( [ 0 , 0 , 320 , 48 ] );
    bar.setBarStyle(2);
    bar.showButtonsWithLeftTitle(null , "Info");
    var title = new UINavigationItem( "Testing app" );
    bar.pushNavigationItem( title );
    bar.onButtonClicked = function( bar , button )
    {
    if ( button == 0 )
    {
    var sheet = new UIAlertSheet( [0 , 0, 200, 60] , 0 );
    sheet.setAlertSheetStyle(0);
    sheet.setTitle( "About" );
    sheet.setBodyText( " Test. " );
    sheet.popupAlertAnimated( true );
    mainView.addSubview( sheet );
    sheet.popupAlertAnimated( true );
    }
    };
    mainView.addSubview( bar ); 
    Good luck with your app.
  3. deleted account 4

    deleted account 4 New Member

    Joined:
    Dec 6, 2007
    Messages:
    293
    Likes Received:
    8
    Device:
    2G iPod touch
    I'm not the person who asked this, but this will probably be helpful to me as soon as I start, so... + imaginary rep to you

Share This Page