Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix get contacts #141

Closed
wants to merge 210 commits into from
Closed

Fix get contacts #141

wants to merge 210 commits into from

Conversation

rlranft
Copy link

@rlranft rlranft commented Jan 31, 2014

This addresses the issue described on the forums at http://www.garagegames.com/community/forums/viewthread/136064

TL/DR: SceneObject::getContact() was returning the pointer and not the id.

MelvMay-GG and others added 30 commits March 27, 2013 19:00
…vents occur in an unexpected order (this can happen but we don't need to see it spamming the console).
…a schema that is strictly compatible with JSON RFC4627 (specifically the part about member names must be unique) however TAML does not care about this and it can be turned off with the console variable "$pref::T2D::JSONStrict" (set it to false).

- TAML adheres to unique member names by adding a suffix.  The member names that do this are the ones that represent children types or custom node names.  The JSON writer has a unique serial number which is increments during writing however you are free to configure the actual format by changing the following in the "tamlJSONWriter.cc" file (at the top): StringTableEntry JSON_RFC4627_NAME_MANGLING_FORMAT = StringTable->insert( "%s[%d]" );
- Taml also allows you to configure which characters are used to separate the type/node-name from the index again using an entry in the "tamlJSONWriter.cc": StringTableEntry JSON_RFC4627_NAME_MANGLING_CHARACTERS = StringTable->insert(" !$%^&*()-+{}[]@:~#|\\/?<>,.\n\r\t");

- TAML already will auto-detects the file type by extension (the defaults are XML is ".taml", BINARY is ".baml") and JSON now has a default of ".json".  As always, you are free to changes these defaults in the C++ code or on a TAML per-instance basis.
…eing specified).

- Fixed console warning from CompundObjectsToy (bad layout mode was being specified).
…ow TAML can perform parsing requests for visitors for potentially any format i.e. you can write a visitor without having knowledge of the format being read. Only an XML parser is currently present but I'm now writing JSON and BINARY parsers. With a JSON and BINARY parser in place you will be able to define things like asset-definitions and module-definitions in any TAML format (any that has a parser).
…ecause there's a parser available (it can even update so it works with renaming assets etc).
…it easier:

removed unnecessary calls in ShooterControls::onRemoveBehavior
fixed a bad reference to caustics particle effect
…lopment

Conflicts:
	modules/TropicalAssets/1/assets/particles/caustics.asset.taml
…s as special-case of two triangles. The changes remove the single/multiple strict batching therefore this metric has been removed from the DebugStats which causes the changes outside of the BatchRender type.
- Batch renderer now works exclusively with triangles making the quads a...
* updates to consoleDoc.cc
  *  output global script functions as "groups" instead of a "namespace".
  * this helps create an organization that isn't hacking the "namespace" C++ concept
* a new doxygen "layout" file
  * uses "groups" instead of "namespace" to get global functions organized well
  * for classes, uses the term "methods" and "fields" in place of "public attributes" and other default C++ what-not
* a new css files.
  * based on doxygen default but with much less bold text. :)
  * keeps all the unnecessary configuration in tact.  it doesn't hurt and it will be easier to diff with future doxygen defaults
   string Vector2Direction ( F32 angle, F32 magnitude )
 * support torque2D doxygen
 * support for torqueScript doxygen on the code base (not by dumping symbols with a script)

moved support files (css, menu layout, footer/header) to a config dir
moved config files (run doxygen for engine or script) into config dir
… documents torque2D with tags. Then documents TorqueScript as a separate doc with links into the torque2D docs. Before there was a concept for ConsoleFunctions and now there is a decent concept for ConsoleMethods as well. Note that doxygen is unhappy with this idea as it was not designed for this. So I'm trying to keep it as simple as possible while still working (frankly tricking Doxygen).
…ript.

Vector2_ScriptBinding.h: example of converting ConsoleFunctions
   * put @addgroup doxygen comments at top and bottom
   * convert ConsoleFunction to ConsoleFunctionWithDocs
   * change return type from S32 to ConsoleInt, for instance
   * move string-based comments to regular comments above the function instead

Simbase*: example of creating a scriptBinding file when there was none
   * pulled the ConsoleFunctions out of SimBase.cc and into SimBase_ScriptBinding.h
   * Added #include "SimBase_ScriptBinding.h" to Simbase.cc
   * Updated SimBase_ScriptBinding.h just like Vector2_ScriptBinding.h example
   * Added new file to VS2012.  Remember to do this for all compilers! (which I did not do for this check in)

Trigger_ScriptBinding.h: updated ConsoleMethods (class functions)
   * (no need to put @addgroup like with ConsoleFunctions)
   * put ConsoleMethodBeginWithDocs(Trigger) at the top of the file
   * put ConsoleMethodEndWithDocs(Trigger) at the bottom of the file
   * convert each ConsoleMethod to ConsoleMethodWithDocs
   * just like with ConsoleFunctions, move the comments and change the return type

may rearrange all this so I want a checkpoint via a commit.
…is an attempt to re-use the least number of concepts and we need namespaces. Functions may have worked in a group but classes will not. the reason is that the same class name will be seen in the engine via the tag file and confuse things.

