Page 8 of 24

Re: New Dynamic Script Ideas

PostPosted: 05 Sep 2013, 06:55
by Krom
@Skypper: You can make a mod to a certain extent: change sprites, change maps, change some house stats, employ dynamic scripts to change gameplay.

Re: New Dynamic Script Ideas

PostPosted: 05 Sep 2013, 07:42
by Skypper
oke thx

Re: New Dynamic Script Ideas

PostPosted: 03 Oct 2013, 09:55
by thunder
:)
scripting idea:
-cylinder -there wont be left and right edges
-sphere -there wont be left right and top, bottom edges
MAPS.
As the snake script is working, just with units. And the units should to calculate with the shorter walking way...etc.
What does it need for this?
Okay and need a map also for this.:)
Thanks!

Re: New Dynamic Script Ideas

PostPosted: 03 Oct 2013, 10:02
by Tef
@ thunder: I don't think that's possible right now. This is because the required information, namely 'desired unit location upon mouse-click' cannot be captured. Hence, you cannot calculate the shortest path, hence you cannot make a unit walk across the edge. Even if you could capture the target location, pathfinding is something you cannot influence through dynamic scripting. Am I saying this all correctly, Lewin / other expert?

Re: New Dynamic Script Ideas

PostPosted: 03 Oct 2013, 11:58
by Krom
@Thunder: This is doable, but very hard/complicated from programmers point of view.

@Tef: Civilization is an example of how it works - there's a cylindrical world :)

Re: New Dynamic Script Ideas

PostPosted: 04 Oct 2013, 15:31
by WhiteWolf
To continue on the, no edges thing, a friend of mine introduced me to 'Populous 3: the beginning'. A bullfrog made game in 1998. The game is not great (however very fun to LAN) but it uses a planet as map. Maybe somethings could be copied to make a sphere like map ? No idea if that is possible but still, might get some inspiration from it ;P

Re: New Dynamic Script Ideas

PostPosted: 04 Oct 2013, 15:51
by Krom
I enjoyed the Populous 3 game back in its time :)
As almost all of Bullfrogs creations it was superb :)

Re: New Dynamic Script Ideas

PostPosted: 05 Nov 2013, 13:25
by RandomLyrics
ErasePlayersTile(x, y: integer) - erase road, vine, plain tile and recovers old natural tile ( like grass or earth).
AddRoad/Vine/Plain(aPlayer, x, y: integer) - add finished road for specific player.

Re: New Dynamic Script Ideas

PostPosted: 06 Nov 2013, 09:27
by sado1
Is there a way in current nightly to check whether a road plan was placed? I can't see anything, the closest to what I want is procedure OnHousePlanPlaced or states Is(Winefield/Field/Road)At, which both won't help me much. I'd like to have either procedure OnRoadPlanPlaced or state IsRoadPlanAt. (Pleeeeeaaase :) )

edit: Also, could you please compile Script Validator and include it each time you make a nightly? Would be much appreciated :)

Re: New Dynamic Script Ideas

PostPosted: 08 Nov 2013, 12:29
by Krom
@sado1: There will be one, much alike OnHousePlanPlaced which occurs when player has placed a house plan.

Andreus offered to add OnConsoleInput command, which will pass what player has typed in console (e.g. /hidetext to hide text overlays).

Re: New Dynamic Script Ideas

PostPosted: 08 Nov 2013, 13:17
by sado1
Andreus offered to add OnConsoleInput command, which will pass what player has typed in console (e.g. /hidetext to hide text overlays).
Oh my god, now that would be mindblowing.

Re: New Dynamic Script Ideas

PostPosted: 09 Nov 2013, 10:08
by Lewin
Andreus offered to add OnConsoleInput command, which will pass what player has typed in console (e.g. /hidetext to hide text overlays).
Sounds like a good idea, maybe we can support more complicated interfaces later too :) Make sure Andreus remembers that console commands must be treated like all other user input and sent through the GIP, otherwise it will break replays/multiplayer since the event OnConsoleInput could be used in the script in a way that causes changes to the game state. Also, in multiplayer the event will need to occur on ALL clients (with a parameter for the player index) otherwise it can go out of sync too.

Re: New Dynamic Script Ideas

PostPosted: 09 Nov 2013, 16:16
by andreus
yes, I remember, it should be synchronized between players. would be cool if you implement this idea ;)

Re: New Dynamic Script Ideas

PostPosted: 15 Nov 2013, 10:02
by RandomLyrics
OnConsoleInput
great idea!
event:
OnOrderGroupWalk(aPlayer, aGroup, X, Y: integer) - occurs when player gives group order to walk somewhere
OnOrderGroupAttackGroup(aPlayer, aGroup, aGroupAttacked: integer) - occurs when player gives group order to attack enemy group
OnOrderGroupAttackHouse(aPlayer, aGroup, aHouseAttacked: integer) - same for house
or OnPlayerClick(aPlayer, X, Y: integer) - occurs when player click right mouse button on the ground

Re: New Dynamic Script Ideas

PostPosted: 21 Nov 2013, 01:11
by RandomLyrics
hi guys, i have a problem with WareDistribution, im changing ware distribution every 10 minutes for each 6 players, and it isnt working well, dont know why.
  Code:
procedure AIChangeDistributionTactic; var j, k, kl: integer; begin for j:= 0 to MAX_PLAYERS-1 do begin if (States.PlayerEnabled(j)) and (States.PlayerDefeated(j) = false ) then begin if States.HouseDeliveryBlocked(PLAYERS_MAIN_TOWER[j]) = false then begin k:= States.KaMRandomI(6); kl:= States.KaMRandomI(6); if (k = 0) and (kl = 0) then k:=k+1; if (k <= 2) and (kl = 0) then k:=k+1; if (kl <= 2) and (k = 0) then k:=k+1; Actions.PlayerWareDistribution(j, 9, 22, k); //mill Actions.PlayerWareDistribution(j, 9, 16, kl); //pig farm end; end; end; end;
on tick:
  Code:
if ( States.GameTime mod AI_DISTRIBUTION_TACTIC_TIME = 0 ) then begin AIChangeDistributionTactic; end;
photo: Image

i think it only works when ill change it manually for each player. So i think the Action desont work properly.