Simple collision detection - help needed

ok, im having trouble with collision detection. i think i've
got the first bit right (below) but i cant seem to complete the
other behaviour which i plan on atteching to the sprite in channel
73 to complete the collision detection.
global gCollision
on collisionDetect me
if sprite(me.spriteNum).within(73) then
go to frame "end"
end if
end
thanks

Try intersect function:
if sprite i intersects j then put("You placed it correctly.")
"P2Vulco" <[email protected]> wrote in
message
news:e2qa5r$l1i$[email protected]..
> im trying to do this:
>
> when sprite 73 collides with sprite 14 then do something

Similar Messages

  • Simple BIP Report help needed

    Hi All ,
    I am bit new to BI Publisher,I have done plenty of Oracle reports 6i and 10g.
    Have read the BIPublisher Guide as well,but could not understand a few points.
    suppose I want to build a very very simple report like
    Sysdate Sysdate Sysdate
    16-Oct-08 16-Oct-08 16-Oct-08
    step 1) I will write the following query in the Data Model and store/save it.
    select sysdate ,sysdate,sysdate from dual.
    Step 2) In the layout model I want to use .rtf layout .So in the MS word .rdf document I create /insert
    a table with 2 rows and 3 columns,where 1st row will have Sysdate in all 3 columns as header.
    Now to fetch date 3times(the data) from the above query,WHAT is going to be my next steps ????
    I am not able to understand the link between the layout(.rtf document) and XML document.
    Please can someone reply to this question and let me know ?
    Regards
    Sunny

    I added a useless parameter just so you could see where parms should go...
    Datatemplate:
    <dataTemplate name="A_SIMPLE_REPORT">
         <properties>
              <property name="xml_tag_case" value="upper"/>
         </properties>
         <parameters>
              <parameter name="P_PARM" dataType="character"/>
         </parameters>
         <dataQuery>
              <sqlStatement name="QUERYNAME">
                   <![CDATA[
    select sysdate SYSDATE1
    , sysdate SYSDATE2
    , sysdate SYSDATE3
    from dual
    where 'XYZ' = nvl(:P_PARM, 'XYZ')
    ]]>
              </sqlStatement>
         </dataQuery>
         <dataStructure>
              <group name="G_UPPERGROUP" dataType="varchar2" source="QUERYNAME">
                   <element name="SYSDATE1" dataType="varchar2" value="SYSDATE1"/>
                   <element name="SYSDATE2" dataType="varchar2" value="SYSDATE2"/>
    <element name="SYSDATE3" dataType="varchar2" value="SYSDATE3"/>
              </group>
         </dataStructure>
         <dataTrigger name="afterReportTrigger" source="A_SIMPLE_REPORT.afterreport()"/>
    </dataTemplate>
    XML OUPUT:
    <?xml version="1.0" encoding="UTF-8" ?>
    <A_SIMPLE_REPORT>
    <LIST_G_UPPERGROUP>
    <G_UPPERGROUP>
    <SYSDATE1>2008-10-16T18:20:19.000-05:00</SYSDATE1>
    <SYSDATE2>2008-10-16T18:20:19.000-05:00</SYSDATE2>
    <SYSDATE3>2008-10-16T18:20:19.000-05:00</SYSDATE3>
    </G_UPPERGROUP>
    </LIST_G_UPPERGROUP>
    </A_SIMPLE_REPORT>
    Hope this helps,
    Scott
    PS If you have been doing reports for as long as you say you prob. know this already...but I NEVER* trust Oracle to convert my dates. I convert them all to char, pass them and convert them on "the other side" (if needed). But, you can change the data type to date if you feel brave, but don't say I didn't warn you. ;-)

  • Simple HTML page HELP needed

    Hi all,
    Here's my dilemma:
    I've got this simple html page that I've made with
    dreamweaver CS3. On the starting page I want to put a section
    called "NEWS", under which there would be essentially a texfield
    with the news. Now, I don't want to put the news text in the html
    code. Rather, I'd like the code to somehow take this text from a
    separate text file which I could edit at will and simply overwrite
    on the host server so that changes are seen in browsers.
    I don't need a real CMS (besides, CMS is way over my head).
    Just this one text field. I've tried with the textfield/text
    area/HTML object/etc. in the 'insert' tool but none worked. Can
    this be done at all? Appreciate any help.

    macioo1 wrote:
    > Now, I don't want to put the news text in
    > the html code. Rather, I'd like the code to somehow take
    this text from a
    > separate text file which I could edit at will and simply
    overwrite on the host
    > server so that changes are seen in browsers.
    You can do this with a server-side include. The first thing
    you need to
    do is to find out whether your hosting company has enabled
    server-side
    includes, or if you have access to a server-side language
    such as ASP or
    PHP. The way that you create a server-side include is
    slightly different
    in each type of setup.
    When you have found what your remote server supports, someone
    can give
    you further instructions.
    David Powers, Adobe Community Expert
    Author, "The Essential Guide to Dreamweaver CS3" (friends of
    ED)
    Author, "PHP Solutions" (friends of ED)
    http://foundationphp.com/

  • Simple java applet help needed

    hi, im having trouble with an applet im developing for a project.
    i have developed an applet with asks the user for simple information( name,address and phone) through textfields, i wish for the applet to store this information in an array when an add button below the textfeilds is pressed.
    client array[];
    array=new client[];//needs to be an infinate array!
    I have created the client class with all the set and get methods plus constructors needed but i dont know how to take the text typed into the textfields by the user and store them in the array.
    i also need to save this info to a file and be able to load it back into the applet.
    Could some please help! Thank you for your time.

    Better maybe redefine the idea using an data structure :
    public class client{
    private char name[];
    private char address[];
    private int phone;
    public class vector_clients{
    private client vect[];
    // methods for vect[]
    What is your opinion about ???

  • Simple Sound Recording - Help needed

    Hi there
    Im wondering if this is possible and if so , does anbody know offhand where I can find a basic implementation of this typea thing...
    I simply need to be able to read in a wav file, then record it and give it a different name. I am just trying to get this basic functionality sorted, because I will be progressing on to reading in a file, runninig some DSP algorithm on it, and then needing to save it back out, so I elieve that I need to write it in chunks much the same as the SourceDataLine buffers the sound...err am i making sense?
    I have been trying to do this with TargetDataLine, and its just getting the better of me at the moment, I am able to read in the file and play it as normal, its just the recording it to an output file where I am failing.
    thanks a million
    conaill

    Do I get you right that you want to read a sound file into memory and then store it back to the hard disk? If this is the case, try this:
    int frameSizeInBytes;
    int bufferLengthInFrames = 32;
    int bufferLengthInBytes;
    byte[] data;
    int numBytesRead;
    BufferedReader mIn;
    AudioFormat format;
    ByteArrayInputStream bIn;
    AudioInputStream outStream;
    File o;
    int soundLength;
    soundLength = 1000;
    f = new File("infile.wav");
    inStream = AudioSystem.getAudioInputStream(f);
    format = inStream.getFormat();
    frameSizeInBytes = format.getFrameSize();
    bufferLengthInBytes = bufferLengthInFrames * frameSizeInBytes;
    data = new byte[soundLength];
    o = new File("outfile.wav");
    // read the sound data
    numBytesRead = inStream.read(data, 0, soundLength);
    inStream.close();
    // now write it back
    bIn = new ByteArrayInputStream(data);
    outStream = new AudioInputStream(bIn, format, soundLength);
    AudioSystem.write(outStream, AudioFileFormat.Type.WAVE, o);This reads only a portion of a file, you'll have to modifiy it.
    Hope this helps,
    S

  • Simple Xmonad configuration help needed.

    I have no idea how haskell works at all. But I simply love xmonad!
    Could someone help me out with my configuration? It is currently
    import XMonad
    import XMonad.Config.Xfce
    main = xmonad xfceConfig
    This works pretty well for me, for the most part. However, I need a few keybinding. First, I want ctrl-alt-arrow to change desktops and I found I can do this with "XMonad.Actions.CycleWS", which I have installed and the configuration of:
    , ("M-<Left>", prevWS )
    , ("M-<Right>", nextWS )
    , ("M-S-<Left>", shiftToPrev )
    , ("M-S-<Right>", shiftToNext )
    However, I have no idea how to do this. Also, I would like XF86AudioRaiseVolume to execute "amixer set Master 5dB+" and XF86AudioLowerVolume to "amixer set Master 5dB-" and XF86AudioMute to "amixer set Master toggle". I know I could easily do this with xbindkeys or some other extra keybinding daemon, but I want to learn how to do this the correct way in haskell. Thanks!

    Is this your whole xmonad.hs ? Anyway for the keybindings part ( for multimediakeys i use xbindkeys because i use the same xmonad.hs on my laptop plus desktop ) , but you can do it without xbindkeys wich is much nicer, less apps needed. If your keys are already reconignized as XF86AudioMute then you wouldnt have to use xmodmap. You can define keys in two various ways in XMonad with the additional keysP (Util.EZconfig ) or with keys = Mykeys
    I always learn from looking into others people's configs , so here is an config from another arch user. Look for the section myKeys, and define something like :
    , ("<XF86AudioLowerVolume>", spawn amixer set Master 5dB+)
    if you are interested here is my config
    Further reference
    Last edited by jelly (2009-07-31 00:31:09)

  • Simple math operation - Help needed

    Hi, i have a simple mathematical operation to do, related to
    a shooping cart, which i want to keep simple.
    I have a input text box named QT1, where customers indicate
    quantity
    I have a dymanic text box, named ST1, where i want the value
    of QT1 to be multiplied by 10$ (hence 10)
    on the release of the button. I have a NaN answer. Here is
    the code.
    on (release) {
    var qt1:Number;
    st1 = qt1 * 10;
    And then, a grand total button will add ST1 + ST2 + ST3, with
    GT the name of the grand total dymamic box:
    on (release) {
    gt = st1 + st2 + st3;
    The second part works, but the first one, with QT1 is giving
    me a Nan (not a number) answer.
    Any help appreciated.

    Problem solved. That cary Auto-kern thing....

  • Creating a very simple dice game - help needed

    I have been assigned to create a simple dice game with the result like below :
    Welcome to the Dice game.
    Please answer the following questions with 2-16 characters :
    Whats the name of player 1? a
    wrong format
    Vad heter spelare 1? Duffy
    Vad heter spelare 2? John
    Duffy throws: 6
    John throws: 4
    I have come to the "Duffy throws 6" part and have absolutly no idea how i should continue. I have tried to look up the codes in "API Specification" but found no codes / names with "dice" :)

    I have come to the "Duffy throws 6" part and have
    absolutly no idea how i should continue.How on earth should it continue??? I can't mind read unfortunately.

  • Simple Narration Editing Help Needed

    Hello,
    I am brand new to audio editing and SB. I have recorded a narration. There was a little bit of background noise and the peak levels were a little too high (going into the red a little too often). I selected a piece of the background recording where no narration exists and used the "Capture Noise Print" in the Clean Up Audi0 - Noise panel to get rid of the background noise. Then I "Equalized Volume Level" to take care of the peaking problem. However, now the voice is a little on the tinny side. Can anyone suggest how I can get rid of that tinny sound and bring back the richness? Or perhaps a tutorial?
    Any suggestion on how to record with proper levels would be helpful as well.
    Thanks,
    Mike

    I have the same problem.
    Did you ever figure this out?
    Using the Effect Fix:Remove Hiss seemed to work better, but there is still a significant amount of background noise when no one is talking.
    It did seem to help to set the Noise -> Reduction value down to 30 or so using the Preview and Green switch to hear the difference.
    I'm still looking for the best workflow to cleanup a group discussion setting and would appreciate anyone else's experience.

  • Simple Array Question - Help Needed!

    Hey people,
    I need a line of code that gets the maximum value out of an array.
    the array is called LEVELS and contains values [1, 3, 4, 17, 3, 2, 4]. I need a line of code that creates a new variable called MAXLEVEL and finds the largest value within the array.
    Thanks,
    sean :)

    Create a variable. Initialize it to the lowest possible value, like say Integer.MIN_VALUE.
    Loop through your array.
    For each element, see if it's greater than the current value in the variable. If it is, use it.
    When you reach the end of the array, the variable now holds the max value.
    How did you think you were going to do it?

  • Simple bash scripting help needed..

    I want to learn som simple bash scripting in order to automate various tasks.. Im totally noob, so bear with me
    First of all I would like to set configs without using nano.. is there a simple command for this? For example if i want change my hostname in /etc/rc.conf.. how can i print the current vallue and how can i change it`?
    i was thinking something like this to get the current value:
    # cat /etc/rc.conf | grep HOSTNAME=
    which returns HOSTNAME="myhostname"
    how can i change this value with one or more commands whitout touching the rest of the file?

    abesto wrote:
    A slightly naive solution:
    CHOICE="lisa"
    NAMES="homer marge lisa bart maggie"
    if [ "`echo \" $NAMES \" | grep \" $CHOICE \"`" ]; then
    echo "this is how you do it"
    fi
    The extra spaces inside the escaped quotes are to ensure that only a whole word is "matched".
    You can also replace the elif's with a loop through a list of "the other variables". Then you'd use the loop variable instead of $CHOICE above.
    grep can check on word-bounderies with \< and \>, or with the -w switch. The -q switch suppresses any messages and exits with exit-code 0 when the first match is found:
    if echo "${NAMES}" | grep -qw "${CHOICE}"; then
    Nice and readable, should work, but i haven't tested it
    EDIT:
    Procyon wrote:CHOICE="lisa"
    NAMES="homer marge lisa bart maggie"
    if [[ $NAMES =~ $CHOICE ]]; then echo match; fi
    This one also matches elisa, ie. no check on word bounderies. You should be carefull with that
    Last edited by klixon (2009-04-23 09:40:22)

  • Simple question, Urgent help needed.(Session Related)

    I am new in Java and i want help in the following query:
    When there is no session already defined and no values assigned to the session and i run the
    String session_loginName = (String) session.getAttribute("username");
    command in a doGet method
    What is the result to the string?
    null? or something else?
    My intensions are:
    To have restricted areas in my web app and when a user clicks on a link which includes restricted content, to first call a servlet which will test if there is a session already and if not it will redirect to the Login page.
    I am thinking to use the following code.
    Will this work ok?
    package mypackage;
    import javax.servlet.*;
    import java.io.*;
    import java.sql.*;
    import javax.servlet.http.*;
    public class EntGroupRegistration extends HttpServlet{
    private String url = "jdbc:odbc:test";
    * Standard Post Method for Processing the HTML Variables
    protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException,IOException
    String session_loginName;
    * Obtain username from session object
    session_loginName = (String) session.getAttribute("username");
    if (session_loginName.equals(null)) {
    response.sendRedirect(
    "http://localhost/se/Resources/changepassS.htm"); }else{
    response.sendRedirect(
    "http://localhost/se/Activities/GroupRegistration.htm");
    Any suggestions upon the code?
    Thank you for your time.

    if session_loginName is null then how can you call equals method on it???? Always give it a little thought first before typing code...
    try something like
    if(session_loginName != null)
    // you code as before
    }

  • Simple problem but help needed

    how do I accept a character y or n from the user? otherthan readLine()used for String console input. which function should I use to accept y or n and proceed based on y or n , same is the case with boolean. If I would want to accept a boolean value from the console
    from the user and would want to proceed according to what boolean value(true or false) has been entered by the user
    import java.io.*;
    public class acceptUsersChoice{
    public static void main(String args[])throws IOException{
    InputStreamReader hi=new InputStreamReader(System.in);
    BufferedReader hey=new BufferedReader(hi);
    //accepting user's choice and acting accordingly
    System.out.println("Enter Your choice 'y' or 'n' ");
    char s=
    /* here how do I accept a character y or n ? which function should I use to accept y or n and proceed based on y or n , same is the case with boolean. If I would want to accept a boolean value
    from the user and would want to proceed according to what boolean(true or false) has been entered by the user, how do I do it?*/
    System.out.println("This is it"+s);
    }}

    Crossposted. Here's one of them:
    http://forum.java.sun.com/thread.jspa?threadID=597733

  • Simple SQl statement help needed!!!

    New to SQL..Please can you advice where is the problem..
    select file_id, a.file_name, a.sum(bytes/1024/1024) Used_space, b.sum(bytes/1024
    /1024) Free_space from dba_data_files a, dba_free_space b where tablespace_name
    ='DATA_TS' OR tablespace_name='INDEX_TS' OR tablespace_name='LOB_TS' group by fi
    le_id
    ERROR at line 1:
    ORA-00918: column ambiguously defined
    Thanks!

    Hi,
    Should you chose to format your SQL the problem is easily seen:
    SQL>select file_id
      2          ,a.file_name
      3          ,a.sum(bytes / 1024 / 1024) used_space
      4          ,b.sum(bytes / 1024 / 1024) free_space
      5      from dba_data_files a, dba_free_space b
      6     where tablespace_name = 'DATA_TS'
      7        or tablespace_name = 'INDEX_TS'
      8        or tablespace_name = 'LOB_TS'
      9  group by file_id;
    group by file_id
    ERROR at line 9:
    ORA-00918: column ambiguously defined
    SQL>So, which file_id do you want - a or b?
    Regards
    Peter

  • Position Class...- Simple question - urgent help needed

    I am only having problems with Position parameters....what the hell does a Position refer
    to? A number? Do you supply a number for Position parameter to find a node in a
    doubly linked list? It seems that it goes by that way, but how the heck do you located it
    with a Position parameter p (Postion p)? Doubly /singly linked lists have no reference this
    with numbers....I am only confused when you have instances like:
    public Object remove (Position p) {.....}
    How do you instantenously locate the appropriate node in a Linked list via Position p
    parameter?
    Everything else I understand!!!! It's just that Positioning is bugging the hell out of me...Do
    I supply number 3 for a third node in a linked list? or what?

    i can not see a Object remove(Position p) in LinkedList , and the only Position class I can think of is in javax.swing.text - which is to do with marking positions in text documents. ?
    can you explain your problem better ?

Maybe you are looking for

  • Windows keeps giving me "itunes has stopped working" error message when I start itunes?  How can i fix this?

    After downloading the newest version, 10.6.1, whenever I open itunes I almost immediately get a "itunes has stopped working" error messsage, in which the only option is to hit the "close the program" button.  Simply closing the error message closes t

  • Backlight does not turn on anymore Satellite M70-147

    Hello outhere, The backlight of my M-series M70-147 does not turn on anymore. I first noticed this when awakening the laptop from standby or hibernation mode. At first I thought the screen was not working anymore, but when I looked closely I could st

  • Data Recovery AFTER TechTool Deluxe "Repair" ?

    Hello, I have a PB from Fall 2005 (1.5 Ghz, 512 Ram, superdrive, 80 GB) running 10.4. Recently, performance really started to lag, so I began diligent monitoring and ordered an external HD to perform a more comprehensive backup. For the last week, al

  • Death penalty without giving a reason

    Hi, I could not start Sun one 7 server. I got the following error: E:\Sun\AppServer7\bin>asadmin start-domain --domain domain1 Could not start the instance: domain1:admin-server server failed to start: abnormal subprocess termination Could not start

  • Switch to "Source Code-Based" mode in class builder

    hi, while doing the tutorial http://help.sap.com/saphelp_nwpi71/helpdata/en/67/6b5bbb681e4f10b44bc2d6c4167b02/content.htm i came across the step, ... Switch to Source Code-Based mode , in the class builder, but in my workbench it is not available. i