also for engine docs, override a few "function-like macros" from the engine which heartily confuse doxygen.  (a semi-colon on the end of macro calls would probably work but that's a lot of files to touch)
several subtle changes such as adding collapsible diagrams to the t2d docs
tried a little trick to pull as much "old" Console function/method docs over as possible.  Seems to work pretty well.
timmgt and others added 24 commits October 27, 2013 09:30
…oggle the android keyboard along with a script binding for it
…improvements. This will temporarily break the other platforms, which I will fix immediately.
…d input improvements. This will temporarily break the other platforms, which I will fix immediately."

This reverts commit 3067b33.
Fixed incorrect buffer size in several places
…ums/viewthread/136064 - now returns the pSceneObjectCollider->getId() value instead of pSceneObjectCollider itself.
@dottools
Copy link
Contributor

dottools commented Feb 1, 2014

This time wrong pull request destination branch.

@rlranft
Copy link
Author

rlranft commented Feb 1, 2014

Ok, this system is more than just a little cumbersome. I had to make another account because I could find no simple way to force my development branch to match the upstream. I can now find no way to "retarget" this pull request. It's a drop-dead simple fix - just add ->getId() to the ends of three lines. That's it.

@rlranft rlranft closed this Feb 1, 2014
@lilligreen
Copy link
Contributor

A few tips:

  • for drop dead simple fixes to 1 source file, I just edit the file directly in my fork through Github (yep, Github has a web based code editor). It's one commit per file so this is not a good method for features or fixes spanning multiple files. Just need to be really careful not to make any mistakes and to test the changes afterwards.
  • I highly recommend everyone use SourceTree as their GUI-based Git client. It really makes using Git simple. All I do for my projects is clone the GG repo and set my fork up as another remote. Pulling changes from origin and pushing stuff to my fork is pretty easy with this program.

@rlranft
Copy link
Author

rlranft commented Feb 1, 2014

Ok, used tip #1 – crossing my fingers!

Rich

From: Mike Lilligreen [mailto:notifications@github.com]
Sent: Saturday, February 1, 2014 11:13 AM
To: GarageGames/Torque2D
Cc: rlranft
Subject: Re: [Torque2D] Fix get contacts (#141)

A few tips:

· for drop dead simple fixes to 1 source file, I just edit the file directly in my fork through Github (yep, Github has a web based code editor). It's one commit per file so this is not a good method for features or fixes spanning multiple files. Just need to be really careful not to make any mistakes and to test the changes afterwards.

· I highly recommend everyone use SourceTree as their GUI-based Git client. It really makes using Git simple. All I do for my projects is clone the GG repo and set my fork up as another remote. Pulling changes from origin and pushing stuff to my fork is pretty easy with this program.


Reply to this email directly or view it on GitHub #141 (comment) . https://github.com/notifications/beacon/6558317__eyJzY29wZSI6Ik5ld3NpZXM6QmVhY29uIiwiZXhwaXJlcyI6MTcwNjgxNDc5MiwiZGF0YSI6eyJpZCI6MjQ3MjE5MjZ9fQ==--b81e4f6fefc03495feb72b25e90d3d542fd565fd.gif

@rlranft
Copy link
Author

rlranft commented Feb 1, 2014

Aw hell – I guess the fix can be merged into your dev if you want – It’s now a duplicate. Anyway, it’s a very simple change – I’m reasonably sure the intent was to return the SimID of the colliding object and not its pointer’s integer value and I changed it accordingly.

I had an extremely frustrating 20 minutes with SmartGit this morning trying to commit changes to the Torque3D-Documents repository on a second account – the damned thing doesn’t ask which username you want to use on a per-session basis, it just keeps the last one.

I’ll give SourceTree a shot – it can’t be as bad as SmartGit….

Thanks!

Rich

From: Mike Lilligreen [mailto:notifications@github.com]
Sent: Saturday, February 1, 2014 11:13 AM
To: GarageGames/Torque2D
Cc: rlranft
Subject: Re: [Torque2D] Fix get contacts (#141)

A few tips:

· for drop dead simple fixes to 1 source file, I just edit the file directly in my fork through Github (yep, Github has a web based code editor). It's one commit per file so this is not a good method for features or fixes spanning multiple files. Just need to be really careful not to make any mistakes and to test the changes afterwards.

· I highly recommend everyone use SourceTree as their GUI-based Git client. It really makes using Git simple. All I do for my projects is clone the GG repo and set my fork up as another remote. Pulling changes from origin and pushing stuff to my fork is pretty easy with this program.


Reply to this email directly or view it on GitHub #141 (comment) . https://github.com/notifications/beacon/6558317__eyJzY29wZSI6Ik5ld3NpZXM6QmVhY29uIiwiZXhwaXJlcyI6MTcwNjgxNDc5MiwiZGF0YSI6eyJpZCI6MjQ3MjE5MjZ9fQ==--b81e4f6fefc03495feb72b25e90d3d542fd565fd.gif

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.