[Mod] Portalgun V6.37 [portalgun]

User avatar
AiTechEye
Member
Posts: 1000
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

[Mod] Portalgun V6.37 [portalgun]

by AiTechEye » Post

Image

Licenses: code: LGPL-2.1, media: CC BY-SA-4.0
Depends: default, mesecons
Source
Download

Portalgun

The gun that can shoot portals :D

The portals can teleport both players, mobs, stuff, and using velocity (which is important)
The users portals, deletes when the user leaves the game or if not used for 40sec.

The extra stuff requires mesecons

"place" to change portal mode (or "left+rightclick" to use the other)

"shift+leftclick" to close both portals (or wait becaoue them removes it self)

"leftclick" on an object to carry it, click again to release
you can craft it to a decuration block, dig to get it back

More info:
Spoiler
=====Blocks and stuff=====
Antiportal block & glass: cant open potals on them
Hard glass: harder then stone
Checkpoint: touch it until you hear a beep sound, then you will move to it after respawn
Cake: eat a dirt-cake? no way!
Security cam: shoots when you are 10 blocks or nearer it
Sentry turret: shoots when something is front of it
Testblock: decuration
Weighted storage cubes disapear if no players is 40 blocks or nearer it (checks every 20 secund)
Entity destroyer: destroys objects 7 blocks around the pointed (hard punsh)
Weighted storage cube spawner: spawns cubes each 5 sec if no cube in same color is 20 blocks or nearer it
Toxic water: the source kills you in 1 secund
Warntape: decoration, but still usefull
Sign number: its basicly 2 blocks, click one of them to change its number

=====Mesecon & technologic stuff=====
Sign X: turns blue/X when off or orange/V on
Close player portal: closing near players portals on singnal
Portal targets: put on your blue portal on blue or orange on orange to activate the block(s)
Mesecon door: only mesecons singnals can open the door
Button: gives mesecon singnal after rightclick
Delayer: punsh to change time 1-10 (delays before mesecon signal and after)
Damage-block: hurts or invisible when active
Object-destroyer: destroys 7 blocks round it on mesecon singnal
Platforms: gives mesecon singnal when same colord cobe is touch it, purple works with all cubes and players
Plathole: gives mesecon singnal when a cube is 2 blocks under it
Powerball-spawner: spawns a deadly powerball each 20'th secund
Powerball-spawner2: spawns a deadly powerball on mesecon singnal
Powerball-target: gives a mesecon singnal when the powerball hits it (the ball activates it)
Powerdoor: a unbreakable and transparant double block, the owner can puch to dig it, fake disapear when is active and is "mesecon singnal leading", it makes you can make unlimited big doors
Trapblock: looks like the test blocks but become invisable when is active (ghoststone)
Weighted storage cube spawner2: spawns a cube in same color on mesecon singnal
Image
Image
Attachments
screenshot_20180817_210139.png
screenshot_20180817_210139.png (152.67 KiB) Viewed 3461 times
screenshot_20180817_205101.png
screenshot_20180817_205101.png (99.07 KiB) Viewed 3461 times
screenshot_20161114_123616.png
screenshot_20161114_123616.png (268.35 KiB) Viewed 3461 times
Last edited by AiTechEye on Fri Jun 19, 2020 10:40, edited 55 times in total.

User avatar
Evergreen
Member
Posts: 2135
Joined: Sun Jan 06, 2013 01:22
GitHub: 4Evergreen4
IRC: EvergreenTree
In-game: Evergreen
Location: A forest in the midwest
Contact:

Re: [MOD] portalgun (0.5)

by Evergreen » Post

This works really well! Great job!

As a side note, I opened this issue a while back on the topic of getter and setter functions for player velocity. This is something minetest really needs.
Back from the dead!

User avatar
Hybrid Dog
Member
Posts: 2834
Joined: Thu Nov 01, 2012 12:46
GitHub: HybridDog

Re: [MOD] portalgun (0.5)

by Hybrid Dog » Post

Evergreen wrote:This works really well! Great job!

As a side note, I opened this issue a while back on the topic of getter and setter functions for player velocity. This is something minetest really needs.
Did you also add an addvelocity function? lf it's lagging the local player differs from the player seen on the server and if you want to do recoil setting velocity wouldn't work for adding it to the current one l assume.

‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪

TG-MyinaWD
Member
Posts: 356
Joined: Thu May 08, 2014 21:22
GitHub: Maddie-Myina
IRC: Maddie-Myina
In-game: .
Location: Far Eden

Re: [MOD] portalgun (0.5)

by TG-MyinaWD » Post

Here a video I did.
Very cool mod hope I will able finish this Portal Test Subgame XD but it only a placeholder atm.

Video
I'm a Transgender no shame about it.
I prefer to be considered as a "Girl/Lady/Miss/Madam/Female" for now on.

