Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Josh @ Dreamland

1501
Function Peer Review / Re: move_contact functions optimised for bbox
« on: January 04, 2011, 08:01:45 PM »
Oh, does it do so in GM? That would mean a change in algorithm (this one stops as soon as it hits a wall).

1502
Announcements / Re: Happenings
« on: January 04, 2011, 02:46:56 PM »
Yeah, that should never happen.

Yes, but the makefile needs updated. Ism updated it for you last time by running automake_all.sh from SHELL/.
You can update it manually, if you wish, or find a competent shell to update it for you. (Or commit and ask Ism to do so again, or I can).

I forget why I couldn't do fonts, be it compression or otherwise. We'll see about those...

1503
Announcements / Happenings
« on: January 03, 2011, 07:42:06 PM »
So after four people in less than a month struggled to install ENIGMA, I've finally begun redoing ENIGMA.exe. It will automatically call mingw-get to install necessary files; the user needs only to specify a drive letter (if he or she is dissatisfied with the default, being the current drive). I was actually looking for a function to prompt for drive letter, but couldn't find one and so abandoned the notion.

In other news, Gary has added unix names to all user accounts. As new users sign up, they will be given a unix name (or can edit it themselves). This name will be used in the Wiki shortly enough, and for user upload directories and whatnot later on.

In what may be old news, ENIGMA is only three functionalities away from being able to run the official GM platform example perfectly. The three include instance_deactivate() and co, dialog functions (for showing and logging high scores), and tiles. We'll see about those three ASAP. (But after the Windows installer).

With any luck, the provisions I am implementing in the Windows installer (new organization system for compilers and makefiles) will mean, once and for all, simplicity of adding devices for which ENIGMA can officially compile. Also with this addition will come the ability to use ENIGMA portably if configured on a USB drive.

Wish us luck.

1504
Function Peer Review / Re: move_contact functions optimised for bbox
« on: January 03, 2011, 12:22:31 PM »
>You can't easily check for 'solid objects that collide with box from the two furthest points' when only using one reference point on the bbox.

Yes, you can. That's why I broke it into quadrants. I didn't have time to sketch up my idea yesterday (or even to draft it fully), but today, I do.

http://dl.dropbox.com/u/1052740/MoveBboxSolid.png

Code: (C) [Select]
case 0: // Quadrant 0; horizontal up to nearly vertical
  const int dx = inst2->bbox_left - inst->bbox_right, dy = inst2->bbox_bottom - inst->bbox_top; // Get horizontal distance
  const int tdt = (dx > dy)?  dx/cos(dir) : dy*sin(dir);
  if (tdt < td and /*a rectangle that is our translated rectangle with a 1px border collides with our inst2->bbox*/ true)
    td = tdt;

1505
Function Peer Review / Re: move_contact functions optimised for bbox
« on: January 02, 2011, 11:59:33 PM »
A for loop is unnecessary with bboxes.
1) Calculate furthest bbox point when translated from the untranslated position.
i.     If your bottom-left corner is at (0,0) and you are 32x32 pixels, and you are checking 10px at 45 degrees, the coordinate you want is 10*cos(45 deg) + 32, 10*sin(45 deg) + 32
2) Loop, looking for solid objects that collide with box from the two furthest points ((0,0) and (10*cos(45 deg) + 32, 10*sin(45 deg) + 32) in our example)
3) Check untranslated rectangle for collisions; if you're colliding with it initially, we obviously can't move any closer, so break.ass
4) Switch the quadrant of our angle (wrap(angle,360) / 90). This code assumes inst is the current instance and inst1 is the instance we're looping through. Neither are translated from their original position. It assumes a variable representing total displacement, dt. distSquared is parameter dist * parameter dist.
Code: (C) [Select]
case 0: // Quadrant 0; horizontal up to nearly vertical
  const int dx = inst2->bbox_left - inst->bbox_right; // Get horizontal distance
  const int tdt = (dx >= 0)?dx/cos(45) : (inst2->bbox_bottom - inst->bbox_top)*sin(45);
  if (tdt < td)
    td = tdt;

I lack time to do the other three quadrants. You can do them and debug, or I will later. Peace.

1506
Function Peer Review / Re: file_delete
« on: December 30, 2010, 09:11:10 PM »
It's implemented somewhere. It probably hasn't been included because its set isn't complete.

Most GM functions are easy to implement.

1507
Issues Help Desk / Re: Segfalt with enigma compiler
« on: December 30, 2010, 03:33:51 PM »
The hard part is actually doing anything with JEdit. I've been thinking a compatibility tool for GM users would be desirable.

The real struggle is getting people to be aware of the components of ENIGMA that GM simply doesn't offer. They'll have to ease into it, which means lots of compatibility settings. It wouldn't be wise to just replace all comparison = with == upon loading a GM6, because users wouldn't learn anything (they'd still use =, then file a bug report when it failed).

Right now the idea is to have two settings panes saved; one for creating EGM files, another for loading/creating GM6 files. That, however, requires collaboration between ism and myself, so...

1508
Issues Help Desk / Re: Segfalt with enigma compiler
« on: December 29, 2010, 01:39:13 PM »
Now if only the type coercer were so competent. That's what I get for adopting an even remotely standard method.

...:P

1509
Issues Help Desk / Re: Segfalt with enigma compiler
« on: December 29, 2010, 11:05:50 AM »
I just fixed that segfault a bit ago, but haven't yet committed it due to an issue that came with it.
I'd appreciate it if you linked to them with their description (should the top 10 change).

1510
Proposals / Re: Additions to new platform system
« on: December 28, 2010, 11:28:14 PM »
C:\MinGW\bin\
/usr/bin/
fuk:i:r:apple:xcode:fuck:stuffthatsworthitssize:stuffwestolefromgnu:bin
C:\DevKitPRO\DevKitPPC\bin\

1511
Proposals / Re: Additions to new platform system
« on: December 27, 2010, 03:56:54 PM »
TGMG:
Please extend this: http://enigma-dev.org/docs/wiki/index.php?title=Compilers/
And this: http://enigma-dev.org/docs/wiki/index.php?title=Module_hierarchy

I'm not opposed to having a Makefiles/ folder of the same design under SHELL/.

1512
Function Peer Review / Re: distance_to_object
« on: December 26, 2010, 06:16:01 PM »
Not to mention, enigma::fetch_inst_iter_by_int(object) is literally as efficient as can be. It is, in fact, the function that composes with(). It is set up such that there is no way to make it any faster; the iterator it returns accounts for all aspects of instance iteration, including ID, object index with heredity, and keywords such as all, other, or noone.

1513
Proposals / Re: Introduction / Profile Forum?
« on: December 26, 2010, 11:03:23 AM »
Oh, haha. I thought you were talking about docs in general. I saw something about replies being useful, and figured you were thinking that discussion on a particular piece of ENIGMA would promote understanding for future readers.

Anyway, what you're describing is what SourceForge has. A competency level for each language. We could tailor it to ENIGMA, giving a competency level for each system or function set, I suppose. And by "we," I mean someone who isn't me. I despise PHP.

1514
Proposals / Re: Welcome PM
« on: December 26, 2010, 10:58:40 AM »
Good point. We'll probably set something up like that when ENIGMA's Windows installer is tailored to beginners.

1515
Proposals / Re: Introduction / Profile Forum?
« on: December 26, 2010, 10:51:49 AM »
That's why I implemented our current policy on bullshit. People make up nonsense about what they need to know about a system, and the developer fills it in.