Jump to content

How to make Metadata blocks work as portal frames for dimensions?


Recommended Posts

Posted

Just to save myself some typing here is a video of the issue on hand:

I use to have this mod working perfectly through ModLoader but seeing how smooth forge runs with other things I been slowly updating the mod to forge over the past few days. I know in the video I was using forge 6.6.0.499, but after I recorded it I updated forge to version 6.6.0.515. The issue was still there. Sat there for another 2 hours trying to figure out what the problem is but there is no luck. The portal lights up now but for some reason I cannot set it to use a certain meta ID for the portal spawn. I want to use the metadata for block ID 230 but as the 2nd metadata case 2. Its kinda bugging me now that I cannot use metadata for portal blocks. Here is the code for each thing used for the dimension blocks:

 

Main.class:

 

  Reveal hidden contents

 

 

PortalBlocks.class (the portal frame blocks):

 

  Reveal hidden contents

 

 

ItemBlockMeta (Since the portal frame is a MetaData block to save ID space):

 

  Reveal hidden contents

 

 

Portal1.class (The portal block that teleports):

 

  Reveal hidden contents

 

 

TeleportSuffering.class (Teleports player to dimension if I recall):

 

  Reveal hidden contents

 

 

I am sure the next 2 class files are irrelevant to what the issue is since they determine what the generation settings are for the dimension is. And before you ask what the issue is watch the video. I am not really good at all describing things in text format so just recording a video of the issue is better to see what the issue is then just me failing at describing it....If its something very simple what the issue is then sorry, still getting use to java and forge =p Now for the question, is it possible that the issue is caused by that the block for the portal frame is a MetaData? Will it cause issues when I use the Same blockID but a different metadata ID for the next dimension later on? (p.s. I do not want to modify the BlockFire.java that way my mod have less of a chance conflicting with other mods so...)

A modder uses search for solutions, a coder asks for help only after looking into the main source of the game modding. A master java programmer has solutions and is helpful. Be friendly to others, they will be friendly to you (depending on how their day goes ;) )

Posted

I'll summarize what the issues seemed to be from the video:

 

[*]Portal does not spawn when the portal frame is ignited

[*]Location of the player's exit point is not right next to the portal in the other dimension.

[*]Not sure if this is also an issue or not, but another issue is that the portal in the other dimension does not spawn a frame. 

[*]Another issue is some displeasure regarding the portal blocks not being able to use meta data.

 

Would you say that is a good summary of the issues you are trying to address?

 

Could you give more details on what the different areas of the code are doing and responsible for?  For example, point out where the code that is supposed to detect the fire and open the portal.

Posted

I have yet to add the code to ignite the portal I decided to hold that off till I figure out what the problem is with the block detection. I updated the video with a different one which shows the problem even more. The main issue is trying to get the metadata block to use the proper block. Nomatter what I try the portal block always registers the default meta but not the 2nd meta. The frame not forming was a bug on my part and was fixed when I set the frame block to mod_Nexion.portalBlocksID alone but it never turned out to be the metadata version just the default. As far as I know (of my knolage) dimensions have a issue detecting metadata blocks or I am not using correct syntax to get it to detect it properly =/ the PortalBlocks.class and the ItemBlockMeta.class handles the MetaData blocks for the portal frames...the rest is basically easy to tell =p

A modder uses search for solutions, a coder asks for help only after looking into the main source of the game modding. A master java programmer has solutions and is helpful. Be friendly to others, they will be friendly to you (depending on how their day goes ;) )

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

  Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

  Your link has been automatically embedded.   Display as a link instead

  Your previous content has been restored.   Clear editor

  You cannot paste images directly. Upload or insert images from URL.

Announcements



  • Create New...

Important Information

By using this site, you agree to our Terms of Use.