[SailfishDevel] Refrence dynamically created QML object?
Peter Pykäläinen
peter.pykalainen at gmail.com
Mon Oct 6 07:25:06 UTC 2014
Cheers! Will do.
// Peter Pykäläinen
On 6 October 2014 10:19, <piggz1 at gmail.com> wrote:
> I'm at work and only have my phone arm. If you haven't sorted it by 6pm
> gmt, let me know and I'll pass something on :)
>
> Sent from my BlackBerry 10 smartphone.
> *From: *Peter Pykäläinen
> *Sent: *Monday, 6 October 2014 8:15 AM
> *To: *Sailfish OS Developers
> *Reply To: *Sailfish OS Developers
> *Subject: *Re: [SailfishDevel] Refrence dynamically created QML object?
>
> Thank you for your reply.
> That sounds like it could work.
> Care to share your solution how you store your objects?
>
>
>
> // Peter Pykäläinen
>
> On 6 October 2014 10:12, <piggz1 at gmail.com> wrote:
>
>> Can't you just store each object in a different javascript object? When I
>> create a bunch of objects in my games I store them in javascript arrays.
>>
>> Sent from my BlackBerry 10 smartphone.
>> *From: *Peter Pykäläinen
>> *Sent: *Monday, 6 October 2014 7:26 AM
>> *To: *devel
>> *Reply To: *Sailfish OS Developers
>> *Subject: *[SailfishDevel] Refrence dynamically created QML object?
>>
>> Hi,
>>
>> I have a problem with a dynamically created QML object and referencing it.
>> The problem is as follows:
>>
>> - Create a dynamic QML object with createObject, assign signal to it.
>> This works fine.
>> - Create another dynamic QML object.
>> - I would need to check collision of these two new objects, I am using a
>> timer to check that.
>> - Now since I can not reference both objects with their IDs I can't get
>> the collision check to work.
>>
>> Any ideas how to achive this?
>>
>> I have tried to use a LlistModel to store all my objects, but looping
>> through them with JavaScript slows down my application significantly, so
>> this is not an option.
>>
>> // Peter Pykäläinen
>>
>>
>> _______________________________________________
>> SailfishOS.org Devel mailing list
>> To unsubscribe, please send a mail to
>> devel-unsubscribe at lists.sailfishos.org
>>
>
>
>
> _______________________________________________
> SailfishOS.org Devel mailing list
> To unsubscribe, please send a mail to
> devel-unsubscribe at lists.sailfishos.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.sailfishos.org/pipermail/devel/attachments/20141006/e4566de3/attachment-0001.html>
More information about the Devel
mailing list