User avatar
Excalibur Zero
Member
Posts: 142
Joined: Tue Apr 02, 2013 19:45
GitHub: ExcaliburZero
Location: United States
Contact:

Re: [MOD] portalgun (0.5)

by Excalibur Zero » Post

Do you think you could set up a GitHub repo for this mod? Doing so would make it easier for other people to contribute to and download the mod.

User avatar
Hybrid Dog
Member
Posts: 2834
Joined: Thu Nov 01, 2012 12:46
GitHub: HybridDog

Re: [MOD] portalgun (0.5)

by Hybrid Dog » Post

Alt. Tester wrote:Here a video I did.
Very cool mod hope I will able finish this Portal Test Subgame XD but it only a placeholder atm.

Video
you may would like to use a tool that makes you execute chatcommands if you use, drop or place it
https://github.com/HybridDog/command_tool

UjEdwin, if you attach the player to an object (which could be invisible and not pointable), you can set the velocity of this object and the player gets it too.

‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪

User avatar
AiTechEye
Member
Posts: 1000
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

Re: [MOD] portalgun (0.5)

by AiTechEye » Post

I had an ide about that too, but it wont work very nice (laggy)
But like the green text, I let everyone that is intrested, to make what they want to do with the mod / source :)
(do exclty what you whant with it)
Becaouse by some reason i got too borred by making mods / program.

User avatar
mrob27
Member
Posts: 21
Joined: Sun Sep 27, 2015 13:32
GitHub: mrob27
Contact:

Re: [MOD] portalgun (basic)

by mrob27 » Post

Thanks @UjEdwin I love this!

Image

I've set this up on Github and I'm working on it, forumpost is here

User avatar
Gaming Association
Member
Posts: 62
Joined: Tue Aug 18, 2015 01:52
GitHub: Gerold55
In-game: Gerold55

Re: [MOD] portalgun (basic)

by Gaming Association » Post

Could u work on the gravity gun mod next? @UjEdwin
Gaming Association

User avatar
philipbenr
Member
Posts: 1897
Joined: Fri Jun 14, 2013 01:56
GitHub: philipbenr
IRC: philipbenr
In-game: robinspi
Location: United States

Re: [MOD] portalgun (basic)

by philipbenr » Post

Awesome!

User avatar
AiTechEye
Member
Posts: 1000
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

Re: [MOD] portalgun (basic)

by AiTechEye » Post

Gaming Association wrote:Could u work on the gravity gun mod next? @UjEdwin
i did that long time ago :-) its a part of diplazer, mode8
https://www.youtube.com/watch?v=8JhbfV2cYHg

User avatar
mrob27
Member
Posts: 21
Joined: Sun Sep 27, 2015 13:32
GitHub: mrob27
Contact:

Re: [MOD] portalgun (basic)

by mrob27 » Post

