If @BlackCloakGS pulls this off (and I don't doubt he will !!) - could the project be extended to supporting bluetooth keyboards ?
Hooking your iMac bluetooth keyboard up to your iPad is really straightforward, but GameSalad doesn't recognise it, it would be great if it did, allowing you to make games with nice tactile keyboard control (as an option alongside onscreen touch controls).
Maybe something like the keyboard key press interface that shows an image of the joystick and you choose which button/direction/trigger will be used in the condition.
That is just a first thought, if something else comes to mind I'll post as well.
@jamie_c that was my first thought as well. However unlike keyboard you can have more that one connected (i know you can connect more that one keyboard to a computer but they still throw the same event unlike a two or more joysticks).
Also think about what if there are more then one controller connected. How would you use that for multiplayer games?
Yeah, you're right. And there are a lot of joysticks/controls that offer different sets of buttons and controls on the market. Seems like something more generic might be needed, like choices of up/down/left/right, button 1/2/3/4, etc... but still not sure that is very workable.
Well... thinking about how there is no standard controller, a nice GUI might not be the best option. How about a drop down menu with list of available binds like in the code:
@BlackCloakGS said:
Though question how should you interact with the gamepad/joysticks in GameSalad? What kind of interface would you like to see?
I've been thinking of how you could define this in game salad all weekend, and i came up with this, and it looks like some other people had a similar idea. Not sure if it's a great implementation, but it's something.
Stick Angle would return a value of 0-360 depending on where the stick is
Stick Magnitude would return a value of 0-100 depending on how far it is from the center
Buttons would return a true or false if they are pressed.
@scottharrrules43 yes but i can't talk about them publicly right now.
@jonmulcahy i think you are on the right track but have a few things for you to think about.
Joysticks/GamePads analog sticks come in different min - max and and min can be negative. Also they comprise of to axis x and y and while one can map that to a angle and magnitude most good libs map each axis to -1.0 to 1.0 (min-max) so zero is half way. Also if the joysticks were devices how may should we support? The desktop and phone could support as may as bluetooth and USB would allow. Also how in this system do you deal with a controller being disconnected and then reconnected? May be we should introduce a concept of player like xbox, wii, and Playstion do. Where each controller is assigned a player number ? Thoughts?
Also would you want a way for the joystick to throw keyboard events?
@BlackCloakGS
haha it's more complicated that I imagined.
@BlackCloakGS said:
Also they comprise of to axis x and y and while one can map that to a angle and magnitude most good libs map each axis to -1.0 to 1.0 (min-max) so zero is half way
That makes sense, it reminds me of the joystick template that used to come with GS way back when. I think if GS handled the physical button output the same way the onscreen joystick did, it would be easy to constrain the players movement to those variables instead of the custom attributes we created.
@BlackCloakGS said:
Also if the joysticks were devices how may should we support?
I would imagine you'd want a minimum of 2, and since (i expect) the OS would provide some of the hooks into the Bluetooth devices, you'd want a way to map the joysticks to a certain player, like in the old Nintendo games where the first person to hit X would be player 1. If gamesalad just provided us a list of joysticks (like we do with touches) we could then add custom code to link those joysticks to onscreen actors in a configuration page to allow them to configure the joystick -> player matchup ingame. I think we have 10 touches prelisted under devices, maybe start with 4 joystick entries?
@BlackCloakGS said:
Also how in this system do you deal with a controller being disconnected and then reconnected?
Maybe have something like the callback attribute in the network function. As long as a device is connected this callback attribute is true. Then we can code ourselves a catch if the callback turns false, display an error message
@BlackCloakGS said:
Also would you want a way for the joystick to throw keyboard events?
I think this could be a good idea too. I can't really think of any real world applications right now, but the more flexibility the better.
I use a GS13 controller that mimics keyboard presses. it has a thumbstick but is not variable as I use it W,S,A,D
In an old Quake Clan...back in da day...we used a Quake setup....on the keyboard for all sorts of movements...when I got a GS13 we simply transfered those key commands to the joystick. Thats a great real world application I woukd think. Maybe hmmmm?
@jonmulcahy what about single player game? I would think the min joysicks would be 1. If we went the way of the touch method you could only ever have 12 joysticks connected (or some finite number) with may be ok. Seems kind of limiting. The xbox and other devices with the concept of players assign the joystick a player number (android does this as well) and the first joystick connect is for player one and so on. If the joystick throws keys it would make logic easier for making a game support keyboard and joystick. You just add behavior for keyboard presses and then make the joystick trow key events for the buttons.
@Thunder_Child the joystick lib will do automatic joystick calibration as well as dead space for the analog sticks ( i still need to finish that code) .
@BlackCloakGS said:
jonmulcahy what about single player game? I would think the min joysicks would be 1. If we went the way of the touch method you could only ever have 12 joysticks connected (or some finite number) with may be ok. Seems kind of limiting. The xbox and other devices with the concept of players assign the joystick a player number (android does this as well) and the first joystick connect is for player one and so on. If the joystick throws keys it would make logic easier for making a game support keyboard and joystick. You just add behavior for keyboard presses and then make the joystick trow key events for the buttons.
oops, forgot about single player games. I was thinking only in multiples. I think assuming that joystick1 is player1 is the way to go. It's easier to implement on our end and people are used to that system.
That seems right on about the keyboard events. That's how I would like to do it.
How could you envision adding logic for an infinite number of joysticks/players? Would you just define an actor as 'playerX' and that actor would accept the values from joystickX? That's the part I can't wrap my head around. I'm so used to constructing my code based on that column view, if we don't have a defined list, how do we assign events
I was thinking of players as devices and that a joystick would be under them. So you could say player1.joystick.dpadup == true or player1.joystick.yaxis >0 (for example). The joysticks would be assigned just like the consoles do it (or if the platform already has player assignment we would respect that). Then eventually we would have some way to show you the joysticks not assigned to a player and then you could assign them to a player. I was think of having a max of 4 to 8 players? Thoughts?
@BlackCloakGS said:
I was thinking of players as devices and that a joystick would be under them. So you could say player1.joystick.dpadup == true or player1.joystick.yaxis >0 (for example). The joysticks would be assigned just like the consoles do it (or if the platform already has player assignment we would respect that). Then eventually we would have some way to show you the joysticks not assigned to a player and then you could assign them to a player. I was think of having a max of 4 to 8 players? Thoughts?
works for me! Personally I would go with 8 players instead of 4. I would expect back end code is not too much different for 8 players vs 4. And it would give everyone more flexibility.
Wow... This sounds cool can hardly wait to see that update, and feature of course... I'll whip up something with game maker studio professional and use it to make the money to buy gamesalad at once... Is it ok if we use 4 game development software companies, say (scirra's construct 2, yoyogames's game maker, your gamesalad, unity)(just wondering is all)? Well provided the games we make for the gamesalad arcade are made with gamesalad of course, so on?
Comments
Yea great work !! So excited to get Amazon fire support!
Send and Receive Data using your own Server Tutorial! | Vote for A Long Way Home on Steam Greenlight! | Ten Years Left
If any one can help with the amazon controller support. that would be great??
Go vote for it if you want it sooner please.
http://bugs.gamesalad.com/show_bug.cgi?id=254
If @BlackCloakGS pulls this off (and I don't doubt he will !!) - could the project be extended to supporting bluetooth keyboards ?
Hooking your iMac bluetooth keyboard up to your iPad is really straightforward, but GameSalad doesn't recognise it, it would be great if it did, allowing you to make games with nice tactile keyboard control (as an option alongside onscreen touch controls).
Yes my lib can be extended to support bluetooth keyboards or any HID device . However, not the first priory of the lib.
Great ! It'd really cool to see it added once you've sorted out the joystick functionality.
Sounds Great Cheers! @BlackCloakGS
Though question how should you interact with the gamepad/joysticks in GameSalad? What kind of interface would you like to see?
Maybe something like the keyboard key press interface that shows an image of the joystick and you choose which button/direction/trigger will be used in the condition.
That is just a first thought, if something else comes to mind I'll post as well.
http://jamie-cross.net/posts/ ✮ Udemy: Introduction to Mobile Games Development ✮ Learn Mobile Game Development in One Day Using Gamesalad ✮ My Patreon Page
@jamie_c that was my first thought as well. However unlike keyboard you can have more that one connected (i know you can connect more that one keyboard to a computer but they still throw the same event unlike a two or more joysticks).
Also think about what if there are more then one controller connected. How would you use that for multiplayer games?
Yeah, you're right. And there are a lot of joysticks/controls that offer different sets of buttons and controls on the market. Seems like something more generic might be needed, like choices of up/down/left/right, button 1/2/3/4, etc... but still not sure that is very workable.
http://jamie-cross.net/posts/ ✮ Udemy: Introduction to Mobile Games Development ✮ Learn Mobile Game Development in One Day Using Gamesalad ✮ My Patreon Page
Well... thinking about how there is no standard controller, a nice GUI might not be the best option. How about a drop down menu with list of available binds like in the code:
And then maybe an option for control detection similar to touch count.
So like a game.controlcount
So we could do rules like:
Follow us: Twitter - Website
@BlackCloakGS Actually thinking about that, it probably wouldn't work. But combining them might.
The rule could be:
when controller (Drop down menu) 1/2/3/etc recieves event (drop down menu) button 1/2/3/etc pressed
Follow us: Twitter - Website
Could make selector thing and make a expression editor and make the controls like accelerometer.
Xbox and ps4 could now be added right?
I could if I had a dev kit.That would be way in the future.
I am sure they will say yes if you ask, right?
came across this today
Apple Invents a Home Button that Doubles as a Gaming Joystick
http://www.patentlyapple.com/patently-apple/2015/01/apple-invents-a-home-button-that-doubles-as-a-gaming-joystick.html
That is pretty cool, apple will probably not add it any time soon or at all. Apple does not like buttons let alone a joystick.
Any updates?
I've been thinking of how you could define this in game salad all weekend, and i came up with this, and it looks like some other people had a similar idea. Not sure if it's a great implementation, but it's something.
Send and Receive Data using your own Server Tutorial! | Vote for A Long Way Home on Steam Greenlight! | Ten Years Left
@scottharrrules43 yes but i can't talk about them publicly right now.
@jonmulcahy i think you are on the right track but have a few things for you to think about.
Joysticks/GamePads analog sticks come in different min - max and and min can be negative. Also they comprise of to axis x and y and while one can map that to a angle and magnitude most good libs map each axis to -1.0 to 1.0 (min-max) so zero is half way. Also if the joysticks were devices how may should we support? The desktop and phone could support as may as bluetooth and USB would allow. Also how in this system do you deal with a controller being disconnected and then reconnected? May be we should introduce a concept of player like xbox, wii, and Playstion do. Where each controller is assigned a player number ? Thoughts?
Also would you want a way for the joystick to throw keyboard events?
@BlackCloakGS
haha it's more complicated that I imagined.
That makes sense, it reminds me of the joystick template that used to come with GS way back when. I think if GS handled the physical button output the same way the onscreen joystick did, it would be easy to constrain the players movement to those variables instead of the custom attributes we created.
I would imagine you'd want a minimum of 2, and since (i expect) the OS would provide some of the hooks into the Bluetooth devices, you'd want a way to map the joysticks to a certain player, like in the old Nintendo games where the first person to hit X would be player 1. If gamesalad just provided us a list of joysticks (like we do with touches) we could then add custom code to link those joysticks to onscreen actors in a configuration page to allow them to configure the joystick -> player matchup ingame. I think we have 10 touches prelisted under devices, maybe start with 4 joystick entries?
Maybe have something like the callback attribute in the network function. As long as a device is connected this callback attribute is true. Then we can code ourselves a catch if the callback turns false, display an error message
I think this could be a good idea too. I can't really think of any real world applications right now, but the more flexibility the better.
Send and Receive Data using your own Server Tutorial! | Vote for A Long Way Home on Steam Greenlight! | Ten Years Left
What about joystick calibration?
I use a GS13 controller that mimics keyboard presses. it has a thumbstick but is not variable as I use it W,S,A,D
In an old Quake Clan...back in da day...we used a Quake setup....on the keyboard for all sorts of movements...when I got a GS13 we simply transfered those key commands to the joystick. Thats a great real world application I woukd think. Maybe hmmmm?
Complete Guide to iOS Publishing {} Complete Guide to Mac Publishing
@jonmulcahy what about single player game? I would think the min joysicks would be 1. If we went the way of the touch method you could only ever have 12 joysticks connected (or some finite number) with may be ok. Seems kind of limiting. The xbox and other devices with the concept of players assign the joystick a player number (android does this as well) and the first joystick connect is for player one and so on. If the joystick throws keys it would make logic easier for making a game support keyboard and joystick. You just add behavior for keyboard presses and then make the joystick trow key events for the buttons.
@Thunder_Child the joystick lib will do automatic joystick calibration as well as dead space for the analog sticks ( i still need to finish that code) .
oops, forgot about single player games. I was thinking only in multiples. I think assuming that joystick1 is player1 is the way to go. It's easier to implement on our end and people are used to that system.
That seems right on about the keyboard events. That's how I would like to do it.
How could you envision adding logic for an infinite number of joysticks/players? Would you just define an actor as 'playerX' and that actor would accept the values from joystickX? That's the part I can't wrap my head around. I'm so used to constructing my code based on that column view, if we don't have a defined list, how do we assign events
Send and Receive Data using your own Server Tutorial! | Vote for A Long Way Home on Steam Greenlight! | Ten Years Left
I was thinking of players as devices and that a joystick would be under them. So you could say player1.joystick.dpadup == true or player1.joystick.yaxis >0 (for example). The joysticks would be assigned just like the consoles do it (or if the platform already has player assignment we would respect that). Then eventually we would have some way to show you the joysticks not assigned to a player and then you could assign them to a player. I was think of having a max of 4 to 8 players? Thoughts?
works for me! Personally I would go with 8 players instead of 4. I would expect back end code is not too much different for 8 players vs 4. And it would give everyone more flexibility.
Send and Receive Data using your own Server Tutorial! | Vote for A Long Way Home on Steam Greenlight! | Ten Years Left
Wow... This sounds cool can hardly wait to see that update, and feature of course... I'll whip up something with game maker studio professional and use it to make the money to buy gamesalad at once... Is it ok if we use 4 game development software companies, say (scirra's construct 2, yoyogames's game maker, your gamesalad, unity)(just wondering is all)? Well provided the games we make for the gamesalad arcade are made with gamesalad of course, so on?