23.07.2013, 02:01
(
Последний раз редактировалось Pottus; 23.07.2013 в 02:54.
)
You should use a variable to store the object id's and return the index the coding looks good but lacks checking when doing actions which could lead to the potential of modifying objects that are not even part of the system. That is what I would do to it so you have some fail safes in place when something goes wrong.
http://pastebin.com/ndL2hxWr
http://pastebin.com/ndL2hxWr