That (Diplazer gravity gun mode) looks pretty cool, but the YouTube video links to this forum post which is totally unrelated. Instead I think you should link to [Mod] Diplazer 15.2 (the ultimate build tool!

I am thinking about using gravity in connection with the P0rtal gun through the crafting recipes. My thinking is like this:
  • The portals are connected by a wormhole in space, and the wormhole has two ends.
  • If you've only placed one portal, then the other end of the wormhole is still inside the gun, and you could walk around with the gun like a vacuum cleaner, any entities would get sucked up and pop out of the portal that you placed.
  • In order to create the wormholes the p0rtalgun contains a "quantum singularity", kind of like a black hole.
  • Since a black hole is very dense matter, it would be made by a chain of crafting recipes like this:

Code: Select all

 rock      obsidian    rock
 obsidian    MESE    obsidian         -->  Dense Matter level 1 (DM-1)
 rock      obsidian    rock

 MESE        DM-1      MESE
 DM-1        DM-1      DM-1           -->  Dense Matter level 2 (DM-2)
 MESE        DM-1      MESE

 DM-1        DM-2      DM-1
 DM-2        DM-2      DM-2           -->  Dark Matter level 1 (Dark-1)
 DM-1        DM-2      DM-1

 DM-2       Dark-1     DM-2
 Dark-1     Dark-1    Dark-1          -->  Dark Matter level 2 (Dark-2)
 DM-2       Dark-1     DM-2

   -     MESE   O.Shard
  MESE  Dark-2     -                  -->  P0rtalgun
  MESE     -       -
except I was thinking of having even more stages, but then it would be effecitvely impossible. Even with 4 stages it would take a ton of work in survival mode to get all the materials to make one P0rtalgun, but that's kind of the point!

Anyway, these dense and dark-matter blocks could also be placed, and they would do stange things with gravity, but I'm not sure exactly what. Maybe if you are near them, the mod would do a set_physics_override({gravity=whatever}) on you (or a setacceleration({x=0, y=whatever, z=0) on other entities)

Any more complex alteration of physics that affects players is hard to do, just like with the boat, you'd have to create an entity and set_attach() the player to it.

User avatar
Hybrid Dog
Member
Posts: 2834
Joined: Thu Nov 01, 2012 12:46
GitHub: HybridDog

Re: [MOD] portalgun (basic)

by Hybrid Dog » Post

mrob27 wrote:If you've only placed one portal, then the other end of the wormhole is still inside the gun, and you could walk around with the gun like a vacuum cleaner, any entities would get sucked up and pop out of the portal that you placed.
yes, then throw the gun into that single portal
In order to create the wormholes the p0rtalgun contains a "quantum singularity", kind of like a black hole.
Since a black hole is very dense matter, it would be made by a chain of crafting recipes like this:
only a specific part of matter causes warping of space l think

‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪‮
‮‪

User avatar
mrob27
Member
Posts: 21
Joined: Sun Sep 27, 2015 13:32
GitHub: mrob27
Contact:

Re: [MOD] portalgun (basic)

by mrob27 » Post

[color=#1781B7]Hybrid Dog[/color] wrote:yes, then throw the gun into that single portal
As currently written (@UjEdwin's code), If only one portal is placed, the globalstep proc doesn't scan for objects near it, so placing one portal then throwing the gun into it has no effect. I believe that's what the original game does too (and the portals look different: they're filled with orange or blue if they don't link to another portal).
  But it would be fun (or perhaps evil) to make it do something spectacular. Suggestions? Kill the player? Make every atom in the universe explode at the speed of light? Something in between?

User avatar
Don
Member
Posts: 1643
Joined: Sat May 17, 2014 18:40
GitHub: DonBatman
IRC: Batman
In-game: Batman

Re: [MOD] portalgun (basic)

by Don » Post

Teleport them to a random location
Many of my mods are now a part of Minetest-mods. A place where you know they are maintained!

A list of my mods can be found here

User avatar
Gaming Association
Member
Posts: 62
Joined: Tue Aug 18, 2015 01:52
GitHub: Gerold55
In-game: Gerold55

Re: [MOD] portalgun (basic)

by Gaming Association » Post

Could u separate the gravity part of the displazer mod because i couldn't figure out exactly how it works
Gaming Association

User avatar
mrob27
Member
Posts: 21
Joined: Sun Sep 27, 2015 13:32
GitHub: mrob27
Contact:

Re: [MOD] portalgun (basic)

by mrob27 » Post

Good idea @Don

@Gaming Association, if you're asking @UjEdwin, you can maybe send them a PM.

User avatar
AiTechEye
Member
Posts: 1000
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

Re: [MOD] portalgun (basic)

by AiTechEye » Post

i should did it from the start, but i dont remmeber how it works too :-)

the best you can do are to remove all parts that it works without, i will see if i can do it.

User avatar
AiTechEye
Member
Posts: 1000
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

Re: [MOD] portalgun (basic)

by AiTechEye » Post

Gaming Association wrote:Could u separate the gravity part of the displazer mod because i couldn't figure out exactly how it works

Now you a chance to remake it to its own mod too, i managed to clear the mostly code, it was a bit hard :-)


the link will disappear after a few days
https://dl.dropboxusercontent.com/u/183 ... ravgun.zip

User avatar
Gaming Association
Member
Posts: 62
Joined: Tue Aug 18, 2015 01:52
GitHub: Gerold55
In-game: Gerold55

Re: [MOD] portalgun (basic)

by Gaming Association » Post

Ty so much @UjEdwin
Gaming Association

User avatar
benrob0329
Member
Posts: 1341
Joined: Thu Aug 06, 2015 22:39
GitHub: Benrob0329
IRC: benrob0329
In-game: benrob03
Location: Michigan
Contact:

Re: [MOD] portalgun (basic)

by benrob0329 » Post

O.O what!?

How have I missed this!?!?!!

THE CAKE IS A LIE!

User avatar
AiTechEye
Member
Posts: 1000
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

Re: [MOD] portalgun 1.0

by AiTechEye » Post

after a long time, i got enough knowledge to make it done :D
this portalgun system is remade and works much better!

changed: refurbished the system
added: place to shift modes
added: player velocity (using entitys)
added: carry with gravity (left click)
added: changes colors in modes

User avatar
AiTechEye
Member
Posts: 1000
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

Re: [Mod] Portalgun 1.5 (beta)

by AiTechEye » Post

added a lot of stuff, look above :-)

User avatar
AiTechEye
Member
Posts: 1000
Joined: Fri May 29, 2015 21:14
GitHub: AiTechEye
Location: Sweden

Re: [Mod] Portalgun 3

by AiTechEye » Post

The portals in this version will work atleast 40% better then version 2.

william341
Member
Posts: 10
Joined: Thu Jul 16, 2015 05:24
GitHub: PatchTest
In-game: william341

Re: [Mod] Portalgun 3

by william341 » Post

I've put your mod on the MPI showcase!
You can find it here: http://minetestplayerinitative.github.io/mods/

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot], Google [Bot] and 10 guests