• Hello Guest! Did you know that ProjectKorra has an official Discord server? A lot of discussion about the official server, development process, and community discussion happens over there. Feel free to join now by clicking the link below.

    Join the Discord Server

[SOLVED] Creating a custom ability with two events

Sam1370

Verified Member
I want to create a custom ability that does something when the player shifts, and something when the player left-clicks. I set isSneakAbility() to true, does that change anything?

Here's my source code
https://github.com/Sam1370/CustomPillars

Some useful quotes:
No, basically I'm making custom pillars. I'm trying to make it that when a person left-clicks it opens a gui to change the pillar size, and when they shift it creates the pillar.
Yea I saw the custom part but I saw stuff about stained glass and for some reason my mind jumped to being able to customize the look of the pillar lol.

Question (completely irrelevant to the post but you could answer in a PM if at all): but when you choose a size will it do that every time you use the move, without having to reset it, or will you only be able to use that specific size once then go back to default?
The stained glass was for adding X, Y, or Z to your pillar.

As for your other question it will do it every time you use the move, although currently I'm storing the data in a HashMap, which means it will reset when the server stops/restarts.
The thing with me is that I watch the most basic part of a tutorial and think I can do the rest on my own, which ends up making it a lot harder for me. I updated the commit, see what you think :D
 
Last edited:

Sam1370

Verified Member
Are you making a cosmetic effect that changes the type of block that spawns when people use RaiseEarth? That's what it seemed like to me...
No, basically I'm making custom pillars. I'm trying to make it that when a person left-clicks it opens a gui to change the pillar size, and when they shift it creates the pillar.
 

xNuminousx

Verified Member
No, basically I'm making custom pillars. I'm trying to make it that when a person left-clicks it opens a gui to change the pillar size, and when they shift it creates the pillar.
Yea I saw the custom part but I saw stuff about stained glass and for some reason my mind jumped to being able to customize the look of the pillar lol.

Question (completely irrelevant to the post but you could answer in a PM if at all): but when you choose a size will it do that every time you use the move, without having to reset it, or will you only be able to use that specific size once then go back to default?
 

Sam1370

Verified Member
Yea I saw the custom part but I saw stuff about stained glass and for some reason my mind jumped to being able to customize the look of the pillar lol.

Question (completely irrelevant to the post but you could answer in a PM if at all): but when you choose a size will it do that every time you use the move, without having to reset it, or will you only be able to use that specific size once then go back to default?
The stained glass was for adding X, Y, or Z to your pillar.

As for your other question it will do it every time you use the move, although currently I'm storing the data in a HashMap, which means it will reset when the server stops/restarts.
 

xNuminousx

Verified Member
The stained glass was for adding X, Y, or Z to your pillar.

As for your other question it will do it every time you use the move, although currently I'm storing the data in a HashMap, which means it will reset when the server stops/restarts.
Ooh okay. That's fine. Glad to see someone kind of focusing on things no one would think of. Definately adds variety to the addon section and I look forward to what you have to offer!
 

Sam1370

Verified Member
Ooh okay. That's fine. Glad to see someone kind of focusing on things no one would think of. Definately adds variety to the addon section and I look forward to what you have to offer!
Thanks for the compliment :D
Although I might have good ideas I'm not very good at coding so if you or anyone else could help me with this project even a slight bit I would appreciate that :)
 

xNuminousx

Verified Member
Thanks for the compliment :D
Although I might have good ideas I'm not very good at coding so if you or anyone else could help me with this project even a slight bit I would appreciate that :)
Well I dont exactly have access to the computer at the moment so I won't be much help. I dont know when I'll get access back. And by the looks of it you have a pretty clear idea of what you're doing ;)
 

Sam1370

Verified Member
Well I dont exactly have access to the computer at the moment so I won't be much help. I dont know when I'll get access back. And by the looks of it you have a pretty clear idea of what you're doing ;)
The thing with me is that I watch the most basic part of a tutorial and think I can do the rest on my own, which ends up making it a lot harder for me. I updated the commit, see what you think :D
 

xNuminousx

Verified Member
The thing with me is that I watch the most basic part of a tutorial and think I can do the rest on my own, which ends up making it a lot harder for me. I updated the commit, see what you think :D
Ssaaammmeee lol. I watched a Java For Beginners tutorial and after I finished it I felt like a genius but apparently I wasn't lol
 

xNuminousx

Verified Member
I need to start learning how to work GitHub. I can work with the buttons there (like looking at the code and looking at the commits and stuff) but I wanna know more in depth.
 

Sam1370

Verified Member
Ssaaammmeee lol. I watched a Java For Beginners tutorial and after I finished it I felt like a genius but apparently I wasn't lol
Lol in your case I wouldn't even finish the tutorial and feel like a genius then fail creating a variable...
I need to start learning how to work GitHub. I can work with the buttons there (like looking at the code and looking at the commits and stuff) but I wanna know more in depth.
Well really all I know is that it's a good place to store your projects, so what I do is integrate GitHub into Eclipse so that you can directly commit and edit from there and you have the formatting and error checking and stuff
 

xNuminousx

Verified Member
Lol in your case I wouldn't even finish the tutorial and feel like a genius then fail creating a variable...

Well really all I know is that it's a good place to store your projects, so what I do is integrate GitHub into Eclipse so that you can directly commit and edit from there and you have the formatting and error checking and stuff
When I was working on a project with other people I got a taste of GitHub. But the project didn't last long so I didn't use it enough to memorize everything.
 

Sam1370

Verified Member
When I was working on a project with other people I got a taste of GitHub. But the project didn't last long so I didn't use it enough to memorize everything.
Cool... I can give you editing rights to my GitHub so that you can contribute if you'd like (After I post this, I'm going to Google "giving other people editing rights to GitHub", lol). Just tell me your GitHub username :D
 

xNuminousx

Verified Member
Cool... I can give you editing rights to my GitHub so that you can contribute if you'd like (After I post this, I'm going to Google "giving other people editing rights to GitHub", lol). Just tell me your GitHub username :D
Haha I completely understand. And it's kind of pointless, but I appreciate the offer. The electrical company predicts my electricity to be off until September 8th.
 

Sam1370

Verified Member
Haha I completely understand. And it's kind of pointless, but I appreciate the offer. The electrical company predicts my electricity to be off until September 8th.
Ah okay forgot about that. To be honest I've never worked on a GitHub project with anyone before so it would be a good experience for me (and maybe you) if you did when your electricity comes back :)
 

xNuminousx

Verified Member
Ah okay forgot about that. To be honest I've never worked on a GitHub project with anyone before so it would be a good experience for me (and maybe you) if you did when your electricity comes back :)
That'd be awesome. I have some notes of ideas that we could chat over if you'd like. Make a plan while I use Pk through my phone. Prefer skype or discord?
 
Top