Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / FixSpriteToSprite seems to be missing from the command set.

Author
Message
PartTimeCoder
AGK Tool Maker
9
Years of Service
User Offline
Joined: 9th Mar 2015
Location: London UK
Posted: 29th Jul 2021 21:53
Thought I would give the brain-ache stuff a little break and just tinker with some game stuff and straight away while trying to attach a turret to a tank I found a missing function ... I Know, I Know, I cant find something that does not exist its an oxymoron!!

Anyhou, This seems to work, pretty happy with how easy it was to implement.



Not sure where the 2 "Forum Functions" came from but I have them in an include, thanks to whoever made them.

Now, to have fun with tanks!








Open Source plugins
Cl - DnD Plugin
Phaelax
DBPro Master
21
Years of Service
User Offline
Joined: 16th Apr 2003
Location: Metropia
Posted: 1st Aug 2021 18:09
I thought there was a command for this already, I must've written my own back in the day when I did a Spriter importer (which is no longer necessary)
Tiled TMX Importer V.2
XML Parser V.2
Base64 Encoder/Decoder
Purple Token - Free online hi-score database
Legend of Zelda

"I like offending people, because I think people who get offended should be offended." - Linus Torvalds
blink0k
Moderator
11
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 2nd Aug 2021 20:34
Very nice matey.
FixTextToSprite() and FixEditBoxToSprite() would be nice as well. For the UI warriors
PartTimeCoder
AGK Tool Maker
9
Years of Service
User Offline
Joined: 9th Mar 2015
Location: London UK
Posted: 2nd Aug 2021 23:04
That's a good idea, group a bunch of items to a sprite and tween it ... I like that.
Open Source plugins
Cl - DnD Plugin
blink0k
Moderator
11
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 2nd Aug 2021 23:59
What would also be super brilliant is if you added draw commands relative to the sprite.
So you could attach a draw command and it would draw a box,line.elipse when it synced. Again for the UI warriors
PartTimeCoder
AGK Tool Maker
9
Years of Service
User Offline
Joined: 9th Mar 2015
Location: London UK
Posted: 3rd Aug 2021 16:39
Hmm, yea draw functions, I wonder how best to go about that

FixBoxToSprite
FixElipseToSprite
FixLineToSprite

FixParticalToSprite, FixParticalToObject could be useful to.

I saw Lee's GGMax video about "Smart Objects" and was thinking that although AppGameKit already has the functionally to achieve the same thing you would have to go about it in a bit of a mix n match fashion, FixObjectToObject/FixObjectToBone, fine its a start but the rest we are updating somewhere else.

FixObjectToBone // sword
FixObjectToObject // sword attachment
FixParticalToObject // sword emitter
FixObjectToBone // shield
FixParticalToObject // shield emitter
FixSpriteToObject // attach healthbar

^^ I just setup a character with a sword with attachment and particle, a shield with particle and a 2D health bar with 6 function calls
maybe even LoadObjectWithAttachments, LoadSpriteWithAttachments

A complete set of Fix* functions is certainly something I could use so I'll be adding them my local lib.
Open Source plugins
Cl - DnD Plugin

Login to post a reply

Server time is: 2024-11-23 12:38:54
Your offset time is: 2024-11-23 12:38:54